Hi , I have a problem with my durable subscription in jboss3.2.1
I have created a publisher and publish a message first.
Afterwards, I subscribe the service using Durable subscriber.
This is not successful. The subscriber simply wait until timeout.
However, if I subscribe first and publish later, it is successful.
I want to have a durable subscription, not this one.
My publisher is written as below:
session= conn.createTopicSession(false, Session.DUPS_OK_ACKNOWLEDGE);
publisher=session.createPublisher(topic);
publisher.publish(message, DeliveryMode.PERSISTENT , Message.DEFAULT_PRIORITY, timeout);
My durable subscriber is written as below:
session= conn.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
conn.start();
subscriber = session.createDurableSubscriber(topic, "http");
message=(TextMessage)subscriber.receive(timeout);
They are not sharing the same session and connection object.
I can see that if I publish first and subscribe later,
there are the following writing inside jbossmq-state.xml
2
http
HttpTopic
Any idea on why I am unsucessful ? I have spent a week on this problem.
Thanks a lot.