Author |
Message
|
simon.starkie |
Posted: Sun Feb 02, 2003 11:06 am Post subject: MQJMS0003: Destination not understood or no longer valid |
|
|
Disciple
Joined: 24 Mar 2002 Posts: 180
|
Good Morning,
I'm using the MA0S WEBSPHERE/MQ JMS API EXERCISER AND CODE GENERATOR support pack to better understand JMS. I eventually would like to build an abstract JMS layer over MQ and MSMQ to (hopefully) integrate both of these MOM's as a web service which will be part of our Enterprise Collaboration Architecture.
I have configured a QCF named QM1 with JMSAdmin. I can successfully connect to the QM1 QCF (the MQ Queue Manager) by using the Swing GUI that came with MA0S. To verify that QCF was properly implemented, I shutdown the QM1 Qmgr and then retried the Connect from the Swing GUI which resulted in the expected "MQJMS2005: failed to create MQQueueManager for 'QM1'" error. After this, I restarted the Qmgr and after it was completely up, I observed that resubmitting the Connect from the GUI was successful.
The problem is, when I try to browse the queue, I get the following message.
Exception thrown in jmsBrowse
javax.jms.InvalidDestinationException: MQJMS0003: Destination not understood or no longer valid
Browser returned a null message. Queue may be empty
MQ Explorer indicates the MQ queue called testQueue is definitly not empty, which suggests the "destination not understood" may be causing the problem?
My JMSAdmin definitions currently look like this:
InitCtx> display qcf(QM1)
FAILIFQUIESCE(YES)
QMANAGER(QM1)
USECONNPOOLING(YES)
TEMPMODEL(SYSTEM.DEFAULT.MODEL.QUEUE)
MSGBATCHSZ(10)
TRANSPORT(BIND)
SYNCPOINTALLGETS(NO)
MSGRETENTION(YES)
RESCANINT(5000)
POLLINGINT(5000)
VERSION(2)
InitCtx> display q(testQueue)
FAILIFQUIESCE(YES)
QMANAGER(QM1)
PERSISTENCE(APP)
CCSID(1208)
TARGCLIENT(MQ)
ENCODING(NATIVE)
PRIORITY(APP)
EXPIRY(APP)
VERSION(1)
Somehow, I'm missing something, but I can't quite see what it is.
I'm using MQ53 (the 90-day eval version with CSD01), JDK1.3.1_03, J2SDKEE 1.3.1 and Windows XP-PRO. I'm not using MA88 because the Java classes are already included in MQ53.
Any help or insight would be greatly appreciated.
Thank you. |
|
Back to top |
|
 |
simon.starkie |
Posted: Sun Feb 02, 2003 1:20 pm Post subject: User error. |
|
|
Disciple
Joined: 24 Mar 2002 Posts: 180
|
This was user error on my part.
I changed the JMSAdmin definition for the QCF to be a Client (we probably don't want to overload the MQAdministrators with lots of local Qmgrs if we can avoid it and Client seems like a plan to avoid this).
The new definitions for the QCF for QM1 looks like this now:
DELETE QF(QM1)
DEFINE QCF(QM1) +
FAILIFQUIESCE(YES) +
QMANAGER(QM1) +
TRANSPORT(CLIENT) +
CHANNEL(SYSTEM.DEF.SVRCONN) +
HOSTNAME(localhost) +
PORT(1416)
The definition for the Q looks like this now:
DELETE Q(testQueue)
DEFINE Q(testQueue) +
QMGR(QM1) +
QUEUE(testQueue)
I can now connect to the QCF using the Swing GUI, send messages to MQ and then receive/browse them.
To send messages (using the GUI's JMSQueueSender tab), I found I MUST have a queue name string in both the Queue Name field and also in the Reply Queue field. I also found I MUST also have isJNDI checked for both (so the definitions had better be in the namespace by the JMSAdmin tool). If anything is not doen this way, I get the MQJMS0003 error.
To Receive or Browse message (using the GUI's JMSQueueReceiver/QueueBrowser tab) is essentially the same--check isJNDI and all is well but you obviously only have one queue to worry about. |
|
Back to top |
|
 |
Troilus |
Posted: Tue Feb 11, 2003 2:21 am Post subject: |
|
|
Apprentice
Joined: 12 Jul 2002 Posts: 28 Location: Belgium
|
That is nice Simon, I got this far as well.
But I would like to use the queue's without having to define them all in JNDI. In other words, I do NOT want to check the IsJNDI box.
If I uncheck the IsJNDI boxes, I get the MQJMS0003 error.
How to do this ??? |
|
Back to top |
|
 |
simon.starkie |
Posted: Tue Feb 11, 2003 9:21 am Post subject: MQJMS0003 if IsJNDI boxes not checked. |
|
|
Disciple
Joined: 24 Mar 2002 Posts: 180
|
Good question. I wonder if this is a code feature. Let's see what yusuf@uk.ibm.com, the author of the MA03 Support Pack, has to say. I have sent him an Email. |
|
Back to top |
|
 |
Troilus |
Posted: Sun Feb 16, 2003 11:59 am Post subject: |
|
|
Apprentice
Joined: 12 Jul 2002 Posts: 28 Location: Belgium
|
Oops,
I am afraid this a case of rtfm.
mea culpa.
You have to put a slash in front of the queue name when the isJNDI box is not checked.
I have it all working now. |
|
Back to top |
|
 |
simon.starkie |
Posted: Tue Feb 18, 2003 8:02 pm Post subject: Yes, a slash is required if isJNDI is not checked |
|
|
Disciple
Joined: 24 Mar 2002 Posts: 180
|
Yes, a slash is required if isJNDI is not checked.
I read it after my original post too...
Everything works great for me too now.
How about those sample code snippets it generates as well.
Nice job Dr. Yusuf. Thank you.
Cheers!  |
|
Back to top |
|
 |
Larry Yusuf |
Posted: Thu Feb 20, 2003 12:58 am Post subject: problems with isJNDI |
|
|
Newbie
Joined: 20 Feb 2003 Posts: 1
|
I see you've figured how to access your queues when not using JNDI. sorry for the late reply. Been snowed under.
when not using JNDI:
specify your queues with a slash in front. E.g.
/TestQ or /TestQueueManager/TestQ -- remember to ensure that the isJNDI button is unchecked.
I hope you're finding the tool and the code snippets useful. Feel free to contact me with any other problems, concerns or suggestions |
|
Back to top |
|
 |
Troilus |
Posted: Thu Feb 20, 2003 12:59 pm Post subject: |
|
|
Apprentice
Joined: 12 Jul 2002 Posts: 28 Location: Belgium
|
It is a very nice tool Larry, especially the code snippet generating feature. I wish some of the other tools, like the API exerciser and supportpac MS10 would do this as well. |
|
Back to top |
|
 |
|