Versions Compared

Key

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

This section explains, through an example scenario, how the Control Bus EIP can be implemented using WSO2 ESB. The following topics are covered:

Table of Contents

...

Start the ESB server and log into its management console UI (https://localhost:9443/carbon). In the management console, navigate to the Main Menu, click Service Bus and then Source View menu and click Source View in the Service Bus section. Next, copy and paste the following configuration, which helps you explore the example scenario, to the source view.

Anchor
step3
step3

...

  • sequence [line 11 in ESB config] - The main sequence, which is the default in the ESB. 
  • throttle [line 13 in ESB config] - Defines a throttling policy in WS-Policy. 
  • WS-Policy Assertion [line 18 in ESB config] - The WS-Policy assertion throttle:MaximumConcurrentAccess defines the number of concurrent connections that can be made. 
  • onReject [line 22 in ESB config] - The onReject element of the Throttle mediator defines what to do if the policy is rejected. The maximum number of concurrent connections at present exceeds 4. In this example, if the policy is rejected, the message is logged and a fault is returned to the client using makeFault with message 'access is denied'. 
  • onAccept [line 35 in ESB config] - The onAccept element of the Throttle mediator defines what to do when the policy is accepted. The maximum number of concurrent connections at present does not exceed 4. In this example, if the policy is accepted, the message is passed on to the service endpoint.