LUCENE-4660: add missing notifyAll after merge finishes

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1428949 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael McCandless 2013-01-04 16:11:22 +00:00
parent 1fa73401ca
commit bbbe89ed14
2 changed files with 12 additions and 0 deletions

View File

@ -310,6 +310,10 @@ Bug Fixes
that have no TermToBytesRefAttribute (commonly provided by CharTermAttribute),
e.g., oal.analysis.miscellaneous.EmptyTokenStream.
(Uwe Schindler, Adrien Grand, Robert Muir)
* LUCENE-4660: ConcurrentMergeScheduler was taking too long to
un-pause incoming threads it had paused when too many merges were
queued up. (Mike McCandless)
Changes in Runtime Behavior

View File

@ -479,6 +479,14 @@ public class ConcurrentMergeScheduler extends MergeScheduler {
// Subsequent times through the loop we do any new
// merge that writer says is necessary:
merge = tWriter.getNextMerge();
// Notify here in case any threads were stalled;
// they will notice that the pending merge has
// been pulled and possibly resume:
synchronized(ConcurrentMergeScheduler.this) {
ConcurrentMergeScheduler.this.notifyAll();
}
if (merge != null) {
updateMergeThreads();
if (verbose()) {