1. You can download WSO2BPS (version 1.1.1) from here. then you can extract in to a directory in your file system. Lets call as BPS_HOME
2. Start ActiveMQ message broker. Go to (ActiveMQ_Install_directory)/bin and run activemq.sh (or activemq.bin in DOS)
3. Copy ActiveMQ libraries to BPS_HOME/repository/components/lib directory
activemq-core-5.2.0.jar and geronimo-j2ee-management_1.0_spec-1.0
4. Enable JMS Transport in WSO2 BPS. Uncomment following parameters in axis2.xml (BPS_HOME/conf directory) Here I have configured it for ActiveMQ environment.
For Receiver
<parameter name="myTopicConnectionFactory">
<parameter name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
<parameter name="java.naming.provider.url">tcp://localhost:61616</parameter>
<parameter name="transport.jms.ConnectionFactoryJNDIName">TopicConnectionFactory</parameter>
</parameter>
<parameter name="myQueueConnectionFactory">
<parameter name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
<parameter name="java.naming.provider.url">tcp://localhost:61616</parameter>
<parameter name="transport.jms.ConnectionFactoryJNDIName">QueueConnectionFactory</parameter>
</parameter>
<parameter name="default">
<parameter name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
<parameter name="java.naming.provider.url">tcp://localhost:61616</parameter>
<parameter name="transport.jms.ConnectionFactoryJNDIName">QueueConnectionFactory</parameter>
</parameter>
For Sender
<transportSender name="jms"
class="org.apache.axis2.transport.jms.JMSSender"/>
5. Start BPS server running the wso2server.sh (in unix) or wso2server.bat (in windows)
You can see following Logs when starting if you have correctly configured
[2010-05-27 22:19:55,019] INFO - JMS ConnectionFactory : default initialized
[2010-05-27 22:19:55,021] INFO - JMS ConnectionFactory : myTopicConnectionFactory initialized
[2010-05-27 22:19:55,022] INFO - JMS ConnectionFactory : myQueueConnectionFactory initialized
[2010-05-27 22:19:55,022] INFO - JMS Transport Receiver/Listener initialized...
We can see JMS endpoint has been added to BPEL service (See the wsdl also)
Note:-
Step 4, You can enable JMS and configure it using UI.
Home | > Manage | > Transports |
But there are some issues when disabling JMS from UI. So i recommended to use axis2.xml configure JMS in WSO2BPS version 1.1.1. This will be fixed in next WSO2BPS release.....!!!