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 » Access <psc> folder from JMS

Post new topic  Reply to topic
 Access <psc> folder from JMS « View previous topic :: View next topic » 
Author Message
sieijish
PostPosted: Mon Apr 24, 2006 7:24 am    Post subject: Access <psc> folder from JMS Reply with quote

Acolyte

Joined: 29 Nov 2004
Posts: 67
Location: London

Hello,

Is there a way to access <psc> folder contents from the JMS API?

I have a SCADA client that publishes a message and the id of the client is contained in psc.publishClientID filed.

Message Broker publishes the message received from the SCADA node and when the JMS Subscriber receives the message, it has to figure out the publishClientID

Regards,
Sieijish Dominic
Back to top
View user's profile Send private message
wschutz
PostPosted: Mon Apr 24, 2006 12:47 pm    Post subject: Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

According to this:
http://publib.boulder.ibm.com/infocenter/wmqv6/v6r0/index.jsp?topic=/com.ibm.mq.csqzaw.doc/csqzaw1481.htm
The answer is NO.
_________________
-wayne
Back to top
View user's profile Send private message Send e-mail AIM Address
sieijish
PostPosted: Tue Apr 25, 2006 4:18 am    Post subject: Reply with quote

Acolyte

Joined: 29 Nov 2004
Posts: 67
Location: London

Since IBM JMS library is parsing the RFH2 header, it definetly has this information, but what i don't know is whether is exposing this via some IBM specific API. I can cast the class to the IBM specific class and call the API

It seems that mapping information to JMS properties is the only way to get the information via JMS API and as per the mapping documentation, there is no standard mapping for this property.
Back to top
View user's profile Send private message
briancop
PostPosted: Tue Apr 25, 2006 11:22 pm    Post subject: Reply with quote

Apprentice

Joined: 04 Apr 2005
Posts: 28
Location: Hursley, UK

The JMS code does parse the RFH2, but in doing so it extracts the info it understands and presents it via the JMS API as header fields and properties, and ignores anything it doesn't understand. So in the current implementation of JMS, you cannot access the contents of folders like <psc>. If you really need access to this, then JMS is not the right API for you; perhaps MQ Classes for Java, although that may cause other issues for you, like having to rewrite your subscriber app with an API that is great for point-point but doesn't make pub/sub anything like as easy as JMS?

The only other way I can think of to do this is some kind of message transformation in the broker to extract the info you need and put it into a property in the <usr> folder so that JMS can get at it. But I'm not a broker expert so couldn't advise you exactly how to do this transformation.
Back to top
View user's profile Send private message
sieijish
PostPosted: Wed Apr 26, 2006 12:24 am    Post subject: Reply with quote

Acolyte

Joined: 29 Nov 2004
Posts: 67
Location: London

Thanks briancop for your comments.

I wanted to confirm that there is no way to access <psc> folder from JMS before going down the <usr> folder route.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Apr 26, 2006 2:42 pm    Post subject: Reply with quote

Grand High Poobah

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

sieijish wrote:
Thanks briancop for your comments.

I wanted to confirm that there is no way to access <psc> folder from JMS before going down the <usr> folder route.


Well yes and no. You have to realize that some of the information in the psc folder is accessed in a complete different way:
Code:
TopicSubscriber mysubscriber = Session.createTopicSubscriber(Topic);
mymessage = mysubscriber.receive(long);


You can now invoke some methods on the subscriber to get information like subscriber.getTopic etc...

Enjoy
_________________
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 » Access <psc> folder from JMS
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.