Direct Proxy

Version: 17.01

Supported Since: 17.01

Use case description

I want to proxy my web service calls by introducing a intermediate proxy service of the UltraESB-X. This proxy service is not supposed to do processing and it will directly route the receiving HTTP calls to the actual back end service.

Proposed Solution

As shown in the following diagram, ESB will come in between the actual end user and the back end service.

direct proxy

Implementation of the Solution

Prerequisite

In order to implement above use case, first we should add the HTTP NIO Connector from the connectors list.

Same can be done to an existing project via Component Registry. From Tools menu, select Ultra Studio → Component Registry and from the Connectors, select above dependencies
Implementation

To implement above use case, first let’s create our integration flow named “direct-proxy”. Then let’s add required components by going through following steps in order.

  1. Add an NIO HTTP Listener connector from the connectors list, to accept the HTTP requests from the user. NIO HTTP Listener basic parameters should be filled as below table.

  2. Add an NIO HTTP Sender connector from the connectors list, to send the received request to the actual back end service. For that NIO HTTP Sender basic parameters should be filled as below table.

After adding above components, complete integration flow should be like below,

direct proxy 1

Each element of the flow should be filled as below

1

NIO HTTP Listener

direct proxy 2

2

NIO HTTP Sender

direct proxy 3

Now you can run the integration flow and check the direct proxying is working as expected. Once you send a request to the configured service path of the NIO HTTP Listener and trace the execution flow using flow tracer, you should be able to see the execution path of your direct proxy integration flow.

Property Configuration

When running the sample in the UltraESB-X distribution, if you needed the default parameters of HTTP Listener or HTTP Sender, please refer to the following section

Refer to Managing Project Properties documentation on how to override properties.

NIOHttpEgressConnector.http-sender.host

The Hostname of the back end server

NIOHttpEgressConnector.http-sender.port

The Port of the backend server

NIOHttpEgressConnector.http-sender.servicePath

The Service Path of the backend server

NIOHttpIngressConnector.http-listener.path

The Service Path of the proxy listener

NIOHttpIngressConnector.http-listener.port

The Service Port of the proxy listener

In this topic
In this topic
Contact Us