Sending a message from a stand-alone Java client to a queue or topic defined within the MQ Simulator JMS provider fails with MQJMS2005, reason code 2012
 Technote (troubleshooting)
 
Problem(Abstract)
When a client running outside of the Java™ virtual machine (JVM) process in the WebSphere® Application Server tries to send a message to an MQ Simulator for Java Developers (MQ Simulator) queue or topic, the MQJMS2005 exception with reason code 2012 occurs.
 
Cause
WebSphere Studio Application Developer V5 ships with a technology called MQ Simulator for Java Developers (MQ Simulator), which is a pure Java, low-footprint Java Message Service (JMS) provider that is accessible to WebSphere Application Server V5.0 test environments. This technology does not function within WebSphere Application Server outside of WebSphere Studio.

This problem is due to a limitation with the MQ Simulator JMS provider. It does not support any inter-process communication. When a client that runs outside of the JVM process in WebSphere Application Server tries to send a message to an MQ Simulator queue or topic, the MQJMS2005 exception with reason code 2012 occurs. Only applications that run within the JVM process in WebSphere Application Server can access MQ Simulator. This limitation includes enterprise beans, servlets, and JavaServer Pages (JSP) files.

 
Resolving the problem
To avoid the problem, either:
  • Send the messages from an enterprise bean, a servlet, or a JavaServer Pages file running within the WebSphere Test Environment JVM process to the queue or topic defined within MQ Simulator.
  • Use embedded messaging rather than MQ Simulator. The installation of embedded messaging is an option in the WebSphere Studio installation wizard. This option must be selected to be installed. When it is installed, embedded messaging is used by default in WebSphere Studio V5.0 and V5.0.1. In WebSphere Studio V5.1, the JMS provider must be selected on the JMS tab of the WebSphere Application Server V5.0 configuration (see the following screen shot). When embedded messaging is used, messages can be sent from clients that run outside of the JVM process in WebSphere Application Server and the MQJMS exception with reason code 2012 does not occur.

 
 
Cross Reference information
Segment Product Component Platform Version Edition
Software Development WebSphere Studio Application Developer JMS Linux, Windows 5.0, 5.0.1, 5.1, 5.1.1 Edition Independent
Application Servers Runtimes for Java Technology Java SDK
 
 


Document Information


Product categories: Software > Application Servers > Distributed Application & Web Servers > WebSphere Application Server > Java Message Service (JMS)
Operating system(s): Windows
Software version: 5.1.1
Software edition:
Reference #: 1157887
IBM Group: Software Group
Modified date: Sep 10, 2004