Page 1 of 1

MQ Connector - Sending vs JMSType

Posted: Mon May 11, 2020 12:58 pm
by IASAQ
Hi all,

A colleague of mine in the organization would like to read messages I sent to a Q with a JMSType header in the message. The payload I'm putting on the Q is a JSON string.

I know that I can find this information in the data element FormatHeaders if I read a message from a Q that contains a JMSType, where the info I get in FormatHeaders basically looks like this:

{R F H 20 00 00 00 02 00 00 00 f0 00 00 01 11 00 00 04 b8 M Q S T R 20 20 20 00 00 00 00 00 00 04 b8 00 00 00 8 < m c d > < M s d > j m s _ t e x t < / M s d > < T y p e > J M S T Y P E _ T E S T < / T y p e > < / m c d > 20 00 00 00 \ < j m s > < D s t > q u e u e : / / / D H . N _ A R V . M A J _ M A T R I C E . E D D . Q U E U E < / D s t > < T m s > 1 5 8 9 2 2 6 8 2 8 5 7 8 < / T m s > < D l v > 2 < / D l v > < / j m s > 20 20 00 00 00 , < u s r > < H E A D E R _ T E S T > A B C D < / H E A D E R _ T E S T > < / u s r > 20 20}

but I have no idea if it's possible for me to do the same when I send a message to a Q via the MQ Connector component. I've tried almost all the options in the MQ Connector stage, but to no avail.

This following thread kind of hinted at what I want to do, but it was never really properly answered:

viewtopic.php?t=152820&highlight=MQRFH2

Any hint appreciated, even if it's just to let me know it can't be done with MQ Connector.

Regards.

Posted: Mon May 18, 2020 3:48 pm
by eostic
Been awhile' but the MQ Connector and the Stage before it had nice support for Data Elements.....and if set, would force interaction with the actual MQ Header. JMS Type doesnt ring a bell, but search the doc and resources around data elements.....

Ernie

Posted: Tue May 19, 2020 1:25 pm
by IASAQ
Thanks Ernie. Looks like you confirm in your own way that setting the JMSType header is not something that can be done with the current MQ Connector. I basically tried to set every options in the connector to a test value and none of them resulted in a JMSType header in the message I received in the test queue.

Regards.

Posted: Tue May 19, 2020 3:37 pm
by eostic
Well....that depends. That Connector was written with a whole lot of powerful features, assuming that they are all still supported. Have you been thru and experimented with all the formal DataStage Data Elements that it supports, such as MSMQ.REPLYTOQ ? (there are a lot of others with the MSMQ prefix). This is one of the few Connectors that truly recognizes a DataStage Data Element as a way to carry additional metadata and meaning. There is also a lot of documentation about using MQRFH2 headers with this Connector. Unfortunately, this Connector didn't get used a lot, so there many not be a large community that has deep expertise with it. But if you haven't at least explored those data elements or the MQRFH2 options, it would be worth re-visiting.

Ernie