|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
MQ as Transport for SOAP - problem with RUNIVT.sh |
« View previous topic :: View next topic » |
Author |
Message
|
ottomann |
Posted: Wed Jan 13, 2016 10:29 pm Post subject: MQ as Transport for SOAP - problem with RUNIVT.sh |
|
|
Newbie
Joined: 13 Jan 2016 Posts: 5
|
This is a fresh install of MQ 7.5 on RHEL 6. Trying to validate SOAP sample provided with the default installation and getting following errors, appreciate any suggestion on how to debug this or what am i missing, since this is a fresh install.
As suggested in documentation i have create a copy of soap directory from samp to another location and running runivt.sh from there. I get following output of running runivt.sh as "mqm" user : |
|
Back to top |
|
 |
ottomann |
Posted: Wed Jan 13, 2016 10:32 pm Post subject: |
|
|
Newbie
Joined: 13 Jan 2016 Posts: 5
|
---------------------------------------------------------
WebSphere MQ Transport for SOAP Install Verification Test
---------------------------------------------------------
NB. If failures occur run SOAPCleanup.sh before
re-running the test
Checking and configuring the Java environment
> ------------------------------------------ Successful
Setting up the queue manager and req/resp queues
> ------------------------------------------ Successful
Deploying the Axis service
> ------------------------------------------ Successful
Compling the Axis clients
> ------------------------------------------ Successful
* + Creating client deployment descriptor
> ------------------------------------------ Successful
Running Axis samples......
Queue manager being used is WMQSOAP.DEMO.QM
----- [AxisWsdl] --------------------------------
WMQ transport test: Axis to Axis, using WSDL Axis calls
OpenJDK 64-Bit Server VM warning: You have loaded library /opt/mqm/java/lib/libmqjbnd.so which might have disabled stack guard. The VM will try to fix the stack guard now.
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.
MQJE001: Completion Code '2', Reason '2495'.
+++ server: ./generated/server/startWMQJListener.sh
--- client: java soap.clients.WsdlClient
start WsdlClient demo, wsdl port soap.server.StockQuoteAxis_Wmq resolving uri to ...
Jan 14, 2016 6:14:59 PM org.apache.axis.utils.JavaUtils isAttachmentSupported
WARNING: Unable to find required classes (javax.activation.DataHandler and javax.mail.internet.MimeMultipart). Attachment support is disabled.
'jms:/queue?destination=SOAPJ.demos@WMQSOAP.DEMO.QM&connectionFactory=(connectQueueManager(WMQSOAP.DEMO.QM))&initialContextFactory=com.ibm.mq.jms.Nojndi&targetService=soap.server.StockQuoteAxis.java&replyDestination=SYSTEM.SOAP.RESPONSE.QUEUE'
OpenJDK 64-Bit Server VM warning: You have loaded library /opt/mqm/java/lib/libmqjbnd.so which might have disabled stack guard. The VM will try to fix the stack guard now.
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.
MQJE001: Completion Code '2', Reason '2495'.
>>> EXCEPTION WHILE RUNNING WsdlClient DEMO <<<
AxisFault
************** TEST FAILED !! TEST FAILED !! TEST FAILED *************
EXPECTED: Response: 55.25
ACTUAL:
**********************************************************************
----- [AxisProxy] --------------------------------
WMQ transport test: Axis to Axis, using Axis proxy client
--- client: java soap.clients.SQAxis2Axis jms:/queue?destination=SOAPJ.demos@WMQSOAP.DEMO.QM&connectionFactory=connectQueueManager(WMQSOAP.DEMO.QM)clientConnection(localhost%25289414%2529)clientChannel(TESTCHANNEL)&replyDestination=SYSTEM.SOAP.RESPONSE.QUEUE&initialContextFactory=com.ibm.mq.jms.Nojndi
Jan 14, 2016 6:15:02 PM org.apache.axis.utils.JavaUtils isAttachmentSupported
WARNING: Unable to find required classes (javax.activation.DataHandler and javax.mail.internet.MimeMultipart). Attachment support is disabled.
MQJE001: Completion Code '2', Reason '2033'.
AxisFault
>>> EXCEPTION WHILE RUNNING ProxyClient DEMO <<<
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.generalException
************** TEST FAILED !! TEST FAILED !! TEST FAILED *************
EXPECTED: Response: 55.25
ACTUAL:
**********************************************************************
----------------------------------
OpenJDK 64-Bit Server VM warning: You have loaded library /opt/mqm/java/lib/libmqjbnd.so which might have disabled stack guard. The VM will try to fix the stack guard now.
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.
MQJE001: Completion Code '2', Reason '2495'.
===========================================
2 tests run, of which 2 failed.
FAILED TESTS:
=============
AxisWsdl
AxisProxy |
|
Back to top |
|
 |
fjb_saper |
Posted: Thu Jan 14, 2016 5:41 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Switch to a client connection and you'd be fine.
Or run with
Code: |
export IBM_JAVA_OPTIONS=-Djava.library.path="/opt/mqm/java/lib64"
OR
export LD_LIBRARY_PATH=/opt/mqm/java/lib64:$LD_LIBRARY_PATH |
Your error log shows you running with a 64 bit JVM but attempting to access the 32 bit libraries to achieve a server connection....  _________________ MQ & Broker admin |
|
Back to top |
|
 |
ottomann |
Posted: Thu Jan 14, 2016 11:57 pm Post subject: |
|
|
Newbie
Joined: 13 Jan 2016 Posts: 5
|
Thanks @fjb_saper. Trying to run 32 bin binary on 64 machine was plain wrong and such a newbie thing.
However i am hitting another error after fixing the first : "MQJE001: Completion Code '2', Reason '2033'." which, what i could find, means that there are no messages in the queue and a "get" is called. Clueless about this one, since this a fresh install and from my understanding i have followed all steps that are required for this soap sample to run. (Please note i have added mail.jar and activation.jar to classpath and data handler error is removed :) )
# ./runivt.sh
---------------------------------------------------------
WebSphere MQ Transport for SOAP Install Verification Test
---------------------------------------------------------
NB. If failures occur run SOAPCleanup.sh before
re-running the test
Checking and configuring the Java environment
> ------------------------------------------ Successful
Setting up the queue manager and req/resp queues
l > ------------------------------------------ Successful
Deploying the Axis service
> ------------------------------------------ Successful
Compling the Axis clients
> ------------------------------------------ Successful
* + Creating client deployment descriptor
> ------------------------------------------ Successful
Running Axis samples......
Queue manager being used is WMQSOAP.DEMO.QM
Checking Queue Manager WMQSOAP.DEMO.QM is available...
Setting up required MQ queues...
Checking runmqlsr...
----- [AxisWsdl] --------------------------------
WMQ transport test: Axis to Axis, using WSDL Axis calls
+++ server: ./generated/server/startWMQJListener.sh
--- client: java soap.clients.WsdlClient
start WsdlClient demo, wsdl port soap.server.StockQuoteAxis_Wmq resolving uri to ...
'jms:/queue?destination=SOAPJ.demos@WMQSOAP.DEMO.QM&connectionFactory=(connectQueueManager(WMQSOAP.DEMO.QM))&initialContextFactory=com.ibm.mq.jms.Nojndi&targetService=soap.server.StockQuoteAxis.java&replyDestination=SYSTEM.SOAP.RESPONSE.QUEUE'
MQJE001: Completion Code '2', Reason '2033'.
>>> EXCEPTION WHILE RUNNING WsdlClient DEMO <<<
AxisFault
************** TEST FAILED !! TEST FAILED !! TEST FAILED *************
EXPECTED: Response: 55.25
ACTUAL:
**********************************************************************
----- [AxisProxy] --------------------------------
WMQ transport test: Axis to Axis, using Axis proxy client
--- client: java soap.clients.SQAxis2Axis jms:/queue?destination=SOAPJ.demos@WMQSOAP.DEMO.QM&connectionFactory=connectQueueManager(WMQSOAP.DEMO.QM)clientConnection(localhost%25289414%2529)clientChannel(TESTCHANNEL)&replyDestination=SYSTEM.SOAP.RESPONSE.QUEUE&initialContextFactory=com.ibm.mq.jms.Nojndi
MQJE001: Completion Code '2', Reason '2033'.
AxisFault
>>> EXCEPTION WHILE RUNNING ProxyClient DEMO <<<
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.generalException
************** TEST FAILED !! TEST FAILED !! TEST FAILED *************
EXPECTED: Response: 55.25
ACTUAL:
**********************************************************************
----------------------------------
===========================================
2 tests run, of which 2 failed.
FAILED TESTS:
=============
AxisWsdl
AxisProxy |
|
Back to top |
|
 |
zpat |
Posted: Fri Jan 15, 2016 3:19 am Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
MQRC 2033 can be considered a successful check of the queue. It was empty at the time.
You can use the get wait (aka receivetimeout) for MQ to wait until a message arrives (or the wait interval elapsed) - but you will still get a 2033 at some point and need to handle it.
You may wish to sleep and then repeat the get, what you do not want to do is immediately retry it without any sleep and without any wait interval or your program will go into a tight loop, whilst thrashing the QM. _________________ Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error. |
|
Back to top |
|
 |
ottomann |
Posted: Sun Jan 17, 2016 10:16 pm Post subject: |
|
|
Newbie
Joined: 13 Jan 2016 Posts: 5
|
Thanks @zpat, from my limited understanding the Soap sample should have worked in a fresh install, with no changes to code like the addition of retry which sounds logical.
From what i understand in the client code, the client code calls a getQuote(...) api on the proxy stub. It appears like a local jvm object call. But underneath the Axis+Soap magic is supposed to take this "locally appearing" call to the remote server (over tcp, taking care of marshalling/demarshalling soap headers etc) and return result back from the server.
Also i am unable to understand how exactly MQSoap message flow is ? I have deployed a MQ server on linux and was able to write a Java client which connects to the QManager over TCP and successfully does put and get messages from a queue.
But wanted to get the out of the box soap sample running before i started creating a mq soap client. Stuck at getting the out of the box sample working. |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Jan 18, 2016 6:16 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Well you are looking at a request reply set up.
So before you run the SOAP Client (request), you need to run the SOAP server part (stub that will create your reply). Otherwise you will get a 2033...
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
ottomann |
Posted: Tue Jan 19, 2016 1:37 am Post subject: |
|
|
Newbie
Joined: 13 Jan 2016 Posts: 5
|
Your logic seems right, if there is nothing in the queue get will return with this error. But when i run out of the box runIVT.sh, it does start the SOAP listener (this is believe should be the server). So isn't the server running behind the SOAP listener port supposed to consume the SOAP request from one queue, and post its response into the response queue which should be available for the client to consume. I can see by running a "amqsbcg" on the request queue that the SOAP request is present.
But it just remains there, and client on the other hand gets no messages available error when it does the get.
It sounds like the server is not running, because it is not consuming the request and not posting the response in the response queue.
Again, isn't the out of the box runIVT.sh handling starting the server ? I see that the listener port has started on the machine (from netstat), the request/response queues are started, but how do i confirm that there is a server configured to consume requests and post responses ? |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Jan 19, 2016 5:22 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
ottomann wrote: |
Again, isn't the out of the box runIVT.sh handling starting the server ? I see that the listener port has started on the machine (from netstat), the request/response queues are started, but how do i confirm that there is a server configured to consume requests and post responses ? |
Check the ipprocs of the request queue. Verify the transaction boundaries. Remember the request cannot be consumed until it is committed.
So if there are no ipprocs on the request queue, it means that nobody is consuming the request.
I thought the IVT could be run either in client mode (default) or in server mode (see parameters to pass)?
If so start the server mode first from a different window...  _________________ MQ & Broker admin |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|