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 API Support » How to GET a JMS Message

Post new topic  Reply to topic
 How to GET a JMS Message « View previous topic :: View next topic » 
Author Message
vennela
PostPosted: Mon Apr 14, 2003 7:31 am    Post subject: How to GET a JMS Message Reply with quote

Jedi Knight

Joined: 11 Aug 2002
Posts: 4055
Location: Hyderabad, India

I have a JMS app (I don't have control over that app) that is putting Messages. I have to read those messages back using non-java apps. How do I read those messages back. If I do a normal GET I am getting some weird characters.

Any pointers would be appreciated.

Thanks
-------
Venny
Back to top
View user's profile Send private message Send e-mail Visit poster's website
meekings
PostPosted: Mon Apr 14, 2003 7:43 am    Post subject: Reply with quote

Voyager

Joined: 28 Jun 2001
Posts: 86
Location: UK, South West

A JMS app will normally put an RFH2 header at the front of the payload (though it can be configured not to). Are these the "weird characters" you're seeing? If so, you just need to jump over it to get to the payload.
_________________
Brian Meekings
Information Design, Inc.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
bower5932
PostPosted: Mon Apr 14, 2003 10:47 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

You can also indicate that you don't want JMS to put the RFH2 header on your message in the first place. There is a TARGCLIENT property on both the Q(ueue) an T(opic). You can set it to either JMS (add the header) or MQ (leave the header off).
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
vennela
PostPosted: Mon Apr 14, 2003 11:17 am    Post subject: Reply with quote

Jedi Knight

Joined: 11 Aug 2002
Posts: 4055
Location: Hyderabad, India

Yes, I am seeing those weird characters in front of the actual message. That may not be too much of a problem. We are using Oracle MQ Adapter (Oracle product) that is putting the message. I want to know what are the various ways of setting the TARCLIENT parameter if I am not using JNDI. Because, I have very little control over the PUT application.

The parameters that I can specify to the Oracle Adapter are
1. QMGR name
2. QUEUE
3. HOSTNAME
4. CHANNEL
5. PORT
6. CCSID

I think they are not using JNDI objects but instead defining objects inline in the program.
I can GET the message using another JMS app. But I want to GET the message using a C app. Is this possible.

Thanks
-------
Venny
Back to top
View user's profile Send private message Send e-mail Visit poster's website
meekings
PostPosted: Mon Apr 14, 2003 11:24 am    Post subject: Reply with quote

Voyager

Joined: 28 Jun 2001
Posts: 86
Location: UK, South West

Queue tQueue = session.createQueue("whatever");
((MQQueue)tQueue).setTargetClient(JMSC.MQJMS_CLIENT_NONJMS_MQ);

in the sender app would do it, but you don't have control over that. So simply code into your C app to skip over the RFH2 header - see manual for location of the "length" field in the header.
_________________
Brian Meekings
Information Design, Inc.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vennela
PostPosted: Mon Apr 14, 2003 12:36 pm    Post subject: Reply with quote

Jedi Knight

Joined: 11 Aug 2002
Posts: 4055
Location: Hyderabad, India

Got that resolved.

I had to do this. In the file where Oracle MQ Adapter is reading parameters from, I changed the queue name like this

///RECEIVER.DATA.QUEUE?CCSID=37&targetClient=1

Previously it looked:
///RECEIVER.DATA.QUEUE

So, nonjndi objects parameters should be set something like above.
Thanks for the pointers.

-------
Venny
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ API Support » How to GET a 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.