[ 
https://issues.apache.org/jira/browse/LUCENE-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13001883#comment-13001883
 ] 

Hoss Man commented on LUCENE-2822:
----------------------------------


Having read through all of the comments in LUCENE-997 I fail to see why any 
Threads are needed in TimeLimitedCollector at all -- repeatedly folks mention 
that the use of a Timer thread is purely because System.currentTimeMillis isn't 
reliable enough and/or not efficient enough, but if we could use Java 1.5, 
System.nanoTime would be exactly what we need.

It's 2011. 
We can use Java 1.5 now in core Lucene. 
so why don't we just rip out the TimerThread and use System.nanoTime() ?


> TimeLimitingCollector starts thread in static {} with no way to stop them
> -------------------------------------------------------------------------
>
>                 Key: LUCENE-2822
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2822
>             Project: Lucene - Java
>          Issue Type: Bug
>            Reporter: Robert Muir
>
> See the comment in LuceneTestCase.
> If you even do Class.forName("TimeLimitingCollector") it starts up a thread 
> in a static method, and there isn't a way to kill it.
> This is broken.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to