WSO2 Integrator: How do Inbound Endpoints reroute requests to resources

Viewed 74

I am trying to understand how the WSO2 micro integrator reroutes requests internally. I know that inbound endpoints basically enable services to be available on a different port. So, does it maintain a list of resources that are mapped to this inbound endpoint and simply act as a passthrough? For example:

  1. I have API resource defined at: http://localhost:8290/healthcare/querydoctor/{category}.
  2. Then create inbound endpoint at port 8505 with Dispatch File Pattern: /healthcare/querydoctor/.*.
  3. At this point does it internally create a map that says http://localhost:8285/healthcare/querydoctor/.* = [http://localhost:8290/healthcare/querydoctor/{category}, ...]

Also, I saw this in the wso2 documentation:

The HTTP inbound endpoint can bypass the inbound side axis2 layer and directly inject messages to a given sequence or API. For proxy services, messages are routed through the axis2 transport layer in a manner similar to normal transports.

What does bypassing the axis2 layer mean, and why is that being done in this case?

1 Answers

Basically, Axis2 is the default transport layer of MI. For example, if you invoke an API through port 8280 it will go through the Axis2 layer and come into the integration layer. If you invoke an HTTP/S Inbound Endpoint it will not go through the transport layer again, it will be routed internally to the Proxy or API if you have a Dispatch Pattern.

The following image will help you to understand the Inbound Endpoint architecture.

enter image description here

Related