ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » MQ Priority not set

Post new topic  Reply to topic
 MQ Priority not set « View previous topic :: View next topic » 
Author Message
matuwe
PostPosted: Mon May 09, 2011 3:30 am    Post subject: MQ Priority not set Reply with quote

Master

Joined: 05 Dec 2007
Posts: 296

I am trying to set the SET OutputRoot.MQMD.Priority = 9; -- High priority
on a compute node. SOmehow when I get out of the compute node the message priority is set back to 0. Is there anything that I am doing wrong???

My compute node properties is set to Message.
Thanks
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon May 09, 2011 4:39 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

There is no reason to change the priority.

If there were a reason to do it, you would not want to use the extreme. You would adjust it +/- 1 not +/- MAX.

For MQ messages, MQ Priority is relative to all the other messages. It's greatest affect occurs when more than one message is sitting on a queue and you do an MQGET. In this instance, all other things being equal, the message with the most important priority gets read first. If all messages have the same priority, then they are read in an undetermined order.

Therefore, forget using Priority, since it provides no benefit to you in your scenario.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
Vitor
PostPosted: Mon May 09, 2011 4:47 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

lancelotlinc wrote:
There is no reason to change the priority.


The OP seems to think there is.

lancelotlinc wrote:
If there were a reason to do it, you would not want to use the extreme. You would adjust it +/- 1 not +/- MAX.


Unless you wanted to be certain the message would jump to the top of the queue.

lancelotlinc wrote:
For MQ messages, MQ Priority is relative to all the other messages. It's greatest affect occurs when more than one message is sitting on a queue and you do an MQGET. In this instance, all other things being equal, the message with the most important priority gets read first. If all messages have the same priority, then they are read in an undetermined order.


And how do you know that, in the OP's environment, the target queue is not being serviced by a slow moving application that doesn't keep up with messages arriving?

lancelotlinc wrote:
Therefore, forget using Priority, since it provides no benefit to you in your scenario.


So your answer to the question "why can't I set priority?" is "stop using priority"?

@matuwe, when you say "get out of the compute node" do you mean you see the priority misset in the debugger, in the target queue or in the user trace? If not the user trace, trying looking there (with a Trace node to show the message tree).
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Mon May 09, 2011 5:26 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

@ Vitor.

My response was a manipulation to see if there really were a business requirement and if there really were a queue stacking up. By issuing a definitive declaration that there was none, I would expect to have push back if there were.

A former client used to set all MQ Priority to MAX. When some channels started backing up latency-important traffic, we located the cause in that a gazillion unimportant messages were clogging the works. But because for years the client coded the MQ Priority on all applications to MAX, there was nothing to be done but source code changes to code that hadn't changed in decades. Ugh!

This lesson learned for me was, don't change the priority unless there is a valid reason to do so, and if you change it, change it the least amount needed to address the true business requirement.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
mqjeff
PostPosted: Mon May 09, 2011 5:39 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

The balance of setting priority is that the minute one application team sets it, everyone else decides that their messages are actually more important than that...
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon May 09, 2011 5:57 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

lancelotlinc wrote:
This lesson learned for me was, don't change the priority unless there is a valid reason to do so, and if you change it, change it the least amount needed to address the true business requirement.


And I don't want to open a debate on the advantages or disadvantages of setting priority, or the advaantages or disadvantages of enforcing priority with WMB (to deal with application teams with bloated self-importance). It's a variation of the application sets priority / WMQ admin sets priority debate.

My point is that your answer didn't address the question at all. It's arguably valid to point out weaknesses in what the poster is trying to do, culminating in the "you're crazy to try this" post I myself have used in the past.

We don't know all the circumstances and people post here for technical help (except the people who post here for free training and/or avoiding reading the documentation).
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
matuwe
PostPosted: Tue May 10, 2011 1:11 am    Post subject: Reply with quote

Master

Joined: 05 Dec 2007
Posts: 296

Oww yes there is a big requirement for it. My broker receives messages from file's queue's and web services. all messages will be processed using one queue. Since webservices are online I need to make sure if a web service message arrives last , it still get processed first. The same will apply for anything that we define as real time/online request where we need to send back a response before the source system timeout.

How can I do this in ESQL..

Thanks
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Tue May 10, 2011 1:38 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

matuwe wrote:
Oww yes there is a big requirement for it. My broker receives messages from file's queue's and web services. all messages will be processed using one queue. Since webservices are online I need to make sure if a web service message arrives last , it still get processed first. The same will apply for anything that we define as real time/online request where we need to send back a response before the source system timeout.

How can I do this in ESQL..

Thanks

Relatively easy. Have your different applications post to a different alias queue. Each alias queue can then show a different priority. That the base queue is the same for all is for you to know. Make sure the delivery on the base queue is set to priority and not fifo. It should all sort itself out.
Of course you will give the web services a priority above 7 and the batch processes a priority below 3. This would then allow you to still prioritize in between processes of the same type if need be.

Remember however that the queue priority only works for the default as queue option. If the application sets its own priority you will need to enforce priority settings....

Using alias queues you could equally separate the traffic by e.g. groups, or even by qmgrs (cluster), having certain brokers process only online traffic...


Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
matuwe
PostPosted: Tue May 10, 2011 1:47 am    Post subject: Reply with quote

Master

Joined: 05 Dec 2007
Posts: 296

Sorry I don't think I understand, I think I didn't explain it properly.

So I receive an HTTP request, which doesn't have MQMD info, Then I wrap the request using a compute node and send it to my queue. I wanted to set the MQMD on this compute node, just before I do a put.. So I am not really receiving any message Priority from the caller application.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Tue May 10, 2011 1:51 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

matuwe wrote:
Sorry I don't think I understand, I think I didn't explain it properly.

So I receive an HTTP request, which doesn't have MQMD info, Then I wrap the request using a compute node and send it to my queue. I wanted to set the MQMD on this compute node, just before I do a put.. So I am not really receiving any message Priority from the caller application.


Then you may have to define different endpoints according to priority and in your compute node setting the priority according to the endpoint/url.

This would result in multiple implementations of the HTTP flow but maybe only a single implementation of the MQ flow.

All in all I believe this (priority usage) to be a bad Idea. I would rather go here for a separation by e.g. or even by broker qmgr (cluster). You risk with the priority model to force time out your batch flows as batch messages of low priority might be stuck forever behind messages of high priority...

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
mqjeff
PostPosted: Tue May 10, 2011 3:16 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

It should be entirely possible to set the message priority in ESQL using the method you have stated.

Where, exactly, are you seeing that the value you have set is changed?

Is it immediately after the compute node- in the logical message tree? If so, then you likely haven't set the right thing. In particular, the MQMD and the Properties tree have some interrelationships. You may need to set an equivalent field in Properties or etc.

Is it after the message has been put to the queue? If so, you have not set the correct options on the MQOutput node.
Back to top
View user's profile Send private message
matuwe
PostPosted: Tue May 10, 2011 3:54 am    Post subject: Reply with quote

Master

Joined: 05 Dec 2007
Posts: 296

Oww I see.. works perfectly.. I used the SET OutputRoot.Properties.Priority = 8; . wich worked super fine... Very much appreciated,
Back to top
View user's profile Send private message
joebuckeye
PostPosted: Tue May 10, 2011 4:35 am    Post subject: Reply with quote

Partisan

Joined: 24 Aug 2007
Posts: 365
Location: Columbus, OH

Check out http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/topic/com.ibm.etools.mft.doc/ac18520_.htm for how the broker determines when to use Properties or MQMD.

Search for "Properties versus MQMD folder behavior for various transports" at that link.
Back to top
View user's profile Send private message
joebuckeye
PostPosted: Tue May 10, 2011 4:39 am    Post subject: Reply with quote

Partisan

Joined: 24 Aug 2007
Posts: 365
Location: Columbus, OH

joebuckeye wrote:
Check out http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/topic/com.ibm.etools.mft.doc/ac18520_.htm for how the broker determines when to use Properties or MQMD.

Search for "Properties versus MQMD folder behavior for various transports" at that link.


Not sure why my previous message showed up as blank. This only shows up when I removed the url tag from the message. Weird.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Tue May 10, 2011 9:59 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

joebuckeye wrote:

Not sure why my previous message showed up as blank. This only shows up when I removed the url tag from the message. Weird.


A space or CR before the [ / u r l ] tag will make the message show blank.
To make it appear I had to delete the stuff between the end of the url and the tag.
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » MQ Priority not set
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.