Re: InterruptedException

2009-01-09 Thread Kevin Burton
o: zookeeper-user@hadoop.apache.org > Subject: Re: InterruptedException > > Kevin Burton wrote: > > On Thu, Jan 8, 2009 at 3:21 PM, Benjamin Reed > wrote: > > > > > >> InterruptedException is rather tricky because the semantics of > >> Thread.

RE: InterruptedException

2009-01-09 Thread Benjamin Reed
...@sun.com] Sent: Friday, January 09, 2009 7:56 AM To: zookeeper-user@hadoop.apache.org Subject: Re: InterruptedException Kevin Burton wrote: > On Thu, Jan 8, 2009 at 3:21 PM, Benjamin Reed wrote: > > >> InterruptedException is rather tricky because the semantics of >> Thre

Re: InterruptedException

2009-01-09 Thread Thomas Vinod Johnson
Kevin Burton wrote: On Thu, Jan 8, 2009 at 3:21 PM, Benjamin Reed wrote: InterruptedException is rather tricky because the semantics of Thread.isInterrupted() is rather vague. specifically, it is unclear why someone would interrupt a thread. usually Thread.interrupt() is used to shut things

Re: InterruptedException

2009-01-08 Thread Kevin Burton
On Thu, Jan 8, 2009 at 3:21 PM, Benjamin Reed wrote: > InterruptedException is rather tricky because the semantics of > Thread.isInterrupted() is rather vague. specifically, it is unclear why > someone would interrupt a thread. usually Thread.interrupt() is used to shut > things down which requir

RE: InterruptedException

2009-01-08 Thread Benjamin Reed
x27;m not clear how you shutdown your poll() method. an easy way to do it would be to use Thread.interrupt(). ben -Original Message- From: Mahadev Konar [mailto:maha...@yahoo-inc.com] Sent: Tuesday, January 06, 2009 7:05 PM To: zookeeper-user@hadoop.apache.org Subjec

Re: InterruptedException

2009-01-06 Thread Mahadev Konar
Hi Kevin, The interrupt exception would be thrown in case any other thread tries to interrupt zookeeper threads during a client call (its not really interrupting the server but interrupting the client threads). Its like any synchronous operation that waits throwing an interrupted exception if inte