Service Test Practitioners Forum
cancel
Showing results for 
Search instead for 
Did you mean: 

How to set ReplyToQ while doing a PUT Message.

reachksuraj
Acclaimed Contributor

How to set ReplyToQ while doing a PUT Message.

Hi,


The MQ Application that we intend to test expects the Request message to contain ReplyToQ information in its MQMD header. The Application reads the ReplyToQ value to send back the Response. How is the ReplyToQ value to be set in HP Service Test ?

 

We are using the 'Put and Get Message' option to run the test. As the ReplyToQ value is not set, the GET message returns an error stating 'No message available'.

 

Please advice.

 

Suraj.

1 REPLY
Highlighted
Ninfea
Occasional Contributor

Re: How to set ReplyToQ while doing a PUT Message.

Go to Events -> BeforeMQPutMEssage.

Now you have to write your custom code. Add the following namespace:
using IBM.WMQ;

Add the following code inside public void MQPutMessageToQueue6_OnBeforeMQPutMessage (...)
{
args.MQMessage.ReplyToQueueName="YourQueueName";
}
//Add this to "OnDomLoad" event