I'd need to see the tests to answer better, but make sure that the 
TestingServer is shutdown at the end of the test. Look at Curator's tests for 
good examples.

-JZ

On May 30, 2013, at 1:43 PM, John Vines <[email protected]> wrote:

> I'm slowly adapting my codebase to use Curator, which includes using 
> TestingServer's in a few places for junit tests. However, I've noticed an 
> issue with my tests sometimes getting stuck in curator methods, specifically 
> in the retry. In the output I see repeated Connection refused messages with 
> occasional ConnectionLossException issues with a full stack trace. 
> Netstatting shows the junit process no longer has a port bound, nor am I 
> seeing any signs of life of zookeeper in a jstack. Unfortunately, I see 
> nothing else in the output to indicate this thread dying.
> 
> Is there any knowledge on this issue, either how to prevent it from happening 
> or at least get a better diagnosis of what is going on? It's quite sporadic, 
> which makes using this for a unit test quite painful.
> 
> Thanks
> John

Reply via email to