You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Ashley Holman (JIRA)" <ji...@apache.org> on 2011/08/16 08:10:27 UTC

[jira] [Commented] (AMQ-2243) Stomp does not retransmit message if client ACKs inside disconnected transaction

    [ https://issues.apache.org/jira/browse/AMQ-2243?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13085556#comment-13085556 ] 

Ashley Holman commented on AMQ-2243:
------------------------------------

Confirming this is no longer an issue 5.5.  Thank you.

> Stomp does not retransmit message if client ACKs inside disconnected transaction
> --------------------------------------------------------------------------------
>
>                 Key: AMQ-2243
>                 URL: https://issues.apache.org/jira/browse/AMQ-2243
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Transport
>    Affects Versions: 5.2.0
>            Reporter: Ashley Holman
>             Fix For: 5.4.1
>
>         Attachments: AMQ-2243-telnetExample.txt, AshStompTest.java
>
>
> Demonstration of problem:
> MyQueue contains MSG1, MSG2.
> Stomp:
> - CONNECT
> - SUBSCRIBE MyQueue (ack = client)
> - BEGIN tx1
> - <reads a message coming from MyQueue> message-id: MSG1
> - ACK message-id: MSG1 
> - *disconnect TCP session*
> Upon reconnecting and subscribing, MSG2 is received.  MSG1 still appears in the queue under the admin web interface but does not get retransmitted (is it still being locked by the now-dead transaction?)
> If the above example finished with an ABORT tx1 before disconnecting, the problem does not occur.
> Further to this, if I restart activemq, MSG1 will now get retransmitted correctly (ie. it is no longer locked by the transaction).
> I suspect that the stomp implementation does not roll back all open transactions when the client unexpectedly disconnects.
> I have attached a telnet session demonstrating the exact problem.
> I've also attached a unit test for transport/stomp/ which contains two tests:
> * testDisconnectRetransmit() - tests that an unacknowledged message is re-transmitted if the client disconnects before ACKing it - SUCCEEDS
> * testTransactionDisconnectRetransmit() - same as above except the message gets ACK'd inside an incomplete transaction before disconnecting - FAILS

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira