Versions Compared

Key

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

You can configure any type of JMS event adapter to run with WSO2 products. This guide discusses how to configure a few common types. You can receive XML, Map, JSON and Text events using JMS transport.

Excerpt
hiddentrue

NOTE TO WRITERS: Add the "children display" macro here.

Child pages (Children Display)

 

 

 

WSO2 MB as Input JMS Event Adaptor

Follow the instructions below to configure WSO2 Message Broker (MB) as a JMS-Qpid Input Event Adaptor.

...

Download and install Message Broker as described in the Message Broker documentation .

...

  • <W SO2MB_HOME>/ client-lib/ andes-client-xx.jar    
  • <WSO2MB_HOME>/ client-lib/ geronimo-j2ee-management_1.1_spec-1.0.1xx.jar    

You can configure this adaptor through the management console as explained below or by manually adding an XML file as explained in step 7.

...

No Format
Event Adaptor Name                  : MBJmsInputAdaptor
Event Adaptor Type                  : jms
JNDI Initial Context Factory Class  : org.wso2.andes.jndi.PropertiesFileInitialContextFactory (file-based JNDI properties)
URL of the JNDI provider            : repository/conf/jndi.properties
Connection Factory JNDI Name        : TopicConnectionFactory
Destination Type                    : topic
Enable Durable Subscription         : false
Info

This is the jndi.properties file in <PRODUCT_HOME>/reposiyory/conf directory. This example uses Topic Connection Factory. Therefore, the following entry points the default Qpid Host to localhost and port to 5672:
connectionfactory.TopicConnectionFactory = amqp:
//admin:admin@clientid/carbon?brokerlist='tcp://localhost:5673' (MB starts with offset 1)

...

Create the XML file with the following WSO2Event event adaptor configurations. Input event adaptor implementation must start with <inputEventAdaptor> root element.

Code Block
languagehtml/xml
<inputEventAdaptor name="MBJmsInputAdaptor" statistics="disable"
  trace="disable" type="jms" xmlns="http://wso2.org/carbon/eventadaptormanager">
  <property name="java.naming.provider.url">repository/conf/jndi.properties</property>
  <property name="transport.jms.SubscriptionDurable">false</property>
  <property name="java.naming.factory.initial">org.wso2.andes.jndi.PropertiesFileInitialContextFactory</property>
  <property name="transport.jms.ConnectionFactoryJNDIName">TopicConnectionFactory</property>
  <property name="transport.jms.DestinationType">topic</property>
</inputEventAdaptor>

You can configure JMS event adaptors with Map, XML, JSON & Text Input  Mapping.

Note

Note: When using WSO2 MB as the Input Event Adaptor, at the time you define the Topic, which is a message-related property, follow the syntax Burl :{topic}. That is, add "Burl :" as the prefix of the actual topic. (When using with MB 2.0.1)

...