Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

...

This component has been deprecated in favor to servicemix-jms component.

...

If you wish to customize the marshalling from NMS to JMS or vice versa you can customize the JmsMarshaler used to perform the mapping.

...

...

If you wish to process messages in a high performance setting and want to use connection & thread pooling, transaction & exception & retry handling and want to support parallel processing of inbound messages we recommend you use the JCA support for inbound JMS messages.

...

Receiving JMS messages

The JmsReceiverComponent subscribes to the given destination using Spring's JmsTemplate and dispatches the message into the JBI container. Here's an example of subscribing to a JMS destination (in this case a topic) and forwarding the JBI message onto another JBI component - which in this case is the foo:transformer service.

...

...

If you wish to use JCA or some other mechanism to subscribe to JMS you can use the JmsInBinding.

...

The JmsSenderComponent will send JMS messages from the input message exchange. This component uses Spring's JmsTemplate to perform the sending. The following example demonstrates a component which when invoked will send a message to a given JMS topic

...

...

JMS bridges

Its a very common requirement to create a message bridge; routing messages from one messaging system to another. With ServiceMix we can connect any transport with any transport - but for now lets focus on JMS to JMS bridging. Imagine for example you wish to route messages from ActiveMQ to MQSeries, or from WebLogic JMS to ActiveMQ.

The following example demonstrates how to setup a JMS bridge in ServiceMix

...

This example is performing an XSLT transform on the messages as well - you can perform arbitrary processing of the messages in the bridge, performing rules processing or content based routing. Obviously you could miss out the transformation step and just route the inbound message on one JMS provider to another JMS provider without any transform step.