Your config is not correct, it should be something like:
DurableNdsmsEmailTopic <!-- matches id from client -->
DurableNdsmsEmailTopic <!-- matches subscription name -->
I don't see how messages could be retained with your config?
Thank you Adrian for your answer!
Duno about the retaining bit, maybe the purge/clean is only done when a connection is made and started?
I determin the amount of messages in the topic by the DurableMessageCount attribute in the MBean view, is that the correct way?
Anyway I tried you configuration change so that the jbossmq-state.xml is now:
<snip is this important?>
And it behaves exactly the same, the messages are retained (as seen by DurableMessageCount) untill I makes and starts a connection with the EmailerBean and then the messages are gone without me recieving any of them...
btw I run on Jboss-3.2.1
Can you enable TRACE logging for org.jboss.mq
and check the server log.
I suspect you will find a message from the state manager
that says it is re-registering the subscription because
it does not match the configured subscription.
Do you get the same problem if you don't add the config
to jbossmq-state.xml and create the subscription from
the client when it first subscribes?
Duh!!! Why didnt I think of checking the trace output...
The trace output stated that the messages was dropped because of timeout. The timeout value of the message was Long.MAX_VALUE so I am not sure why the messages was timed out, but it worked when I set timeout value to 14 days...
Thank you for the help!