activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From B&W <trabelsi.a...@gmail.com>
Subject activemq with axis2
Date Tue, 30 Oct 2007 13:58:03 GMT

Hello,

I'm trying to deploy a web service on axis2 using JMS transport.
I'm using tomcat 6.0.13, axis2 1.2 and activemq 4.1

here is my services.xml file : 
<service>
  
 <transports> 
    <transport>jms</transport> 
  </transports>
 
  <parameter name="transport.jms.ConnectionFactory"
locked="true">myQueueConnectionFactory</parameter>
  <parameter name="transport.jms.Destination"
locked="true">QueueConnectionFactory</parameter>

    <description>
        sample web service using JMS
    </description>
    <parameter name="ServiceClass"
locked="false">service.MyService</parameter>
   
    <operation name="addNumbers">
    	<messageReceiver
class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/>  
        <actionMapping>urn:addNumbers</actionMapping>
         
    </operation>
 </service>

and here is the part of axis2.xml used to activate the JMS transport on
axis2

<transportReceiver name="jms"
class="org.apache.axis2.transport.jms.JMSListener">
        <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>
    </transportReceiver> 

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



I put the necessary activemq jars in the tomcat lib directory.

My problem is when I start tomcat, I get this exception : 
org.apache.activemq.ActiveMQConnectionFactory cannot be cast to
javax.jms.Destination

Has someone any idea about the solution of this problem?

Thanks in advance
-- 
View this message in context: http://www.nabble.com/activemq-with-axis2-tf4718624s2354.html#a13489206
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message