MQ Monitor logs error during shutdown due attempt to call method that does not exist.

Document ID : KB000125664
Last Modified Date : 01/02/2019
Show Technical Document Details
Issue:
MQ Monitor agent monitoring IIB v9 (and IIB fieldpack monitoring IIB v10) both report an error message on shutdown

MQ Monitor agent: Exception in thread "Thread-9" java.lang.NoSuchMethodError: com/ibm/mq/jms/Cleanup.cleanup()V at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.MBStatisticsCleanup.cleanQueue(MBStatisticsCleanup.java:396) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.MBStatisticsCleanup.doCleanup(MBStatisticsCleanup.java:362) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.v7.MBTreeConfigMain.processCleaning(MBTreeConfigMain.java:639) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.v7.MBTreeConfigMain.access$2(MBTreeConfigMain.java:606) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.v7.MBTreeConfigMain$1.run(MBTreeConfigMain.java:224) IIB 10 field pack agent: Exception in thread "Thread-10" java.lang.NoSuchMethodError: com/ibm/mq/jms/Cleanup.cleanup()V (loaded from file:/opt/mqm/java/lib/com.ibm.mq.allclient.jar by sun.misc.Launcher$AppClassLoader@861c2567) called from class com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.MBStatisticsCleanup (loaded from file:/opt/mqmmon/N1INWB01/iibagent/MQMonitor/MQMonitor.jar by sun.misc.Launcher$AppClassLoader@861c2567). at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.MBStatisticsCleanup.cleanQueue(MBStatisticsCleanup.java:396) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.MBStatisticsCleanup.doCleanup(MBStatisticsCleanup.java:362) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.v7.MBTreeConfigMain.processCleaning(MBTreeConfigMain.java:745) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.v7.MBTreeConfigMain.access$2(MBTreeConfigMain.java:717) at com.wily.powerpack.websphereMQ.agent.MQMonitor.MBMonitor.v7.MBTreeConfigMain$1.run(MBTreeConfigMain.java:232)

There is no advserse impact of this message on functionality
Environment:
MQ monitor with MQ 7.5 or high and IIB / MB monitoring enabled - all agent versions up to 10.7 SP2
Cause:
The problem  relates to the MQ version in use the cleanup method has one variant in 8.0

void  cleanup(boolean runAtRegularIntervals)

https://www.ibm.com/support/knowledgecenter/en/SSFKSJ_8.0.0/com.ibm.mq.javadoc.doc/WMQJMSClasses/com/ibm/mq/jms/Cleanup.html

where as in 7.1 it has 2

void  cleanup()
void  cleanup(boolean runAtRegularIntervals)

The call made by the agent assumes the method wiith parameters is available
Resolution:
A test fix has been verified for this and teh fix will be rolled into the next agent release