Using automatic client reconnection in Java EE environments

The IBM® MQ resource adapter, which can be deployed into Java EE (Java Platform, Enterprise Edition) environments, and the WebSphere® Application Server IBM MQ messaging provider use the IBM MQ classes for JMS to communicate with IBM MQ queue managers. The IBM MQ resource adapter and the WebSphere Application Server IBM MQ messaging provider provide support for automatic client reconnection.

The options available to provide automatic client reconnection in a Java EE environment are:
  • Activation specification
  • WebSphere Application Server listener ports
  • Enterprise JavaBeans and web-based applications
  • Applications running inside client containers
Note: Automatic client reconnection with activation specifications using the functionality provided by IBM MQ classes for JMS is not supported. The IBM MQ resource adapter provides its own mechanism for reconnecting activation specifications if the queue manager that the activation specification was connecting to becomes unavailable.

This mechanism is controlled by:

  • The IBM MQ resource adapter property reconnectionRetryCount.
  • The IBM MQ resource adapter property reconnectionRetryInterval.
  • The activation specification property connectionNameList.

For more information on these properties, see Configuration for ResourceAdapter object properties.

The use of automatic client reconnection within a message-driven bean application's onMessage() method, or any other application that is running within the Java Platform, Enterprise Edition environment is not supported. The application needs to implement its own reconnection logic if the queue manager it was connecting to becomes unavailable.