lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dawid Weiss <>
Subject Re: Thread "leaking" in junit tests
Date Fri, 29 Jun 2012 09:20:01 GMT
> I absolutely agree, even though IMO warning is better than silence.

I plan to work on it soon, we've released Carrot2 and Lingo3G and
there's a chunk of free time for me to work on randomized testing.

> Anyway I got what I wanted: a failure in my test ;)

So maybe I'll hint you a bit more -- look at the log messages before
the test fails with a leaked thread. The runner will try to "probe"
the thread's stack at random intervals to give you an idea where it's
been before it was killed. The probing cuts off identical stack
portion so you can pretty much tell what a thread was doing.

   * The number of "probes" of the offending thread's stack trace
before an attempt
   * is made to kill it. Snapshots are taken at random intervals
between 10 and 100
   * milliseconds each and dumped to system logger to facilitate
debugging of the offending thread.
   * <p>Setting this value to 0 means no samples will be taken.
  int stackSamples() default 10;


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message