I have a queue onto which ObjectMessages are placed from a stand-alone application. The messages are then read off the queue by a listener within a J2EE application (not a message bean - just a servlet that starts up a message listener thread). When the Message Listener tries to read a message from the queue I get the following exception:
javax.jms.MessageFormatException: MQJMS1061: Unable to deserialize object
at com.ibm.jms.JMSMessage.newMessageFormatException(JMSMessage.java:247)
at com.ibm.jms.JMSObjectMessage.getObject(JMSObjectMessage.java:230)
at za.co.sanlamhealth.orion.web.correspondence.StatusQueueListener.onMe)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:583)
at com.ibm.mq.jms.contact admin.run(contact admin.java:189)
Yes - my object is serializable and contains a serial version UID. Here is the code for the object.
The class is included in the classpath on the server (it resides in a jar file)
public final class RequestStatus implements Serializable {
private int requestId;
private Date dateProcessed;
private Vector /* of String */ errors = new Vector();
private final static long serialVersionUID = 6739271624628766788L;
}
I am using the same classes on the server and the stand alone application.
Does anyone have any suggestions as to why I am getting this message and what I can do to resolve it.
Joined: 27 Aug 2001 Posts: 3023 Location: Dallas, TX, USA
I thought that there was a known bug when trying to deserialize objects with MQSeries and WebSphere. You'll need to get an efix from IBM support to get around it. I don't have an APAR number.
Does anyone have an APAR / efix number for this problem (MQSeries 5.2 and WAS 4 on solaris). I have scanned the archives but to no avail.
I found a reference on google to a document which deals with this problem:
I had this same problem. MQ dev came up with an efix for me. You can get it from MQ support. It is called "MQ_WAS_EFIX.JAR". It goes in the webapp classpath before any of the other MQ java libs.
The other way to fix it is to put the serialized object in the application classpath (which breaks auto reload of changed classes).
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum