I'm using the default cofiguration for jboss 4.0.3 and I have two standalone 
clients: one sends a single persistent message to a queue and that one works 
properly. After that I start the second standalone client which looks pretty 
much like this:

Session s = con.createSession(false, Session.AUTO_ACKNOWLEDGE);
MessageConsumer consumer = s.createConsumer(destination);
consumer.setMessageListener(new MessageListener() {
public void onMessage(Message message) {
System.out.println(message);
throw new RuntimeException("please retry me");
}
});

The first time I start the consumer application it receives the message 
properly but the second time and so on the message is no longer received and 
the web console shows the queue size to be zero.

The behavior I see is not consistent with this excerpt from the jms 1.1 javadoc:

public static final int AUTO_ACKNOWLEDGE

With this acknowledgment mode, the session automatically acknowledges a 
client's receipt of a message either when the session has successfully returned 
from a call to receive or when the message listener the session has called to 
process the message successfully returns. 

Is it a (known) bug ?


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3905101#3905101

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3905101


-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to