axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anthony Bull <anthony.b...@bcsoft.co.nz>
Subject Re: JMS
Date Wed, 18 Jul 2007 20:50:06 GMT
I set my Axis 2 instance to use Apache Active MQ using the examples on 
the Axis 2 documentation.  What are your specific problems?

The steps I followed were:
1. Setup Active MQ as standard.
2. Change the axis2.xml file under the axis2 webapp context on Tomcat so 
that the JMS transport receiver and sender elements were active (as 
follows):

    <transportReceiver name="jms" 
class="org.apache.axis2.transport.jms.JMSListener">
        <parameter name="myTopicConnectionFactory" 
locked="false">                       
            <parameter name="java.naming.factory.initial" 
locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" 
locked="false">tcp://localhost:61616</parameter>           
            <parameter name="transport.jms.ConnectionFactoryJNDIName" 
locked="false">TopicConnectionFactory</parameter>
        </parameter>

        <parameter name="myQueueConnectionFactory" 
locked="false">                       
            <parameter name="java.naming.factory.initial" 
locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" 
locked="false">tcp://localhost:61616</parameter>           
            <parameter name="transport.jms.ConnectionFactoryJNDIName" 
locked="false">QueueConnectionFactory</parameter>
        </parameter>

        <parameter name="default" locked="false">                       
            <parameter name="java.naming.factory.initial" 
locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" 
locked="false">tcp://localhost:61616</parameter>           
            <parameter name="transport.jms.ConnectionFactoryJNDIName" 
locked="false">QueueConnectionFactory</parameter>
        </parameter>
    </transportReceiver>

    <transportSender name="jms"
                     class="org.apache.axis2.transport.jms.JMSSender"/>

3. And finally installed the basic EchoXMLService I found on the Axis2 
documentation example. Its a simple one class web service, where the 
only different is that it specifies a JMS transport in its services.xml 
file as follows:

<service name="EchoXMLService">
    <description>
        This is a sample Web Service for JMS tests.
    </description>
    <parameter name="ServiceClass" 
locked="false">org.apache.axis2.jms.Echo</parameter>
    <operation name="echoOMElementNoResponse">
        <messageReceiver 
class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/>
        <actionMapping>urn:echoOMElementNoResponse</actionMapping>
    </operation>
    <operation name="echoOMElement">
        <messageReceiver 
class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/>
        <actionMapping>urn:echoOMElement</actionMapping>
    </operation>

    <transports>
      <transport>jms</transport>
    </transports>
    <parameter name="transport.jms.ConnectionFactory" 
locked="true">myQueueConnectionFactory</parameter>
    <parameter name="transport.jms.Destination" 
locked="true">dynamicQueues/TestQueue</parameter>
</service>

4. I'm moving over to WebSphere MQ as the MOM provider, but haven't got 
that far yet - but I assume its only a change to the JNDI properties in 
axis2.xml as is the case with other JMS stuff.

cheers,
Ants.

Mike Krell wrote:
> Does anyone know how to configure JMS to be used with Axis?  I've read 
> the docs and samples and I'm still struggling.  Thanks


-- 
Anthony
-------------------------------------
Anthony Bull
Senior Developer
Black Coffee Software Ltd
PO Box 10-192 The Terrace
Wellington, New Zealand

anthony.bull@bcsoft.co.nz
Ph  +64 4 472 8818
Fax +64 4 472 8811
Mobile 021 303 692
-------------------------------------
www.bcsoft.co.nz
---------------------------------------------------------------
This email may contain confidential or privileged information,
and is intended for use only by the addressee, or addressees.
If you are not the intended recipient please advise the sender
immediately and do not copy, use or disclose the contents to
any other person or organisation.
Black Coffee Software Ltd accepts no responsibility for viruses
received with this email, or to any changes made to the original
content. Any views or opinions expressed in this email may be
personal to the sender and are not necessarily those of Black
Coffee Software Ltd.
---------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message