[jboss-dev-forums] [Design of Messaging on JBoss (Messaging/JBoss)] - Re: Incorporating Remoting http transport into Messaging
ron_sigal
do-not-reply at jboss.com
Wed Sep 27 19:30:04 EDT 2006
"tim_fox" wrote : ... when you close a consumer, closing() first gets called on the ServerConsumerEndpoint, this causes stop() to be called, which waits for any deliveries of messages to the client which might be in progress to complete first.
|
| Once that is done, the actual client consumer is closed and removed from the callback manager.
Looking a the code again, I noticed something I missed the first time around. When MessageCallbackHandler gets a message, it does one of two things:
1. If a thread is blocked in receive(), it wakes up the thread and returns.
2. If a MessageListener is registered, it queues up a Runnable to call onMessage().
Now, 1 is irrelevant if the MessageConsumer has called close(), so I thought the point was to make sure that a MessageConsumer didn't close while a listener was in onMessage(). But it looks like that could still happen. Is that ok? Just curious.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974707#3974707
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974707
More information about the jboss-dev-forums
mailing list