In this tutorial we’ll present BP-Switch feature that helps us to set up a simple message forwarding without touching the message. This can be handy when you need to route your messaging traffic through the BP-Node which usually stands on a crossroad of multiple network domains. In such a case BP-Node can receive a message on one connection (and settings), unwrap it and forward to another connection with a different configuration (e.g. TLS).
In this scenario, following BP-Node components will be used:
The first thing we’ll need is to create the listening connection, which will serve as the entry point for receiving our messages. In our scenario a component called NbyteHeaderTCP class will be configured.
Open your BP-UI and navigate to Components. There click the green button which says “Add Component”. From the Class options available pick the bp::eftlab::node::ipc::NbyteHeaderTCP and name it: Downlink.
When clicking the Add button new options will appear, related to the class selected. Fill in the following values:
Click the Save button.
No we need to add a plugin which will strip originator connection information so message can be processed by another connection.
Click “Add Plugin” button.
Pick the “bp::eftlab::node::ipc::plugins::SingleConnectionForMessageExchange”.
Click Save.
Now we can add a connection. A connection is the actual entry point so we need to fill the IP and port on which the BP-Node will be listening.
Press the “Add Connection” button.
Fill in the form with following connection values:
Save the configuration changes by clicking the “Save” button.
Note the Component Id (8b98e582-9c3c-4023-a8e3-88336743b64f) as it will be needed for further configuration.
We also need the target connection – a client which will connect to the acquirer, for this we’ll use the NbyteHeaderTCP component again.
Open the components menu and add a new NbyteHeaderTCP component (bp::eftlab::node::ipc::NbyteHeaderTCP).
Select the bp::eftlab::node::ipc::NbyteHeaderTCP component class and name the new component as: Uplink
Save the component.
Fill the following:
Click Save.
Click “Add Plugin” button.
Pick the “bp::eftlab::node::ipc::plugins::SingleConnectionForMessageExchange”.
Click Save.
Click “Add Connection” button.
Set Connection values as followed:
Save the component.
Note the Component Id (d3ee5dde-fca3-409a-a092-f82fa438c6c6) and return back to previously created Downlink component and fill it there as the “Message Destination: d3ee5dde-fca3-409a-a092-f82fa438c6c6“.
Save the Downlink component.
Now any of the incoming messages on port 7002 is forwarded to 127.0.0.1 port 7011 or any IP and port according to your choice, you may also extend this to force tho BP-Node uplink to use SSL connection etc.
In this tutorial, we went through a part of the easy message forwarding functionality for EFTlab’s BP-Switch.