Problem determination for the IBM MQ resource adapter

When using the IBM MQ resource adapter, most errors cause exceptions to be thrown, and these exceptions are reported to the user in a manner that depends on the application server. The resource adapter makes extensive use of linked exceptions to report problems. Typically, the first exception in a chain is a high-level description of the error, and subsequent exceptions in the chain provide the more detailed information that is required to diagnose the problem.

For example, if the IVT program fails to obtain a connection to a IBM MQ queue manager, the following exception might be thrown:
javax.jms.JMSException: MQJCA0001: An exception occurred in the JMS layer.
See the linked exception for details.
Linked to this exception is a second exception:
javax.jms.JMSException: MQJMS2005: failed to create an MQQueueManager for
'localhost:ExampleQM'
This exception is thrown by IBM MQ classes for JMS and has a further linked exception:
com.ibm.mq.MQException: MQJE001: An MQException occurred: Completion Code 2,
Reason 2059
This final exception indicates the source of the problem. Reason code 2059 is MQRC_Q_MGR_NOT_AVAILABLE, which indicates that the queue manager specified in the definition of the ConnectionFactory object might not have been started.

If the information provided by exceptions is not sufficient to diagnose a problem, you might need to request a diagnostic trace. For information about how to enable diagnostic tracing, see Configuration of the IBM MQ resource adapter.

Configuration problems commonly occur in the following areas:

  • Deploying the resource adapter
  • Deploying MDBs
  • Creating connections for outbound communication