InvalidDestinationException: MQJMS0003: Destination not understood or no longer valid
网上几点总结: ①======================================================================================= Question 4: A WSAS administrator notices the following error in the SystemOut.log: javax.jms.InvalidDestinationException: Which of the following could have caused this error? A. The JMS destination requires IIOP protocol for access. The JMS client is using the default JMS message protocol. The use of an (instanceof MQQueue) test was returning false ②======================================================================================= Explanation: The queue or topic may have become unavailable, the application may be using an incorrect connection for the queue or topic, or the supplied destination is not of the correct type for this method. queue or topic. ③======================================================================================= ************************************************************************************************************************************************** instanceOf operator of java would return false for objects of the same class if they are being loaded by different classloaders. In my case i had many webapplications and the Queue object was got by a jndi lookup. Now when first time this code is executed it all works fine for a application but when you start using anohter web application the same code fails and throws the InvalidDestinationException . The reason being the 2 objects on which ibm code is doing instanceof are loaded by different classloaders. The Solution to this problem is delete all the ibm jars (com.ibm.mq.jar and com.ibm.mqjms.jar) from individual web application and add these in the servers lib directory. Now all instances are loaded by the server classloader and not by webappclassloaders . This is a criptic issue which took me 2 days to figure out. wfac错误原因: |