[jboss-dev-forums] [Design of Messaging on JBoss (Messaging/JBoss)] - Re: JBM 2.0 Strict ordering via ordering groups
gaohoward
do-not-reply at jboss.com
Thu Dec 4 12:01:30 EST 2008
My understanding of message group in JBM 2.0 is that all messages that belong to one message group are guaranteed to be delivered to one consumer. This by definition has nothing to do with strict ordering (or even ordering). They are different concepts. Message groups doesn't necessarily need to observe ordering, and ordering doesn't necessarily enforce single consumer.
Although we can combine the two into one code module, we still can't mingle the two concepts, we still should consider the functionalities for each feature. As for ordering vs message group
1. consumers of strict ordered messages cannot receive second message without first being acknowledged. Consumers of message group can.
2. If we can guarantee strict ordering, there is no need to nail the ordered messages to one consumer. Consider if there are two consumers on one queue that deliver ordered messages. If one consumer gets a failure situation and is not able to consume anymore, the current message will not be acked (or will be rolled back), the other consumer may take over the job (as backup) and continue working (it may call session.recover() first). Will message group allow that happen?
3. If user only wants message group, he shouldn't pay the performance cost brought by strict ordering.
4. In failover and cluster cases, message group and strict ordering are handled differently. Consumer identity is critical for a message group to survive a failure, but sequence is vital to ordering.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4194418#4194418
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4194418
More information about the jboss-dev-forums
mailing list