ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Java / JMS » Strange message parsing exception

Post new topic  Reply to topic
 Strange message parsing exception « View previous topic :: View next topic » 
Author Message
Zed
PostPosted: Fri Oct 06, 2006 12:21 am    Post subject: Strange message parsing exception Reply with quote

Newbie

Joined: 06 Oct 2006
Posts: 3

Hi everyone
I've faced with a strange WebSphere MQ behaviour. Situation looks like this:
I have MQ and WebSphere Process Server connected through MQLink. I put a message to remote queue and it's forwarded to the Process Server through MQLink (it transforms message to JMS message). On Process Server side message is parsed and replied with another message.
Everything working fine when I use IBM WebSphere MQ Explorer to put a message from graphical interface.
But when I'm trying to use Java API to put a message to the same remote queue I get an exception on Process Server Side as following:
Code:
jar#export.emulatorExportEIS, null)". Exception data: org.xml.sax.SAXParseException: Content is not allowed in prolog.
   at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
   at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source)
   at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
   at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)

......................

com.ibm.ws.sib.ra.inbound.impl.SibRaDispatcher.dispatch(SibRaDispatcher.java:572)
   at com.ibm.ws.sib.ra.inbound.impl.SibRaSingleProcessListener$SibRaWork.run(SibRaSingleProcessListener.java:463)
   at com.ibm.ejs.j2c.work.WorkProxy.run(WorkProxy.java:463)
   at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
Wrapped by:
com.ibm.websphere.sca.ServiceRuntimeException: org.eclipse.emf.ecore.resource.Resource$IOWrappedException: Content is not allowed in prolog.: caused by: org.eclipse.emf.ecore.resource.Resource$IOWrappedException: Content is not allowed in prolog.
   at com.ibm.ws.sca.databinding.impl.DataBindingImplXML.read(DataBindingImplXML.java:206)
   at com.ibm.ws.sca.databinding.impl.DataBindingImplXML.setFromString(DataBindingImplXML.java:117)


It looks like there is some differences in message headers when I'm using Java API instead of MQ Explorer.

Any help appreciated.
Thanks.
_________________
Hot russian guy
Back to top
View user's profile Send private message MSN Messenger
jefflowrey
PostPosted: Fri Oct 06, 2006 1:55 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Create a queue that is not read by the MQLink.

Use MQ Explorer to put the message there.

Use your code to put the message there.

Use the sample program amqsbcg to browse the queue. Examine the two messages in the output of that program, and figure out what's different.

Change your code to do what should be done.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Zed
PostPosted: Fri Oct 06, 2006 2:54 am    Post subject: Reply with quote

Newbie

Joined: 06 Oct 2006
Posts: 3

Thanks. I've already done it. When we put messages to local queue they are identical. The difference seems to appear in case of putting a message to remote queue. I stopped the Sender channel (to MQLink) and analyzed message in Transmission queue. The differences were in XQH header (right before the message body). In case of Java API usage there were two additional bytes in the end of the header.

I don't know the reason of this.
_________________
Hot russian guy
Back to top
View user's profile Send private message MSN Messenger
fjb_saper
PostPosted: Fri Oct 06, 2006 2:55 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Do you have the latest fix packs? Have you talked to IBM support? There was a case a while back where MQLink truncated the message from MQ...
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Zed
PostPosted: Fri Oct 06, 2006 4:18 am    Post subject: Reply with quote

Newbie

Joined: 06 Oct 2006
Posts: 3

It seems strange because in first case when message came from MQ Explorer MQLink doesn't truncate it
But anyway I'll get all fixes
_________________
Hot russian guy
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Strange message parsing exception
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.