Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

BAM Mediator is a mediator for WSO2 ESB that captures data events from the ESB mediation sequences and sends to any server with a listening Thrift port such as WSO2 BAM or WSO2 CEP servers. The Thrift port receives data events via a Thrift API. It uses a binary protocol and enables fast data transmission between the ESB and a Thrift port.

...

The following sections explain how to use the existing BAM Mediator configuration when editing a mediation sequence, using a sample scenario.

Table of Contents
maxLevel4
minLevel4

Configuring

...

server profiles and streams
Anchor
Configure BAM Server Profiles and Streams
Configure BAM Server Profiles and Streams

Before adding a BAM mediator to a mediator sequence, you must update the BAM mediator configurations. Configuration information is considered as a set of BAM server profiles, which contain transport and credential data required to connect to the BAM server. In each BAM server profile, you must define one or many event stream configurations. Streams contain Thrift API event stream related information like Stream Name, Stream Version etc. and the data to be extracted from the configuration context of the mediation sequence. The steps below explain this.

...

  1. Go to <ESB_HOME>/samples/axis2Server/src/SimpleStockQuoteService and build the backend service with Apache Ant (You must have Apache Ant installed).
  2. Go to <ESB_HOME>/samples/axis2Server and run the Axis2 server.

    • In Linux: axis2server.sh
    • In Windows: axis2server.bat
  3. Test whether the proxy service WSDL exists in http://localhost:9000/services/SimpleStockQuoteService?wsdl.

Adding a proxy service to

...

the ESB

These are the steps to create a sample WSDL Proxy Service to test the BAM mediator.

  1. Go to ESB management console and select Main→Web Services→Add→Proxy Service from the side panel.
  2. Click Based Proxy to create a new WSDL based proxy.
  3. Fill the form as follows:
    1. Insert a suitable Proxy Service Name (eg: Simple_Stock_Quote_Service_Proxy)
    2. Set http://localhost:9000/services/SimpleStockQuoteService?wsdl as the WSDL URI
    3. Set SimpleStockQuoteService as the WSDL service
    4. Set SimpleStockQuoteServiceHttpSoap11Endpoint as the WSDL Port
  4. Click Create.
  5. Click on the newly created proxy's name (Simple_Stock_Quote_Service_Proxy in this case) to go to its dashboard.

Adding

...

BAM Mediator to WSDL proxy service

After creating a sample WSDL proxy service, the user can add one or more BAM mediators to the sequence of WSDL Proxy Service as follows.

...

The BAM mediator is now added to the WSDL proxy service named Simple_Stock_Quote_Service_Proxy.

...

Sending messages to the ESB

Before you test the BAM mediator, finish all steps discussed above. In this section, we send custom messages through the WSDL proxy service created earlier and test whether they are correctly stored in a Cassandra database. This is an example, but the same steps apply in any a production scenario, using any Thrift listening port.

...