Mediator is the smallest functional unit in WSO2 ESB. A mediator is granular enough to perform a given specific task. WSO2 ESB comes with a rich collection of mediators addressing most of the common integration problems. For example, the Log mediator can be used to log any incoming/outgoing messages. The DBLookup mediator can be used to retrieve information from a database. The Header mediator can be used to add or remove SOAP headers.