BTW the default in ActiveMQ from 5.2 onwards is now to use the failover transport - so unless you disable it or change the failover protocol, it will silently reconnect and recover for you without Spring having to do anything
http://activemq.apache.org/failover-transport-reference.html 2008/10/9 xokao <[EMAIL PROTECTED]>: > > when using consumer.receive() to receive messages from a selected broker, > if i shutdown the selected broker . the consumer.receive() didn't throw > any Exception . Nevertheless ExceptionListener or TransferListener can > catch the disconnected exception , but i thought that the client consumer > still not know the server is shutdown,and continue receive message from the > broker. i shoud write more code to stop the client by the Exception catch > by the Exceptionlistener or TransferListener. > > > this issue was found when i user DefaultMessageListenerContainer in > spring-jms api to receive message from a broker, as i use openjms it cound > work well,even if i shutdown the broker and then startup it. by while i > change the jms provider with AMQ5.1. it cant recover from after broker is > restarted. after traced into the codes, i found this problem . > > is this a bug or the desginer intented to design as it ? > -- > View this message in context: > http://www.nabble.com/A-bug-or-A-intent-design--while-useing-using-consumer.receive%28%29-tp19895165p19895165.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com. > > -- James ------- http://macstrac.blogspot.com/ Open Source Integration http://open.iona.com