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 » Extract the payload from JMS Message.

Post new topic  Reply to topic
 Extract the payload from JMS Message. « View previous topic :: View next topic » 
Author Message
imsiva_k
PostPosted: Tue May 28, 2013 11:22 pm    Post subject: Extract the payload from JMS Message. Reply with quote

Apprentice

Joined: 02 Dec 2008
Posts: 25

Dear Team,

Could anyone please guide me how to extract the payload from JMS message.

Scenario : I'm using WESB in my project. I would be poling the MQ queue from WESB using MQJMS export. The message in MQ is delimited. Hence I need the payload alone to parse and make as a dataobject and send it to provider

I'm posting a sample plain text message from my MQ explorer. I'm using JMSDatabinding interface and trying to parse the incoming message.

The message in server.out log is
JMSMessage class: jms_text
JMSType: null
JMSDeliveryMode: 1
JMSExpiration: 0
JMSPriority: 0
JMSMessageID: ID:414d5120514d5f5745534220202020204e79a55120015502
JMSTimestamp: 1369809516140
JMSCorrelationID: null
JMSDestination: null
JMSReplyTo: null
JMSRedelivered: true
JMSXAppID: re MQ\java\jre\bin\javaw.exe
JMSXDeliveryCount: 2
JMSXUserID: imsiva
JMS_IBM_Character_Set: UTF-8
JMS_IBM_Encoding: 546
JMS_IBM_Format: MQSTR
JMS_IBM_MsgType: 8
JMS_IBM_PutApplType: 11
JMS_IBM_PutDate: 20130529
JMS_IBM_PutTime: 06383614
claimRequest ~ SA2001 ~ Approved

Now how to extract the payload alone ?

Please help me........ Thanks.
Back to top
View user's profile Send private message Send e-mail
fjb_saper
PostPosted: Wed May 29, 2013 12:19 pm    Post subject: Reply with quote

Grand High Poobah

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

Like you would extract any other text payload from a JMS TextMessage...
Have you tried casting the Message to a javax.jms.TextMessage and invoking getText() on it?
Paradox: it seems your little test there did it, or is the ~ delimitated text we see there a Fata Morgana? (also known to be easily found in the French Air Force...)
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Extract the payload from JMS Message.
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.