Author |
Message
|
Anjali |
Posted: Wed Jul 20, 2016 7:09 am Post subject: checking whether the input is coming from MQ? |
|
|
Novice
Joined: 20 Jul 2016 Posts: 11
|
My scenario is to know whether the input is coming from MQ or FTP?
I tried in like getting to know details from MQMD headers so that I can know it is coming from MQ. BUt i'm facing an issue when I'm accessing queue name from MQMD headers in Compute node like "Failed to locate constant". So, can anyone please tell me the solution  |
|
Back to top |
|
 |
Vitor |
Posted: Wed Jul 20, 2016 7:11 am Post subject: Re: checking whether the input is coming from MQ? |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Anjali wrote: |
My scenario is to know whether the input is coming from MQ or FTP? |
Did it come from an MQInput node or a FileInput node?
That's going to be a clue....  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Jul 20, 2016 7:17 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
The solution is to compare your code against a trace of the input message.
Several ways that could be done _________________ chmod -R ugo-wx / |
|
Back to top |
|
 |
Anjali |
Posted: Wed Jul 20, 2016 10:28 am Post subject: |
|
|
Novice
Joined: 20 Jul 2016 Posts: 11
|
that is what i want to know whether it is coming from FTP or MQ Input node.
give me some suggestions how can i know whether from which i am getting and the input will i'll be getting will be in xmlnsc having the topic for publish and subscription by taking the input from that xmlnsc dynamically |
|
Back to top |
|
 |
Vitor |
Posted: Wed Jul 20, 2016 10:37 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Anjali wrote: |
that is what i want to know whether it is coming from FTP or MQ Input node. |
It's your flow - if the previous node is a FileInput it's FTP, if the previous node is an MQInput then it's MQ.
Anjali wrote: |
give me some suggestions how can i know whether from which i am getting |
What difference does it make? Why do you need to know this? If the input is XML that's then being published (possibly after some transformation) how cares where it came from?
Anjali wrote: |
the input will i'll be getting will be in xmlnsc having the topic for publish and subscription by taking the input from that xmlnsc dynamically |
Congratulations. Was there a question there?
If it was "how do I take the topic from the XMLNC dynamically and use it to publish", don't bother asking. The answer you need is in the product documentation and any "answers" here may range from unhelpful to unprofessional  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
adubya |
Posted: Wed Jul 20, 2016 12:32 pm Post subject: |
|
|
Partisan
Joined: 25 Aug 2011 Posts: 377 Location: GU12, UK
|
Just check for the presence of a MQMD header in the input message. If there's one present then there is a good chance that your message came from a queue. If missing then it probably came from a non-MQ source, like a file/FTP input. _________________ Independent Middleware Consultant
andy@knownentity.com |
|
Back to top |
|
 |
manoj5007 |
Posted: Wed Jul 20, 2016 11:20 pm Post subject: |
|
|
 Acolyte
Joined: 15 May 2013 Posts: 64
|
Another method would be to check for generation of LocalEnvironment.File field.
When the message is out of a FileInputNode, the details of the file picked are stored in LocalEnvironment under File folder. |
|
Back to top |
|
 |
JuliaFrohwein |
Posted: Wed Jul 20, 2016 11:31 pm Post subject: |
|
|
Newbie
Joined: 20 Jul 2016 Posts: 1
|
Like has been mentioned before you can try comparing your code against a trace of the input message. |
|
Back to top |
|
 |
|