21

The company I work for is evaluating some middleware solutions for governace, metering and security of web services. Currently, we're using an Enterprise Service Bus (ESB) for this purpose, but some cool guys in management decided they are going to deploy some API Management Middleware.

I researched a bit about these API Management (aka API Gateway) Solutions but couldn't find the difference between them and actual ESBs. I evaluated some white papers from Mule, WSO2, Oracle etc, but the features offered by both products seem to be almost the same. The question is, what an API Management can do that an ESB cannot do and vice-versa? What value can be added to an IT Infrastructure by replacing an ESB for an API Gateway?

1
  • 4
    How is the question "What's the difference between an API Gateway and an ESB" off topic for a Software Engineering discussion? Commented Aug 31, 2018 at 16:38

1 Answer 1

22

The reason you're getting the concepts jumbled up is that the vendors are selling them in a package. But they are definitely separate concepts.

An API Gateway provides a central access point for managing, monitoring, and securing access to your publicly exposed web services. It would also allow you to consolidate services across disparate endpoints as if they were all coming from a single host. For example let's say you had ten different service endpoints that were all part of a single "suite" of services. Rather than informing consumers of your service to use service1.yourcompany.com for one service and service2.yourcompany.com for another and so forth, you can instead have them all point to api.yourcompany.com/service1 or api.yourcompany.com/service2 and the gateway would be responsible for redirecting the requests to the appropriate endpoints.

An ESB is an internal "Bus" that allows applications and services to communicate with each other in an uncoupled fashion. All applications can hook into the bus and they can receive any message that interests them when published by another application. They can also publish their own messages that another application may listen for and respond to. The applications are not responsible for connecting with each other directly, they publish their messages to the bus and all interested parties listen and react.

Logically the API Gateway is not a replacement for an ESB but rather an enhancement for a service oriented architecture.

4
  • 1
    I believe the argument for using ESBs is the same. ESBs are central access points and can perform load balancing, monitoring, metering and security of services from different endpoints. You may also pass the URL of the ESB to the consumers instead of the URL of individual services. So far, nothing new.
    – dliber
    Commented Dec 2, 2014 at 16:53
  • ESB is internal API Gateway is intended for external consumption.If you want to use an API Gateway internally instead of an ESB I guess there's nothing to stop you. Commented Dec 2, 2014 at 23:24
  • That's exactly the point. There is an overlap of features of ESBs and API platforms. You could deploy an ESB for external access or an API platform for internal access. If their features are the same, what is the benefit of using one instead of the other? What makes them so different so you can use one instead of the other (or both together) and deliver real value to your business?
    – dliber
    Commented Dec 4, 2014 at 12:22
  • One thing an ESB is designed for high volume traffic. It usually has a proprietary or non-internet friendly protocol. An API Gateway is designed to translate between Internet protocols (SOAP, JSON, XML, HL7) and place the requests on the ESB. Basically, you CAN use the gateway for communications between your internal services, that doesn't necessarily make it the best fit. Commented Dec 4, 2014 at 15:38

Not the answer you're looking for? Browse other questions tagged or ask your own question.