OK, so first off, be cautious of the meaning of the broker statistics.
Negative consumer counts is definitely a concern and worthy of a bug report
(hopefully with a unit test that replicates the problem - or at least simple
instructions to reproduce it). But some of the other statistics can be
misleading - especially enqueue and dequeue counts on Topics.
That temporary advisory is an attempt to optimize the case of a client
producing messages to a temporary destination after that destination has
been removed. Every connection consumes from that advisory by default
unless the "jms.watchTopicAdvisories" flag is set on the connection URI;
like this:
tcp://localhost:61616?jms.watchTopicAdvisories=false
However, that subscription should never be durable.
Back to the answer of how missing messages are detected. Increasing
"Pending Queue" counts shows messages being stored - not lost. How is the
loss detected?
On the topic of disk space use: keep in mind that a single message can hold
an entire KahaDB data file (typically 32mb), leading to large amounts of
unused KahaDB space. Durable subscribers are a risk for causing a problem
of this type because they are designed to allow consumers to go offline -
which creates a "slow consumer" scenario (really a no-consumer scenario).
And when they are offline, their messages sit unconsumed in the data files
while other messages continue to flow through the system.
Hope this helps.
--
View this message in context:
http://activemq.2283324.n4.nabble.com/Messages-are-kept-in-Pending-queue-for-durable-topic-subscribers-tp4690015p4690679.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.