File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
server/src/main/java/org/elasticsearch/index/engine Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -65,6 +65,7 @@ private ThreadPoolMergeExecutorService(ThreadPool threadPool) {
6565 void submitMergeTask (MergeTask mergeTask ) {
6666 assert mergeTask .isRunning () == false ;
6767 assert mergeTask .isOnGoingMergeAborted () == false ;
68+ // first enqueue the runnable that runs exactly one merge task (the smallest it can find)
6869 if (enqueueMergeTaskExecution () == false ) {
6970 // if the threadpool cannot run the merge, just abort it
7071 mergeTask .abortOnGoingMerge ();
@@ -73,6 +74,7 @@ void submitMergeTask(MergeTask mergeTask) {
7374 // count enqueued merge tasks that support IO auto throttling, and maybe adjust IO rate for all
7475 maybeUpdateIORateBytesPerSec (submittedIOThrottledMergeTasksCount .incrementAndGet ());
7576 }
77+ // then enqueue the merge task proper
7678 enqueueMergeTask (mergeTask );
7779 }
7880 }
You can’t perform that action at this time.
0 commit comments