Consider a service provider and a service consumer within your organization.
A provider needs clients to talk to it. The consumer needs to consume the services of the provider. The provider allows this to happen by exposing its services through some kind of RPC or messaging. The difference between the two is that RPC tends to be procedure centric whole messaging is more content centric.
Consumers need to talk directly to the providers and in the process circumvent the differences in protocol (is it RPC over HTTP or RMI over IIOP) and canonical data models (is it XML or Plain Java objects or some kind of binary stream)
Direct interaction implies that the consumer is aware of the URI at which the service is provided. In a complex system, there would be multiple service providers and consequently multiple end points for consuming those services.
Deployment considerations mandate that the consumer be unaware of who is providing the service and at which end point the service is being provided. An ESB provides an intermediation layer to facilitate this.
Typical features include:
1. Location (or endpoint) transparency – a deliberate unawareness of the location at which services are provided. All services are provided at some well known locations which would not change.
2. Transformation layer – where the consumer’s language (so to speak) is translated into the provider’s language. For instance, if the consumer can only understand XML and the provider only knows binary streams of data then this layer would serve to do the translation.
3. Protocol transparency – where the consumer can request for services using one protocol and the ESB translates it to some other protocol.
4. A bunch of Enterprise Integration Pattern (EIP) artifacts – like routers, queues and the like. – These take care of routing from the consumer to the provider.
5. Various management utilities to govern the way the ESB functions. For instance, you may want to load routing tables etc using this interface.
6. Tools to facilitate Business Process Orchestration. Can include artifacts that are demanded by BPEL etc.
Note that 4,5 and 6 above typically come along with an ESB but are not a necessity from it. ESB by the way can be trivially implemented using a messaging system. It does not necessarily have to be an elaborate tool.