Monday, August 11, 2008

Changes to Apache CXF JMS transport to allow jmsDestination name

Recently Apache CXF JMS transport is modified in order to allow use of jmsDestinationName and jmsReplyDestinationName. Till now CXF JMS only allowed using jndi destination names to lookup queue/destination and was not able to use jms destination names to create queues/topics.

Here is the diff of the schema change to specify the jmsDestinationName and jmsReplyDestinationName.

Example jms:address looks like this:

<jms:address jndiconnectionfactoryname="ConnectionFactory"
<jms:jmsnamingproperty name="java.naming.factory.initial"
<jms:jmsnamingproperty name="java.naming.provider.url"

This will allow CXF consumer and services to use the real queue names (where JMS provider will allow the creation of the queues) as opposed to use jndi lookup.


Christian Schneider said...

That is a step in the right direction. Would it be possible to make CXFs JMS Tranport a little more like in camel? For example you simply configure a ConnectionFactory as a spring bean and reference it in the JMS transport. Currently we use CXF based on JMS in my company. But as configuring JMS in CXF is not very easy and clear we use the Camel tranport and then setup the JMS routing in camel. It is not ideal that we have to include another project in our runtime but the configuration using cxf and camel together looks much cleaner. I will post an example of this shortly on the Camel and CXF Wiki.

Mazya uchapati (my low-tech efforts) said...

Hi Christian,
You are right on point. Next thing on the plan based on the time is to allow CXF JMS transport to use Spring JMS and implement SPECJMS support.

shan said...


Just wanted to know if it is possible
to create a client to send SOAP request to output queue and receive message from input queue using CXF?


Mazya uchapati (my low-tech efforts) said...

Hi Shan,

You can use any client to send soap request in JMS message. CXF doesn't mandate that you should use CXF client to send SOAP request. As long as SOAP request is valid CXF Server will process it and if you specify replyto queue it will send the reply onto replyto queue.