Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

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

Table of Contents
maxLevel5

...

Simulating the sample scenario

Send a request using Stock Quote client to the proxy service in the following manner. For information on the Stock Quote client, refer to the Sample Clients section in WSO2 ESB documentation. 

ant stockquote -Dtrpurl=http://localhost:8280/services/StockQuoteProxy -Dsymbol=WSO2

Note that the request is stored in WSO2 Message Broker. Any consumer can access the stored message by accessing destinationMyQueue in WSO2 Message Broker.

How the implementation works

...

  • jms:/myqueue - Looks for a JNDI entry myqueue (see JNDI properties above).
  • ? - Separator indicating extra attributes.
  • transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory - Looks up ConnectionFactory in JNDI with name QueueConnectionFactory.
  • &  - Separator (this will convert to ‘&’)
  • java.naming.factory.initial=org.wso2.andes.jndi.PropertiesFileInitialContextFactory - Uses the andes properties-based JNDI.
  • &  - Another separator (this will convert to ‘&’)
  • java.naming.provider.url=repository/conf/jndi.properties - Looks in repository/conf/jndi.properties for the JNDI properties file.