users@glassfish.java.net

Re: Durable subscription for topic connection factory

From: <glassfish_at_javadesktop.org>
Date: Mon, 18 May 2009 11:42:51 PDT

We have finally found a solution to this!

It's so trivial, we should all be flipping burgers. haha

The trick to getting durable subscribers working on Open MQ is setting up two connection factories, one for the durable subscribers and the other for the nondurable and publishers. The AHA moment came when I broke the pieces into two apps and discovered that it was the message producer that was failing, not the subscriber. For the durable subscriber connection factory, you have to add the ClientId property on the resource. Nothing else is required in the app beyond flipping the subscriptionDurable switch.

So basically, we needed to set up separate topic connection factories, one for the publisher and one for the subscriber which needs to be durable.

We have tested setting this up. Made the needed changes to the test app and tested it out. Everything worked.

Also, we are using spring in the application for all of this.
[Message sent by forum member 'sbeard' (sbeard)]

http://forums.java.net/jive/thread.jspa?messageID=346657