Author |
Message
|
techno |
Posted: Wed Jan 22, 2003 2:29 pm Post subject: MQGetMessageOptions - MQJava - JMS |
|
|
Chevalier
Joined: 22 Jan 2003 Posts: 429
|
I have a java messaging program witten as per JMS standard.
If I use MQ Base java, I see a class MQGetMessageOptions, specifying many options while reading from a queue. Can I do the same thing if the coding is done as per JMS standard?
Eg: How do I specify MQGMO_FAIL_IF_QUIESCING in JMS code?
thanks for your help,
Shiva. |
|
Back to top |
|
 |
EddieA |
Posted: Thu Jan 23, 2003 2:05 pm Post subject: |
|
|
 Jedi
Joined: 28 Jun 2001 Posts: 2453 Location: Los Angeles
|
You can't unless you're running 5.3.
Then, its the "setFailIfQuiesce(int)" method on the ConnectionFactory. It can also be set when administering JMS objects with the JMSAdmin tool.
But, I'm guessing, that this is an IBM specific extension to the JMS spec, which would make your code non-portable. _________________ Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0 |
|
Back to top |
|
 |
techno |
Posted: Thu Jan 23, 2003 4:51 pm Post subject: |
|
|
Chevalier
Joined: 22 Jan 2003 Posts: 429
|
Thanks for your information
I am using 5.2.
What is the alternative then? My application is locking MQ server and MQ server is not getting stopped under normal mode.
Any hints are valuable to me.
thanks,
Shiva. |
|
Back to top |
|
 |
EddieA |
Posted: Wed Jan 29, 2003 5:38 pm Post subject: |
|
|
 Jedi
Joined: 28 Jun 2001 Posts: 2453 Location: Los Angeles
|
One way would be to code the RECEIVE with a short wait, and keep looping around. _________________ Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0 |
|
Back to top |
|
 |
techno |
Posted: Thu Jan 30, 2003 11:48 am Post subject: |
|
|
Chevalier
Joined: 22 Jan 2003 Posts: 429
|
Basically whole concept changes here. It will be no more Listener concept. Am I right? |
|
Back to top |
|
 |
EddieA |
Posted: Fri Jan 31, 2003 9:28 am Post subject: |
|
|
 Jedi
Joined: 28 Jun 2001 Posts: 2453 Location: Los Angeles
|
I don't see why.
Original design:
Get message with indefinite wait and quiesce option.
If message, process and go back to Get.
If queue manager ending, done.
Otherwise MQ error.
New design:
Get message waiting for 10 seconds.
If message, process and go back to Get.
If no message, go back to Get.
If MQ error, check for codes that imply queue manager ending. Done.
Otherwise MQ error.
You're still Listening for a message. Just taking a break every few seconds to see if something more important is happening. _________________ Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0 |
|
Back to top |
|
 |
|