Skip to content

Commit f0788b5

Browse files
committed
YARN-11656 RMStateStore event queue blocked
- some style fix
1 parent 4811257 commit f0788b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/event/multidispatcher/MultiDispatcherExecutor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public void execute(Event event, Runnable runnable) {
6767
public void stop() throws InterruptedException {
6868
long timeOut = clock.getTime() + config.getGracefulStopSeconds() * 1_000L;
6969
// if not all queue is empty
70-
if (!Arrays.stream(threads).allMatch(t -> t.queue.isEmpty())
70+
if (Arrays.stream(threads).anyMatch(t -> 0 < t.queueSize())
7171
// and not timeout yet
7272
&& clock.getTime() < timeOut) {
7373
LOG.debug("Not all event queue is empty, waiting to drain ...");

0 commit comments

Comments
 (0)