*Summary of the problem
*
After reconnecting and resubscribing to a durable subscription, ActiveMQ
does not send messages - that were sent to the topic while the client with a
durable subscription was offline.

I have tested this with version 5.1.0 and 5.2.0 with same results.

*Details
*
Here are the steps to reproduce the problem:


   1. STOMP client connects with "client-id:connection1" header
   2. Create a durable subscription with "destination: /topic/destination1"
   and "activemq.subscriptionName:testdurablesubscription1" headers
   3. Send messages M1 and M2 to /topic/destination1:
   4. Client receives these messages  M1 and M2
   5. Now disconnect using DISCONNECT command
   6. Using another client publish messages M3, M4 and M5 to
   /topic/destination1
   7. Reconnect the STOMP client with "client-id:connection1" header
   8. Create the durable subscription with "destination:
   /topic/destination1" and
   "activemq.subscriptionName:testdurablesubscription1" headers
   9. *NOW M3, M4 and M5 are not delivered to the client.*


Using JConsole, I do see the durable subscription with the name
"testdurablesubscription1" and it has following attributes:


   - DequeueCounter = 2
   - EnqueueCounter = 5
   - PendingQueueSize = 0


As you can see that there are 3 messages that were not dequeued but the
PendingQueueSize is 0.

I have implemented a same test case with Java client using JMS API against
ActiveMQ and it works just fine. On reconnect and resubscribe, I do get
M3,M4 and M5 delivered to the client.

I also looked at
StompTest.java<https://svn.apache.org/repos/asf/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/transport/stomp/StompTest.java>and
I don't see any tests for same.

Is this a know issue? What are the right set of STOMP headers to send to get
this to work.

Your assistance is really appreciated.

Best Regards,
Sidda

Director of Management Services
>|< Kaazing Corporation >|<
888, Villa St. Suite #410, Mountain View, CA 94040, USA

Reply via email to