Author |
Message
|
pottas |
Posted: Thu Jul 10, 2008 12:35 am Post subject: Need sample Soap to Cobol |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
Guys,
I have searched the developerworks website, this site and looked through the Message Broker samples.
I need a sample flow that uses a Soap Input Node, transforms the Soap message into a Cobol Copybook, putting the message on MQ, and then getting the correlated response from MQ, responding back to the Requestor.
I have configured a similar flow, but I am having trouble configuring specifically the MQGet node to get the response from MQ. This is what I have:
SoapInput-->Compute-->MQOutput-->MQGet-->Compute-->SoapReply
The thing is - we have done a flow that exposes a Web Service in Broker and then doing a SoapRequest to Host, but we need to look at other alternatives, i.e. Copybooks with MQ as a transport protocol to Host.
Any assistance or sample would be greatly appreciated. |
|
Back to top |
|
 |
AkankshA |
Posted: Thu Jul 10, 2008 1:21 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
No i dont have the sample... but just want to mention a point since you having trouble in getting response using MQGet..
is your MQOutput and MQGet using same queue??
if yes then have you taken the transaion factor into account... _________________ Cheers |
|
Back to top |
|
 |
pottas |
Posted: Thu Jul 10, 2008 1:47 am Post subject: |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
Thanks for the prompt reply.
Quote: |
is your MQOutput and MQGet using same queue?? |
Yes
Quote: |
if yes then have you taken the transaion factor into account... |
I have the following properties on my MQGet Node:
Advanced:
Transaction Mode: Yes
Generate Mode: LocalEnvironment and Message
Copy Message: Copy Entire Message
Copy Local Environment: Copy Entire LocalEnvironment
Request:
Get by correlation ID: Checked
Result:
Output data Location: OutputLocalEnvironment
What I am trying to achieve is to get the correlated reply from Host to format the Soap Reply back to the requestor. |
|
Back to top |
|
 |
pottas |
Posted: Thu Jul 10, 2008 1:51 am Post subject: |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
Apologies, I lied...
I have a remote queue I put to and I read from a local queue...
So it is like this:
SoapInput-->Compute1-->MQOutput(remote definition)-->MQGet(local definition)-->Compute2-->SoapReply
all of the above nodes connected in a single flow.
Also, in my compute1, I set a correlation ID and try to Get the message from the Local queue by this Corellation Id. |
|
Back to top |
|
 |
AkankshA |
Posted: Thu Jul 10, 2008 2:01 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
What about MQOutput node??
What value does it hold for transaction mode..
are you getting no message found error ?? _________________ Cheers |
|
Back to top |
|
 |
pottas |
Posted: Thu Jul 10, 2008 2:13 am Post subject: |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
Quote: |
What about MQOutput node?? |
I have an MQOutput node - connected to the input terminal of the MQGet.
Quote: |
What value does it hold for transaction mode.. |
Transaction Mode is set to 'Yes' on the 'Advanced' tab
Quote: |
are you getting no message found error ?? |
No, I get the exact same message that I put to the output queue. |
|
Back to top |
|
 |
AkankshA |
Posted: Thu Jul 10, 2008 2:20 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
Set Transaction Mode to 'NO' since you want MQOutput to commit the message the moment you place it in queue.... _________________ Cheers |
|
Back to top |
|
 |
pottas |
Posted: Thu Jul 10, 2008 2:46 am Post subject: |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
Nope. Same thing.
(hey... thanks for your patience - I really appreciate it!)
I have to following configuration settings on my MQGet Node:
Basic: <My Local Queue Definition>
Input Message Parsing: <My message definition of the expected Cobol Response from Host>
Advanced:
Transaction Mode: Yes
Generate Mode: LocalEnvironment and Message
Copy Message: Copy Entire Message
Copy Local Environment: Copy Entire LocalEnvironment
Request:
Get by correlation ID: Checked
Result:
Output data Location: OutputLocalEnvironment
Include message contents in output message assembly: Checked
I guess what I would like to achieve is to set a correlation ID on the message I post to Host and Get the response from Host on a different queue by Correlation ID. |
|
Back to top |
|
 |
AkankshA |
Posted: Thu Jul 10, 2008 2:59 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
pottas wrote: |
Request:
Get by correlation ID: Checked
I guess what I would like to achieve is to set a correlation ID on the message I post to Host and Get the response from Host on a different queue by Correlation ID. |
You must be populating this correlation id in local env too?? for MQGet to know... rt ?
Just asking this since i dont see a compute node after MQOutput to populate this and hence may be you missed this.. _________________ Cheers |
|
Back to top |
|
 |
pottas |
Posted: Thu Jul 10, 2008 3:14 am Post subject: |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
Ok, it feels like I'm getting a bit closer now. What field exactly would I be setting in the Environment tree? And how do I tell my MQGet node to use this specific value?
What I'm attempting now is to set the Correlation ID in my ESQL Node preceding the MQOutput Node:
SET OutputRoot.MQMD.CorrelId = '123'; |
|
Back to top |
|
 |
AkankshA |
Posted: Thu Jul 10, 2008 4:38 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
I would advise you to pls read about MQGet node in infocenter... You yourself ll be able to answer all your queries.. _________________ Cheers |
|
Back to top |
|
 |
pottas |
Posted: Thu Jul 10, 2008 5:58 am Post subject: |
|
|
 Disciple
Joined: 27 Oct 2005 Posts: 185 Location: South Africa
|
AkankshA,
Thanks a lot for your assistance - I worked through the samples and the docs and I got it working. I think my biggest mistake was that I set the MQGet property 'Output data location' to 'OutputRoot.MQMD' rather than to simply 'OutputRoot'. Now I realise there's no way that I would have been able to put the resulting data into an MQMD.
Again, thanks for your time and assistance!
pottas |
|
Back to top |
|
 |
AkankshA |
Posted: Thu Jul 10, 2008 6:02 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
pottas wrote: |
AkankshA,
Thanks a lot for your assistance - I worked through the samples and the docs and I got it working. I think my biggest mistake was that I set the MQGet property 'Output data location' to 'OutputRoot.MQMD' rather than to simply 'OutputRoot'. Now I realise there's no way that I would have been able to put the resulting data into an MQMD.
|
Bingo....!!! _________________ Cheers |
|
Back to top |
|
 |
|