activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jonm <>
Subject STOMP broker - order of ACKs?
Date Mon, 02 Apr 2007 20:35:48 GMT

I am new to JMS and ActiveMQ -- I have been investigating using the STOMP
broker and things have worked well so far, but I have a question about ACKs
to messages received by a consumer:

It seems that the order of ACKs is not important (if they are done in a
'batch'), for example, I can receive, say 10 messages, process them and then
ACK all of them. I can even scramble the order of ACKs after the messages
have been processed and it's OK.

However, say I write a forked script that processes messages as needed (some
children take longer depending on the action required by the message) and
the children do their own ACKing... Seems like this is not allowed and that
this sequence of events cannot happen on the connection:

- Message 1 rcvd
- ACK msg 1
- Message 2 rcvd
- Message 3 rcvd
- ACK msg 3
- ACK msg 2

I seem to get the following error (a STOMP ERROR frame) in this scenario:

[message] => Unexpected ACK received for message-id
org.apache.activemq.transport.stomp.ProtocolException: Unexpected ACK
received for message-id [ID:jstation-36270-1175286660410-3:148:-1:1:41]

Although this error is thrown, the message is no longer in the queue
(jconsole indicates no messages are waiting to be picked up/sent to the
consumer)...... so though the exception is thrown, everything seems OK....
is this expected? can I ignore this exception and still rely on this
message/ack sequence?

I'm using activeMQ version 4.1.0

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message