Author |
Message
|
jay_2005 |
Posted: Fri Apr 08, 2005 1:52 am Post subject: jms mqmd mapping help |
|
|
Newbie
Joined: 08 Apr 2005 Posts: 2
|
hi,
i am using jms to send messages to mq. I need to set the ApplIdentityData property in MQMD. Any ideas?
thanks |
|
Back to top |
|
 |
Michael Dag |
Posted: Fri Apr 08, 2005 3:20 am Post subject: |
|
|
 Jedi Knight
Joined: 13 Jun 2002 Posts: 2607 Location: The Netherlands (Amsterdam)
|
|
Back to top |
|
 |
tricky_knight |
Posted: Fri Apr 08, 2005 8:12 am Post subject: |
|
|
Apprentice
Joined: 12 Mar 2005 Posts: 34
|
but what if you had a simple string you wanted to place in the header?
The message is going from JMS to native MQ and the target client is set to 'MQ' so the rfh2 is stripped off. what field would you use to pass the string you needed(MQMD filed)? |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Apr 08, 2005 8:56 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
tricky_knight wrote: |
but what if you had a simple string you wanted to place in the header?
The message is going from JMS to native MQ and the target client is set to 'MQ' so the rfh2 is stripped off. what field would you use to pass the string you needed(MQMD filed)? |
I would put the data in the message body, either in a fixed length field or with a delimiter.
Or I would create a custom MQ header.
It is very problematic to put user data in the MQMD. Not all MQMD fields get data conversion on them done, and you are not guaranteed that the field you decide to use won't be needed by something else. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
jay_2005 |
Posted: Mon Apr 11, 2005 5:36 am Post subject: |
|
|
Newbie
Joined: 08 Apr 2005 Posts: 2
|
Hi,
any ideas on how to create a custom MQ header?
thanks |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Apr 11, 2005 6:47 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
There is descriptions somewhere in the Application Programming Guide, I believe, for creating custom MQ headers.
But it's not necessarily going to be any easier than putting the information at the front of the message data.
You're still going to have to add support for it to all of your applications that want to use it, and you still won't be able to use JMS selectors to get messages from queues based on values in the custom header.
But, in my opinion, anything that selects particular messages from a queue, unless in a request/reply scenario, is trying to use a queue as a database... and that's an anti-pattern in MQ design. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
|