This section describes how to configure WSO2 ESB to send messages to a JMS Queue.
Follow the steps below to configure WSO2 ESB to accept messages via HTTP and send them to JMS queue.
Configure WSO2 ESB with Apache ActiveMQ and set up the JMS Sender. For instructions, see Configure with ActiveMQ.
Create a proxy service with the following configuration.To create a proxy service using ESB Tooling, see Working with Proxy Services via ESB Tooling.
See below, for details on how to define the JMS endpoint in the proxy configuration.
Within the inSequence, the
OUT_ONLYproperty is set to true to indicate that message exchange is one-way.
Send a message to ESB by executing the following command from
You can view the ActiveMQ queue by accessing the ActiveMQ management console using the URL
adminas both the username and password.
JMS Connection URL
To send a message to a JMS queue, we define a JMS connection URL (line numbers 7 in the configuration above) as the URL of the endpoint, which will be invoked via the send mediator.
You can define a JMS queue name and connection factory parameters in the JMS connection URL. Values of connection factory parameters depend on the type of the JMS broker. Listed below are examples of how the JMS connection URL can be defined for WSO2 Message Broker and for ActiveMQ.
When entering the following JMS connection URLs in the Management Console, be sure to replace the '
&' character in the endpoint URL with '
&' to avoid the following exception: