On Mon, 2009-01-19 at 13:58 -0800, Patrick Ruckstuhl wrote:
> Hi Timothy
> 
> I'm now able to deal with connection interruptions on the sending side but
> seem to get some problems on the receiving side (there are some partner that
> simple just receive messages)
> 
> What I currently do is (in pseudocode)
> 
> Consumer c = session.createConsumer(SomeDestination)
> 
> while(true) {
>     Message m = c.receiveTimeout(1Second)
>     if(m != Void){
>        doSomething()
>     }
> }
> 
> 
> Now my problem seems to be that, "c.receive" doesn't throw an exception if
> the connection is lost and therefore I'm not able to detect the lost
> connection. 
> 

Are you registering am Exception Listener on the Connection ?  
Also depending on the platform the TCP stack my not fail immediately but
wait for some timeout, so you may need to play around with the TCP settings.


-- 
Tim Bish
http://fusesource.com
http://timbish.blogspot.com/



Reply via email to