This documentation is for WSO2 Business Activity Monitor 2.2.0. View documentation for the latest release.

Unknown macro: {next_previous_link3}
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

You can send events to multiple BAM/CEP receivers in load balanced manner. That is, you can send the same event to many BAM/CEP receivers, and you can also load balance within some set of servers.And also, this handles the fail over problem, which means when the events are load balanced within a set of servers, if one receiver became unreachable, it'll automatically send the events to other available active BAM receivers.

The major three scenarios where you can use this functionality is described below.

Scenario - 1 (Only load balancing within a set of servers)

The above depicted setup shows the load balancing the event publishing among all three BAM receivers. The load balanced publishing is done in a 'Round Robin' manner, which sends each event to each receiver in a circular order without any priority. It also handles the fail over cases such as say if BAM Receiver -1 is marked down, then the Data agent will only send the data among the BAM Receiver -2 & BAM Receiver -3 in round robin manner. And If BAM receiver becomes active after some time, the data agent will automatically detect it add it to the operation and again will start to load balance within all three receivers. This functionality reduces the data loss significantly, and provide more high concurrency.

Foe this functionality, you only need to include the server URL in the data agent as below as just comma separated value of general BAM receiver URLs:

Receiver URL= tcp://<BAM Receiver -1>:<port>,tcp://<BAM Receiver -2>:<port>,tcp://<BAM Receiver -3>:<port>

[Here <BAM Receiver – 1, 2, 3> can be host name or IP addresses. And <port> is corresponding port of BAM receivers]

Eg: tcp://10.100.2.32:7611, tcp://10.100.2.33:7611, tcp://10.100.2.34:7611

Scenario -2 (Sending a event to more than one receivers)


The above depicted diagram shows sending all events to more than one BAM receiver. That is mainly used where you are using other servers to analyze your events with BAM servers. For example, the you can use the same data agents to publish the events to WSO2 CEP also, and you can use this functionality to publish the same event to both BAM and CEP server same time by which you can do some real time analytics with CEP and persists and so some complex analysis with BAM in nearly real time.

Same as 1st scenario, here also it's a matter of modifying the data agent URL. The following will show the pattern of the URL for this scenario. Here you should include all BAM/CEP receivers urls within curly braces ({}), and seperate with comma.

Receiver URL = {tcp://<BAM Receiver -1>:<port>}, {tcp://<BAM Receiver -2>:<port>}, {tcp://<BAM Receiver -3>:<port>}

[Here <BAM Receiver – 1, 2, 3> can be host name or IP addresses. And <port> is corresponding port of BAM receivers]

Eg: {tcp://10.100.2.32:7611},{ tcp://10.100.2.33:7611}, {tcp://10.100.2.34:7611}

Scenario - 3 (Sending events to more than one receivers with load balancing)

As depicted in above picture, there are two set of servers A and B. And you can send the events to both set of servers, and you can do load balancing as mentioned in scenario-1. This scenario is the combination of scenario -1 and scenario -2. That means a event will be sent to both severs set A and B, within A set it will be sent either for A-1 or A-2 receiver and within B set, it'll be sent either to B-1 or B-2. Here only two sets of servers and two servers per set is shown as an example, neither of theese numbers are need not to be confined to this, you can any number of sets and any number of servers as you require. But you should mention this properly in the server URL.

As described in above use cases, here also you can describe this as receiver URL. The sets should be mentioned in within curly braces and it should be separated by comma. Further more, each receivers that belongs to the set should be within the curly braces and within the curly braces the receiver URLs should be comma separated. The receiver URL format is given below.

Receiver URL = {tcp://<BAM Receiver -A-1>:<port>, tcp://<BAM Receiver -A-2>:<port>},{tcp://<BAM Receiver -B-1>:<port>, tcp://<BAM Receiver -B-2>:<port>}

[Here <BAM Receiver – A-(1, 2), B- (1, 2)> can be host name or IP addresses. And <port> is corresponding port of BAM receivers]

Eg: {tcp://10.100.2.32:7611, tcp://10.100.2.33:7611}, {tcp://10.100.2.34:7611, tcp://10.100.2.35:7611}

 

Above all three are different ways to use the data agents with multiple receivers with load balancing functionality. All three scenarios and has it own advantages depends on your requirement.

 

  • No labels