Hi Art,
I don't have hard numbers to hand, but I would not expect there to be a significant performance difference between the two MSGDLVSQ options in most cases.
The only real difference between the two is at the time the message is put.
For PRIORITY, the message is stored on one of the 20 sub-queues based on the message priority and persistence.
For FIFO, the message priority is ignored and the messages are treated as having the queue's default priority. This means they are all placed on the default priority's two sub-queues based only on the persistence.
At the time the messages are got, the logic is entirely the same. MQ looks for the first suitable message starting with the highest priority sub-queue pair and working downwards (with some optimisations to minimise unnecessary scanning). It makes very little difference whether there are messages on all 20 sub-queues or only 1.
For completeness, the reason for the "in most cases" above is that it is possible to construct scenarios where one setting would perform better than the other.
e.g.
- Put 1000 messages with a property "city=London" and a priority of 8.
- Put 1000 messages with a property "city=Paris" and a priority of 9.
- Run getting applications which use a selector to get just the London messages.
On a FIFO queue would have the London messages at the front of the queue as they were put first, but on a PRIORITY queue the would be logically behind the Paris messages, as they have a lower priority.
The getting applications would perform worse with the PRIORITY setting because more work would be required to reach a matching message.
------------------------------
Doug Burns
------------------------------