APAR status
Closed as program error.
Error description
A MQ classes for JMS v8.0.0.10 application is running inside the Hitachi Cosminexus application server on the Linux (x86-64) platform, using the Hitachi JVM. Multiple threads attempt to connect to a z/OS queue manager concurrently, where the queue manager is running in the CCSID 1399. Occasionally when these threads initially attempt to connect, the following NullPointerException is thrown and the connection attempt fails: java.lang.NullPointerException at java.util.TreeMap.deleteEntry(TreeMap.java:2340) at java.util.TreeMap.remove(TreeMap.java:608) at com.ibm.mq.jmqi.system.JmqiCodepage$JmqiCodepageFactory.initiali zeCodepage(JmqiCodepage.java:307) at com.ibm.mq.jmqi.system.JmqiCodepage$JmqiCodepageFactory.getByCcs id(JmqiCodepage.java:189) at com.ibm.mq.jmqi.system.JmqiCodepage.getJmqiCodepage(JmqiCodepage .java:720) at com.ibm.mq.jmqi.system.JmqiCodepage.getJmqiCodepage(JmqiCodepage .java:682) at com.ibm.mq.jmqi.remote.impl.RemoteConnection.initSess(RemoteConn ection.java:1476) at com.ibm.mq.jmqi.remote.impl.RemoteConnection.connect(RemoteConne ction.java:1007) at com.ibm.mq.jmqi.remote.impl.RemoteConnectionSpecification.getSes sionFromNewConnection(RemoteConnectionSpecification.java:409) at com.ibm.mq.jmqi.remote.impl.RemoteConnectionSpecification.getSes sion(RemoteConnectionSpecification.java:305) at com.ibm.mq.jmqi.remote.impl.RemoteConnectionPool.getSession(Remo teConnectionPool.java:155) at com.ibm.mq.jmqi.remote.api.RemoteFAP.jmqiConnect(RemoteFAP.java: 1724) at com.ibm.mq.jmqi.remote.api.RemoteFAP.jmqiConnect(RemoteFAP.java: 1288) at com.ibm.mq.ese.jmqi.InterceptedJmqiImpl.jmqiConnect(InterceptedJ mqiImpl.java:376) at com.ibm.mq.ese.jmqi.ESEJMQI.jmqiConnect(ESEJMQI.java:560) at com.ibm.msg.client.wmq.internal.WMQConnection.<init>(WMQConnecti on.java:356) at com.ibm.msg.client.wmq.internal.WMQXAConnection.<init>(WMQXAConn ection.java:67) at com.ibm.msg.client.wmq.factories.WMQXAConnectionFactory.createV7 ProviderConnection(WMQXAConnectionFactory.java:188) at com.ibm.msg.client.wmq.factories.WMQConnectionFactory.createProv iderConnection(WMQConnectionFactory.java:7913) at com.ibm.msg.client.wmq.factories.WMQXAConnectionFactory.createPr oviderXAConnection(WMQXAConnectionFactory.java:98) at com.ibm.msg.client.jms.admin.JmsConnectionFactoryImpl.createXACo nnectionInternal(JmsConnectionFactoryImpl.java:347) at com.ibm.mq.jms.MQXAQueueConnectionFactory.createXAQueueConnectio n(MQXAQueueConnectionFactory.java:168) at com.ibm.mq.jms.MQXAQueueConnectionFactory.createXAConnection(MQX AQueueConnectionFactory.java:116) at com.ibm.mq.connector.ConnectionBuilder.createConnection(Connecti onBuilder.java:195) at com.ibm.mq.connector.outbound.ManagedQueueConnectionFactoryImpl. createConnection(ManagedQueueConnectionFactoryImpl.java:197) at com.ibm.mq.connector.outbound.ManagedConnectionImpl.<init>(Manag edConnectionImpl.java:173) at com.ibm.mq.connector.outbound.ManagedQueueConnectionImpl.<init>( ManagedQueueConnectionImpl.java:74) at com.ibm.mq.connector.outbound.ManagedQueueConnectionFactoryImpl. createManagedConnection(ManagedQueueConnectionFactoryImpl.java:1 51) at com.hitachi.software.ejb.cm.connector.ConnectorResourceFactory.c reate(ConnectorResourceFactory.java:338) ... ... ...
Local fix
Problem summary
**************************************************************** USERS AFFECTED: User of the MQ classes for Java/JMS, including users of the MQ Managed File Transfer. Platforms affected: MultiPlatform **************************************************************** PROBLEM DESCRIPTION: When the MQ classes for Java/JMS connects to a queue manager, it negotiates a common communication protocol between the queue manager and the MQ classes for Java/JMS. Part of this negotiation includes determining if the JVM has Charset support for the Coded Character Set Identifier (CCSID) that the queue manager is running in. The MQ classes for Java/JMS uses a class named: com.ibm.mq.jmqi.system.JmqiCodepage.getJmqiCodepage to determine if the JVM has support for a specific CCSID. This class contains two objects of the type: java.util.TreeMap which permit the mapping between IBM CCSID integer values, and Java java.nio.charset.Charset names. If the JVM does not have support for the requested Charset, then the MQ classes for Java/JMS optimises future requests for Charset support by removing these mappings from the TreeMap set. However, if multiple application threads were connecting to the queue manager in parallel and the CCSID was not supported by the JVM, then it was possible that more than one thread would try and remove the entry concurrently, leading to a java.lang.NullPointerException to be thrown by the JVM, with a stack of the form: java.lang.NullPointerException at java.util.TreeMap.deleteEntry at java.util.TreeMap.remove at com.ibm.mq.jmqi.system.JmqiCodepage$JmqiCodepageFactory.initiali zeCodepage at com.ibm.mq.jmqi.system.JmqiCodepage$JmqiCodepageFactory.getByCcs id at com.ibm.mq.jmqi.system.JmqiCodepage.getJmqiCodepage at com.ibm.mq.jmqi.system.JmqiCodepage.getJmqiCodepage In order to encounter this problem, you require an environment where: (a) The queue manager's CCSID is not supported by the JVM (b) Multiple application threads are connecting to the queue manager concurrently
Problem conclusion
The MQ classes for Java/JMS has been updated to add Java locking around the updating of the java.util.TreeMap object to ensure that this issue no longer occurs. --------------------------------------------------------------- The fix is targeted for delivery in the following PTFs: Version Maintenance Level v9.0 LTS 9.0.0.12 v9.1 LTS 9.1.0.9 v9.2 LTS 9.2.0.4 v9.x CD 9.2.4 The latest available maintenance can be obtained from 'WebSphere MQ Recommended Fixes' http://www-1.ibm.com/support/docview.wss?rs=171&uid=swg27006037 If the maintenance level is not yet available information on its planned availability can be found in 'WebSphere MQ Planned Maintenance Release Dates' http://www-1.ibm.com/support/docview.wss?rs=171&uid=swg27006309 ---------------------------------------------------------------
Temporary fix
Comments
APAR Information
APAR number
IT37224
Reported component name
IBM MQ BASE MP
Reported component ID
5724H7251
Reported release
800
Status
CLOSED PER
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt / Xsystem
Submitted date
2021-06-11
Closed date
2021-06-24
Last modified date
2021-06-24
APAR is sysrouted FROM one or more of the following:
APAR is sysrouted TO one or more of the following:
Fix information
Fixed component name
IBM MQ BASE MP
Fixed component ID
5724H7251
Applicable component levels
[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSYHRD","label":"IBM MQ"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"8.0.0.0","Line of Business":{"code":"LOB45","label":"Automation"}}]
Document Information
Modified date:
04 February 2022