You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Ines Dannehl <In...@loyaltypartner.com> on 2008/03/28 12:35:27 UTC
SOAP with JMS and JBoss
Hi all,
I'm using a webservice with Axis2 version 1.1.1 deployed to JBoss
4.0.5.GA within an ear file. This works fine with the HTTP transport
protocol.
Now, I have to switch to the JMS transport protocol. Has anybody
experiences with this subject?
I did the following steps but without success:
1. axis2.xml: I uncommented the JMS transportReceiver and
transportSender.
2. ActiveMQ: I followed the steps to integrate the Apache ActiveMQ
with JBoss as decribed in
http://activemq.apache.org/integrating-apache-activemq-with-jboss.html
3. Client: I changed the URL to
jms:/StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConn
ectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.Activ
eMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61616
The result is that I get no response:
2008-03-28 12:13:39,286 WARN
org.apache.axis2.transport.jms.JMSOutTransportInfo - Cannot get or
lookup JMS destination : StockQuoteService from url : jms:/
StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConnectio
nFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQIn
itialContextFactory&java.naming.provider.url=tcp://localhost:61616 :
StockQuoteService
2008-03-28 12:14:10,023 WARN org.apache.axis2.transport.jms.JMSSender -
Did not receive a JMS response within 30000 ms to destination : queue://
StockQuoteService
2008-03-28 12:14:10,070 FATAL - org.apache.axis2.AxisFault: Incoming
message input stream is null
There is no entry in the servers logfile that indicates that the called
webservice operation was executed.
When I try to setup the following option in the client:
Stub._getServiceClient().getOptions().setUseSeparateListener(true);
I get the following exception:
2008-03-28 12:25:37,037 FATAL - org.apache.axis2.AxisFault: Unknown
transport jms
When I use the simple Axis2 server from the distribution I get the rigth
response although I also get the warning:
2008-03-28 12:13:39,286 WARN
org.apache.axis2.transport.jms.JMSOutTransportInfo - Cannot get or
lookup JMS destination : StockQuoteService from url : jms:/
StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConnectio
nFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQIn
itialContextFactory&java.naming.provider.url=tcp://localhost:61616 :
StockQuoteService
The test example from the ActiveMQ integration with JBoss also works
fine.
Has anybody an idea what is wrong with my JBoss or webservice or
ActiveMQ configuration?
Thanks for help and best regards!
Ines
AW: SOAP with JMS and JBoss
Posted by Ines Dannehl <In...@loyaltypartner.com>.
Hi,
I got it working. I think the patch given in
http://issues.apache.org/jira/browse/AXIS2-1488 is incomplete.
The JMS listener is initialized but it is not startet! Therefore I
patched the patch as follows:
protected void initializeAllTransportReceiversButHttp(ListenerManager
listenerManager ) {
QName httpTransportName = new QName(Constants.TRANSPORT_HTTP);
Iterator transportNames =
axisConfiguration.getTransportsIn().values().iterator();
while (transportNames.hasNext()) {
try {
TransportInDescription transportInDescription =
(TransportInDescription) transportNames.next();
if
(!transportInDescription.getName().getLocalPart().equals(httpTransportNa
me.getLocalPart())) {
TransportListener listener =
transportInDescription.getReceiver();
listener.init(configContext,
transportInDescription);
listener.start();
listenerManager.addListener(transportInDescription,
true);
log.debug("Transport receiver [" +
transportInDescription.getName() + "] has been initialized.");
}
} catch (Exception e) {
log.error(e);
}
}
}
I'm surprised that there is no fixed Axis2 version. Also Axis2 version
1.3 does not work with JMS and JBoss (the patch is not included).
I think it is a blocker for Axis2. Nobody will use the simple axis
server in production environment and JMS becomes more and more
important.
Will there be a fix in the near future?
Ines
________________________________
Von: Upul Godage [mailto:upulg.dev@gmail.com]
Gesendet: Dienstag, 8. April 2008 16:01
An: axis-user@ws.apache.org
Betreff: Re: AW: SOAP with JMS and JBoss
Hi,
Could you go through all the destinations in JBoss and see where Axis2
service is listening. If there are no errors in the Axis2 console, it
should be listening in somewhere :-).
Isolate the service and the JBoss. Don't start anything else.
Go to http://localhost:8080/jmx-console/.
Go to jboss.mq.destination section.
Go to each destination under that heading.
See whether SubscribersCount or ReceiversCount has a 1 instead of 0.
Then that is where the service is listening.
If there is nothing, copy and send the Axis2 server startup log.
Also could you check with the latest Axis2 1.3.
Upul
On Tue, Apr 8, 2008 at 6:04 PM, Ines Dannehl
<In...@loyaltypartner.com> wrote:
Hi Upul,
the queue seems to be correct. There are also messages in. But nobody
listens to the queue. I found a bug report for Axis2 version 1.1.1
http://issues.apache.org/jira/browse/AXIS2-1488
Therefore I tried the patch given (for AxisServlet.java). Now I get the
following error message in the JBoss logfile:
ERROR [AxisServlet] java.lang.ClassCastException:
org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl
Which is thrown while initializing the JMS transport listener:
listener.init(configContext, transportInDescription);
My axis2.xml looks like that.
<transportReceiver name="jms"
class="org.apache.axis2.transport.jms.JMSListener">
<parameter name="default" locked="false">
<parameter name="java.naming.factory.initial"
locked="false">org.jnp.interfaces.NamingContextFactory</parameter>
<parameter name="java.naming.provider.url"
locked="false">jnp://localhost:1199</parameter>
<parameter name="transport.jms.ConnectionFactoryJNDIName"
locked="false">QueueConnectionFactory</parameter>
</parameter>
</transportReceiver>
What is wrong?
Ines
________________________________
Von: Upul Godage [mailto:upulg.dev@gmail.com]
Gesendet: Freitag, 4. April 2008 04:59
An: axis-user@ws.apache.org <ma...@ws.apache.org>
Betreff: Re: AW: SOAP with JMS and JBoss
May be client is using StockQuoteService and the server is listening on
queue/StockQuoteService. Start jboss and the server and see whether
service is listening to the destination. You can check that from the
JBoss jmx-console, going to the relevent destination page and checking
the receiversCount or something. Also check where client is sending the
message from the console by the message count listed in the relevent
destination.
Upul
On Thu, Apr 3, 2008 at 6:05 PM, Ines Dannehl
<In...@loyaltypartner.com> wrote:
Hi Asankha,
I can't find out the correct full JNDI name of the queue. I get the log
message:
2008-04-03 14:23:24,659 INFO
[org.jboss.mq.server.jmx.Queue.StockQuoteService] Bound to JNDI name:
queue/StockQuoteService
But when I use queue/StockQuoteService as JNDI name it's still the same.
I also wonder that there is no exception when I give a sure non-existing
JNDI name in the configuration you recommended (e.g. BLABLA).
Do you have some experiences with the JBoss configuration?
Regards
Ines
________________________________
Von: Asankha C. Perera [mailto:asankha@wso2.com]
Gesendet: Mittwoch, 2. April 2008 10:44
An: axis-user@ws.apache.org
Betreff: Re: AW: SOAP with JMS and JBoss
Ines
It seems like the request was sent to the right queue but the webservice
is not listening to the queue. I did no special configuration for the
webservice. Therefore I think it should listen to a queue with the
service name (StockQuoteService). Do I need a special message receiver?
The StockQuoteService from the Axis2 example has the message receiver
Yes, now its getting into a Queue, but the Queue name is not properly
bound to the service. On your services' services.xml add the following
parameter
<parameter name="transport.jms.Destination"
locked="true">thefullJNDINameOfYourDestination</parameter>
Ref: http://ws.apache.org/axis2/1_3/jms-transport.html
asankha
Re: AW: SOAP with JMS and JBoss
Posted by Upul Godage <up...@gmail.com>.
Hi,
Could you go through all the destinations in JBoss and see where Axis2
service is listening. If there are no errors in the Axis2 console, it should
be listening in somewhere :-).
Isolate the service and the JBoss. Don't start anything else.
Go to http://localhost:8080/jmx-console/.
Go to jboss.mq.destination section.
Go to each destination under that heading.
See whether SubscribersCount or ReceiversCount has a 1 instead of 0. Then
that is where the service is listening.
If there is nothing, copy and send the Axis2 server startup log.
Also could you check with the latest Axis2 1.3.
Upul
On Tue, Apr 8, 2008 at 6:04 PM, Ines Dannehl <
Ines.Dannehl@loyaltypartner.com> wrote:
> Hi Upul,
>
>
>
> the queue seems to be correct. There are also messages in. But nobody
> listens to the queue. I found a bug report for Axis2 version 1.1.1
> http://issues.apache.org/jira/browse/AXIS2-1488
>
> Therefore I tried the patch given (for AxisServlet.java). Now I get the
> following error message in the JBoss logfile:
>
>
>
> ERROR [AxisServlet] java.lang.ClassCastException:
> org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl
>
>
>
> Which is thrown while initializing the JMS transport listener:
>
>
>
> listener.init(configContext, transportInDescription);
>
>
>
>
>
> My axis2.xml looks like that.
>
>
>
> <transportReceiver name="jms"
> class="org.apache.axis2.transport.jms.JMSListener">
>
> <parameter name="default" locked="false">
>
> <parameter name="java.naming.factory.initial"
> locked="false">org.jnp.interfaces.NamingContextFactory</parameter>
>
> <parameter name="java.naming.provider.url"
> locked="false">jnp://localhost:1199</parameter>
>
> <parameter name="transport.jms.ConnectionFactoryJNDIName"
> locked="false">*QueueConnectionFactory*</parameter>
>
> </parameter>
>
> </transportReceiver>
>
>
>
> What is wrong?
>
>
>
> Ines
>
>
> ------------------------------
>
> *Von:* Upul Godage [mailto:upulg.dev@gmail.com]
> *Gesendet:* Freitag, 4. April 2008 04:59
> *An:* axis-user@ws.apache.org
> *Betreff:* Re: AW: SOAP with JMS and JBoss
>
>
>
> May be client is using StockQuoteService and the server is listening on
> queue/StockQuoteService. Start jboss and the server and see whether service
> is listening to the destination. You can check that from the JBoss
> jmx-console, going to the relevent destination page and checking the
> receiversCount or something. Also check where client is sending the message
> from the console by the message count listed in the relevent destination.
>
> Upul
>
> On Thu, Apr 3, 2008 at 6:05 PM, Ines Dannehl <
> Ines.Dannehl@loyaltypartner.com> wrote:
>
> Hi Asankha,
>
>
>
> I can't find out the correct full JNDI name of the queue. I get the log
> message:
>
>
>
> 2008-04-03 14:23:24,659 INFO
> [org.jboss.mq.server.jmx.Queue.StockQuoteService] Bound to JNDI name:
> queue/StockQuoteService
>
>
>
> But when I use queue/StockQuoteService as JNDI name it's still the same.
>
>
>
> I also wonder that there is no exception when I give a sure non-existing
> JNDI name in the configuration you recommended (e.g. BLABLA).
>
>
>
> Do you have some experiences with the JBoss configuration?
>
>
>
> Regards
>
> Ines
>
>
> ------------------------------
>
> *Von:* Asankha C. Perera [mailto:asankha@wso2.com]
> *Gesendet:* Mittwoch, 2. April 2008 10:44
>
>
> *An:* axis-user@ws.apache.org
>
> *Betreff:* Re: AW: SOAP with JMS and JBoss
>
>
>
> Ines
>
> It seems like the request was sent to the right queue but the webservice
> is not listening to the queue. I did no special configuration for the
> webservice. Therefore I think it should listen to a queue with the service
> name (StockQuoteService). Do I need a special message receiver? The
> StockQuoteService from the Axis2 example has the message receiver
>
> Yes, now its getting into a Queue, but the Queue name is not properly
> bound to the service. On your services' services.xml add the following
> parameter
>
> <parameter name="transport.jms.Destination" locked="true">thefullJNDINameOfYourDestination</parameter>
>
>
>
> Ref: http://ws.apache.org/axis2/1_3/jms-transport.html
>
>
>
> asankha
>
>
>
>
>
AW: AW: SOAP with JMS and JBoss
Posted by Ines Dannehl <In...@loyaltypartner.com>.
Hi Upul,
the queue seems to be correct. There are also messages in. But nobody
listens to the queue. I found a bug report for Axis2 version 1.1.1
http://issues.apache.org/jira/browse/AXIS2-1488
Therefore I tried the patch given (for AxisServlet.java). Now I get the
following error message in the JBoss logfile:
ERROR [AxisServlet] java.lang.ClassCastException:
org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl
Which is thrown while initializing the JMS transport listener:
listener.init(configContext, transportInDescription);
My axis2.xml looks like that.
<transportReceiver name="jms"
class="org.apache.axis2.transport.jms.JMSListener">
<parameter name="default" locked="false">
<parameter name="java.naming.factory.initial"
locked="false">org.jnp.interfaces.NamingContextFactory</parameter>
<parameter name="java.naming.provider.url"
locked="false">jnp://localhost:1199</parameter>
<parameter name="transport.jms.ConnectionFactoryJNDIName"
locked="false">QueueConnectionFactory</parameter>
</parameter>
</transportReceiver>
What is wrong?
Ines
________________________________
Von: Upul Godage [mailto:upulg.dev@gmail.com]
Gesendet: Freitag, 4. April 2008 04:59
An: axis-user@ws.apache.org
Betreff: Re: AW: SOAP with JMS and JBoss
May be client is using StockQuoteService and the server is listening on
queue/StockQuoteService. Start jboss and the server and see whether
service is listening to the destination. You can check that from the
JBoss jmx-console, going to the relevent destination page and checking
the receiversCount or something. Also check where client is sending the
message from the console by the message count listed in the relevent
destination.
Upul
On Thu, Apr 3, 2008 at 6:05 PM, Ines Dannehl
<In...@loyaltypartner.com> wrote:
Hi Asankha,
I can't find out the correct full JNDI name of the queue. I get the log
message:
2008-04-03 14:23:24,659 INFO
[org.jboss.mq.server.jmx.Queue.StockQuoteService] Bound to JNDI name:
queue/StockQuoteService
But when I use queue/StockQuoteService as JNDI name it's still the same.
I also wonder that there is no exception when I give a sure non-existing
JNDI name in the configuration you recommended (e.g. BLABLA).
Do you have some experiences with the JBoss configuration?
Regards
Ines
________________________________
Von: Asankha C. Perera [mailto:asankha@wso2.com]
Gesendet: Mittwoch, 2. April 2008 10:44
An: axis-user@ws.apache.org
Betreff: Re: AW: SOAP with JMS and JBoss
Ines
It seems like the request was sent to the right queue but the webservice
is not listening to the queue. I did no special configuration for the
webservice. Therefore I think it should listen to a queue with the
service name (StockQuoteService). Do I need a special message receiver?
The StockQuoteService from the Axis2 example has the message receiver
Yes, now its getting into a Queue, but the Queue name is not properly
bound to the service. On your services' services.xml add the following
parameter
<parameter name="transport.jms.Destination"
locked="true">thefullJNDINameOfYourDestination</parameter>
Ref: http://ws.apache.org/axis2/1_3/jms-transport.html
asankha
Re: AW: SOAP with JMS and JBoss
Posted by Upul Godage <up...@gmail.com>.
May be client is using StockQuoteService and the server is listening on
queue/StockQuoteService. Start jboss and the server and see whether service
is listening to the destination. You can check that from the JBoss
jmx-console, going to the relevent destination page and checking the
receiversCount or something. Also check where client is sending the message
from the console by the message count listed in the relevent destination.
Upul
On Thu, Apr 3, 2008 at 6:05 PM, Ines Dannehl <
Ines.Dannehl@loyaltypartner.com> wrote:
> Hi Asankha,
>
>
>
> I can't find out the correct full JNDI name of the queue. I get the log
> message:
>
>
>
> 2008-04-03 14:23:24,659 INFO
> [org.jboss.mq.server.jmx.Queue.StockQuoteService] Bound to JNDI name:
> queue/StockQuoteService
>
>
>
> But when I use queue/StockQuoteService as JNDI name it's still the same.
>
>
>
> I also wonder that there is no exception when I give a sure non-existing
> JNDI name in the configuration you recommended (e.g. BLABLA).
>
>
>
> Do you have some experiences with the JBoss configuration?
>
>
>
> Regards
>
> Ines
>
>
> ------------------------------
>
> *Von:* Asankha C. Perera [mailto:asankha@wso2.com]
> *Gesendet:* Mittwoch, 2. April 2008 10:44
> *An:* axis-user@ws.apache.org
> *Betreff:* Re: AW: SOAP with JMS and JBoss
>
>
>
> Ines
>
> It seems like the request was sent to the right queue but the webservice
> is not listening to the queue. I did no special configuration for the
> webservice. Therefore I think it should listen to a queue with the service
> name (StockQuoteService). Do I need a special message receiver? The
> StockQuoteService from the Axis2 example has the message receiver
>
> Yes, now its getting into a Queue, but the Queue name is not properly
> bound to the service. On your services' services.xml add the following
> parameter
>
> <parameter name="transport.jms.Destination" locked="true">thefullJNDINameOfYourDestination</parameter>
>
>
>
> Ref: http://ws.apache.org/axis2/1_3/jms-transport.html
>
>
>
> asankha
>
>
>
AW: AW: SOAP with JMS and JBoss
Posted by Ines Dannehl <In...@loyaltypartner.com>.
Hi Asankha,
I can't find out the correct full JNDI name of the queue. I get the log
message:
2008-04-03 14:23:24,659 INFO
[org.jboss.mq.server.jmx.Queue.StockQuoteService] Bound to JNDI name:
queue/StockQuoteService
But when I use queue/StockQuoteService as JNDI name it's still the same.
I also wonder that there is no exception when I give a sure non-existing
JNDI name in the configuration you recommended (e.g. BLABLA).
Do you have some experiences with the JBoss configuration?
Regards
Ines
________________________________
Von: Asankha C. Perera [mailto:asankha@wso2.com]
Gesendet: Mittwoch, 2. April 2008 10:44
An: axis-user@ws.apache.org
Betreff: Re: AW: SOAP with JMS and JBoss
Ines
It seems like the request was sent to the right queue but the webservice
is not listening to the queue. I did no special configuration for the
webservice. Therefore I think it should listen to a queue with the
service name (StockQuoteService). Do I need a special message receiver?
The StockQuoteService from the Axis2 example has the message receiver
Yes, now its getting into a Queue, but the Queue name is not properly
bound to the service. On your services' services.xml add the following
parameter
<parameter name="transport.jms.Destination"
locked="true">thefullJNDINameOfYourDestination</parameter>
Ref: http://ws.apache.org/axis2/1_3/jms-transport.html
asankha
Re: AW: SOAP with JMS and JBoss
Posted by "Asankha C. Perera" <as...@wso2.com>.
Ines
>
> It seems like the request was sent to the right queue but the
> webservice is not listening to the queue. I did no special
> configuration for the webservice. Therefore I think it should listen
> to a queue with the service name (StockQuoteService). Do I need a
> special message receiver? The StockQuoteService from the Axis2 example
> has the message receiver
>
Yes, now its getting into a Queue, but the Queue name is not properly
bound to the service. On your services' services.xml add the following
parameter
<parameter name="transport.jms.Destination" locked="true">thefullJNDINameOfYourDestination</parameter>
Ref: http://ws.apache.org/axis2/1_3/jms-transport.html
asankha
AW: SOAP with JMS and JBoss
Posted by Ines Dannehl <In...@loyaltypartner.com>.
Hi Asankha,
I removed the ActiveMQ JMS provider now. I use the JBossMQ JMS provider
coming with JBoss. Therefore I made the following changes:
Axis2.xml:
<transportReceiver name="jms"
class="org.apache.axis2.transport.jms.JMSListener">
<parameter name="default" locked="false">
<parameter name="java.naming.factory.initial"
locked="false">org.jnp.interfaces.NamingContextFactory</parameter>
<parameter name="java.naming.provider.url"
locked="false">jnp://localhost:1199</parameter>
<parameter name="transport.jms.ConnectionFactoryJNDIName"
locked="false">ConnectionFactory</parameter>
</parameter>
</transportReceiver>
Client:
url = "jms:/" +
"StockQuoteService" +
"?transport.jms.ConnectionFactoryJNDIName=ConnectionFactory" +
"&java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory" +
"&java.naming.provider.url=jnp://localhost:1199";
JBoss jbossmq-destinations-service.xml:
<mbean code="org.jboss.mq.server.jmx.Queue"
name="jboss.mq.destination:service=Queue,name=StockQuoteService">
<depends
optional-attribute-name="DestinationManager">jboss.mq:service=Destinatio
nManager</depends>
</mbean>
The effect is that the client sends a JMS message to the queue
StockQuoteService. But I get no response (client log):
2008-04-02 09:27:32,587 DEBUG org.jboss.mq.il.uil2.UILClientILService -
Starting
2008-04-02 09:27:32,712 DEBUG org.apache.axis2.transport.jms.JMSSender -
[Client]Sending message to destination : QUEUE.StockQuoteService
2008-04-02 09:27:32,774 DEBUG org.apache.axis2.transport.jms.JMSSender -
Waiting for a maximum of 30000ms for a response message to destination :
QUEUE.JMS_TQ1
2008-04-02 09:28:02,775 WARN org.apache.axis2.transport.jms.JMSSender -
Did not receive a JMS response within 30000 ms to destination :
QUEUE.StockQuoteService
2008-04-02 09:28:02,775 DEBUG org.jboss.mq.il.uil2.SocketManager - End
ReadTask.run
2008-04-02 09:28:02,775 DEBUG org.jboss.mq.il.uil2.UILClientILService -
Stopping
2008-04-02 09:28:02,775 DEBUG org.jboss.mq.il.uil2.SocketManager - End
WriteTask.run
2008-04-02 09:28:02,869 FATAL com.billit.client -
org.apache.axis2.AxisFault: Incoming message input stream is null
It seems like the request was sent to the right queue but the webservice
is not listening to the queue. I did no special configuration for the
webservice. Therefore I think it should listen to a queue with the
service name (StockQuoteService). Do I need a special message receiver?
The StockQuoteService from the Axis2 example has the message receiver
public class StockQuoteServiceMessageReceiverInOut extends
org.apache.axis2.receivers.AbstractInOutSyncMessageReceiver ...
Any ideas?
Regards!
Ines
________________________________
Von: Asankha C. Perera [mailto:asankha@wso2.com]
Gesendet: Mittwoch, 2. April 2008 08:43
An: axis-user@ws.apache.org
Betreff: Re: SOAP with JMS and JBoss
Ines
1. axis2.xml: I uncommented the JMS transportReceiver and
transportSender.
So does the configuration now point to an ActiveMQ JMS provider
instance?
1. ActiveMQ: I followed the steps to integrate the Apache ActiveMQ
with JBoss as decribed in
http://activemq.apache.org/integrating-apache-activemq-with-jboss.html
I am not familiar with this.. but why would you want to integrate
ActiveMQ with JBoss? You can select either of these as your JMS provider
and just use it..
1. Client: I changed the URL to
jms:/StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConn
ectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.Activ
eMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61616
This obviously points to ActiveMQ
The result is that I get no response:
2008-03-28 12:13:39,286 WARN
org.apache.axis2.transport.jms.JMSOutTransportInfo - Cannot get or
lookup JMS destination : StockQuoteService from url : jms:/
StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConnectio
nFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQIn
itialContextFactory&java.naming.provider.url=tcp://localhost:61616 :
StockQuoteService
This means that there was no JMS destination named "StockQuoteService"
found on the JNDI when using the given properties (listed out in the
warning message).. Usually, AMQ creates destinations "on demand" but I
think other providers like JBoss requires you to create these before
hand. Since you have done some 'integration' of the two, I am not sure
what is valid.. you could use a JMS sample client like the QueueBrowser
or JConsole to see if the destination actually exists and visible when
using the above params
asankha
Re: SOAP with JMS and JBoss
Posted by "Asankha C. Perera" <as...@wso2.com>.
Ines
>
> 1. axis2.xml: I uncommented the JMS transportReceiver and
> transportSender.
>
So does the configuration now point to an ActiveMQ JMS provider instance?
>
> 1. ActiveMQ: I followed the steps to integrate the Apache ActiveMQ
> with JBoss as decribed in
> http://activemq.apache.org/integrating-apache-activemq-with-jboss.html
>
I am not familiar with this.. but why would you want to integrate
ActiveMQ with JBoss? You can select either of these as your JMS provider
and just use it..
>
> 1. Client: I changed the URL to
> jms:/StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61616
>
This obviously points to ActiveMQ
> The result is that I get no response:
>
> 2008-03-28 12:13:39,286 WARN
> org.apache.axis2.transport.jms.JMSOutTransportInfo - Cannot get or
> lookup JMS destination : StockQuoteService from url : jms:/
> StockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61616
> : StockQuoteService
>
This means that there was no JMS destination named "StockQuoteService"
found on the JNDI when using the given properties (listed out in the
warning message).. Usually, AMQ creates destinations "on demand" but I
think other providers like JBoss requires you to create these before
hand. Since you have done some 'integration' of the two, I am not sure
what is valid.. you could use a JMS sample client like the QueueBrowser
or JConsole to see if the destination actually exists and visible when
using the above params
asankha
Re: SOAP with JMS and JBoss
Posted by KleinM <ma...@content-software.com>.
Hi,
I followed the discussion with a lot of interest, since I had (still have)
the same (similar problems) installing Axis2 1.3 with JMS transport on JBoss
4.0.3SP1.
I made the following observation. If within
../deploy/jbossweb-tomcat55.sar/META-INF/jboss-service.xml the attribute
UseJBossWebLoader is set to "false" the webservice will not be registered
automatically during deployment at the specified JMS-Queue. If the attribute
is set to "true" the webservice will be registered automatically. You can
see that by checking the "ReceiversCount" value in the corresponding MBean
and by a log message in server.log:
[org.apache.axis2.transport.jms.JMSConnectionFactory] Mapping JNDI name :
queue/StockQuoteService and JMS Destination name : StockQuoteService against
service : StockQuoteService
Please note that this is working without applying any patch, or patch of
patch (listener.start();).
I am wondering how that can be!
Unfortunately running the deployment with UseJBossWebLoader=true causes the
Axis2 validation check to fail, because of different versions of the same
library coming from JBoss and Axis2. The error is
ERROR (http-0.0.0.0-8080-2)
[org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/axis2].[jsp]]
Servlet.service() for servlet jsp threw exception
java.lang.NoSuchMethodError:
org.apache.commons.httpclient.HttpConnectionManager.getParams()Lorg/apache/commons/httpclient/params/HttpConnectionManagerParams;
at
org.apache.axis2.transport.http.AbstractHTTPSender.initializeTimeouts(AbstractHTTPSender.java:441)
at
org.apache.axis2.transport.http.AbstractHTTPSender.getHttpClient(AbstractHTTPSender.java:496)
at
org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:158)
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
at
org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
at
org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
at
org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
at
org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:528)
at
org.apache.axis2.client.ServiceClient.sendReceive(ServiceClient.java:508)
at
org.apache.jsp.axis2_002dweb.HappyAxis_jsp.invokeTheService(org.apache.jsp.axis2_002dweb.HappyAxis_jsp:338)
at
org.apache.jsp.axis2_002dweb.HappyAxis_jsp._jspService(org.apache.jsp.axis2_002dweb.HappyAxis_jsp:494)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at
org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
at
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:407)
at
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
at java.lang.Thread.run(Thread.java:595)
If UseJBossWebLoader=false the validation check returns OKAY, but the
webservice will not be connected to the JMS-Queue, and there are no errors
shown in the log.
Any help on how to configure JBoss and Axis2 the right way would be
appreciated.
KleinM
--
View this message in context: http://www.nabble.com/SOAP-with-JMS-and-JBoss-tp16350791p16895130.html
Sent from the Axis - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org