Topic
  • 2 replies
  • Latest Post - ‏2016-12-16T14:14:54Z by DSerbin
Imey
Imey
1 Post

Pinned topic Creating MQHeaderIterator Problem

‏2009-10-20T08:42:38Z |
Hi, all

I am using MQ v7.0 and programming against a funtion to get the headers from a message, but after

MQHeaderIterator iter = new MQHeaderIterator(rcvMessage);

I got an exception:

Exception in thread "main" java.lang.NoClassDefFoundError: com/ibm/mq/headers/internal/CachingHeader
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$000(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at com.ibm.mq.headers.MQHeaderRegistry.class$(MQHeaderRegistry.java:91)
at com.ibm.mq.headers.MQHeaderRegistry.getDefault(MQHeaderRegistry.java:98)
at com.ibm.mq.headers.MQHeaderIterator.<init>(MQHeaderIterator.java:98)

And i check the package, there exist no such Class or Interface named cachingheader, when google it, only 2 dated and unavailable results are displayed.

Anybody any ideas?

Thanks
Updated on 2010-02-15T22:20:35Z at 2010-02-15T22:20:35Z by karumuri
  • karumuri
    karumuri
    1 Post

    Re: Creating MQHeaderIterator Problem

    ‏2010-02-15T22:20:35Z  
    I am also seeing the same issue. Any remedy for this issue.
  • DSerbin
    DSerbin
    1 Post

    Re: Creating MQHeaderIterator Problem

    ‏2016-12-16T14:14:54Z  

    Required interface is in the com.ibm.mq.pcf.jar package and not in com.ibm.mq.headers.jar. Add it to classpath.