MQ Connector in request and reply scenario

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
caola
Participant
Posts: 10
Joined: Tue Jul 24, 2007 3:42 am

MQ Connector in request and reply scenario

Post by caola »

Hi all,

I'm using MQ Connector to send msg to the request queue and meanwhile waiting for reply msg from the response queue.

The job design is like this:

sequential file --->MQ Connector ------> sequential file

I could send and get reply msg successfully if there's no other message on the response queue. But if there is an old msg on the response queue before I send msg to the request queue, I will get that old msg on response queue instead of the corresponding one of the request msg I send.

I found below info in the help doc. I think I should get the corresponding reply msg of the request one, but actually I did't. I got any msg appears on the reply queue no matter what the correlation id is...

Does anyone know why? Pls help...

In its role as consumer, the connector performs the following high-level tasks:
1. Creates a request message.
2. Sends the request message to the target queue. The message identifier and the correlation identifier of the request message are noted.
In its role as producer, the connector performs the following high-level tasks: 1. Opens the queue in the Reply to queue property.
2. Issues a call to receive the reply messages when the message identifier of the request message matches the correlation identifier of the reply message.
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Interesting pattern..... I doubt seriously if it was designed to be used in that fashion, especially within an EE Job.... In fact, I'm entirely surprised it didn't generate an error. Such "passive" (classic source/target) type Stages are not usually designed to support "flow thru" like an active stage. They are a "source" or a "target" and not both. The only time I've seen the request/response paradigm utlized is when they are in two separate jobs.....one Job that is writing into the queue (using the Connector as a target)...and another that is concurrently operating in a "wait" condition on the same queue (using the Connector as a Source). Try to separate jobs and see what happens.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
caola
Participant
Posts: 10
Joined: Tue Jul 24, 2007 3:42 am

Post by caola »

Thanks Ernie.

The MQ connector could act in request/reply mode, to get the corresponding response msg. I found out it's a bug of DS 8.1. After the Fix Pack 1 is installed, this problem is solved.
:)
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Excellent! I'll have to give it a try in 8.5, assuming the patch moved forward successfully.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
Post Reply