On Thu, Mar 18, 2010 at 12:15 PM, jumbro <jum...@fortress.com> wrote:
>
> I just tested persistence using a QUEUE and... it works!
>
> So my question is: do topics offer this same functionality? If not, then
> why?
>
> If topics do support persistence, then I'm still missing something..

Topics support durability which is slightly different. But with
topics, messages will only be persisted if a durable subscription
exists on the topic. Below is a description of durability vs.
persistence that I wrote for chapter 2
of the forthcoming ActiveMQ In Action book:

Two points within JMS that are often confused are message durability
and message persistence. Though they are similar, there are some
semantic differences but each has its specific purpose. Message
durability can only be achieved with the pub/sub domain. When clients
connect to a topic, they can do so using a durable or a non-durable
subscription. Consider the differences between the two:

Durable Subscription - A durable subscription is infinite. It is
registered with the topic to tell the JMS provider to preserve the
subscription state in the event that the subscriber disconnects. If a
durable subscriber disconnects, the JMS provider will hold all
messages until that subscriber connects again.

Non-Durable Subscription - A non-durable subscription is finite. It's
subscription state is not preserved by the JMS provider in the event
that the subscriber disconnects. If a subscriber disconnects, it
misses all messages during the disconnection period and the JMS
provider will not hold them.

Message persistence is independent of the message domain. Message
persistence is a quality of service property used to indicate the JMS
application's ability to handle missing messages in the event of a JMS
provider failure.

Bruce
-- 
perl -e 'print 
unpack("u30","D0G)u8...@4vyy9&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

ActiveMQ in Action: http://bit.ly/2je6cQ
Blog: http://bruceblog.org/
Twitter: http://twitter.com/brucesnyder

Reply via email to