leventov commented on a change in pull request #8809: Prohibit
Futures.addCallback(Future, Callback)
URL: https://github.com/apache/incubator-druid/pull/8809#discussion_r342940649
##########
File path:
indexing-service/src/main/java/org/apache/druid/indexing/overlord/RemoteTaskRunner.java
##########
@@ -256,7 +256,9 @@ public void onFailure(Throwable throwable)
waitingForMonitor.notifyAll();
}
}
- }
+ },
+ // The callback is non-blocking and quick, so it's OK to
schedule it using directExecutor()
Review comment:
`synchronized (waitingForMonitor)` **is blocking**. You may argue that this
lock is (almost) free, for some reasons, so then the callback should still be
considered "mostly non-blocking" and OK to schedule on directExecutor(), but in
any case it demands a more elaborate comment
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]