keith-turner commented on a change in pull request #402: ACCUMULO-4615: Updated
get status for thread safety and with a per-task timeout
URL: https://github.com/apache/accumulo/pull/402#discussion_r176467774
##########
File path:
server/master/src/main/java/org/apache/accumulo/master/TimeoutTaskExecutor.java
##########
@@ -121,25 +123,43 @@ public void onTimeout(TimeoutCallback<C>
timeoutCallback) {
* @throws IllegalStateException
* If all of the callbacks were not registered before calling this
method.
* @throws InterruptedException
- * If interrupted while awaiting callable results.
+ * If interrupted while awaiting trackingCallable results.
*/
public void complete() throws InterruptedException {
Preconditions.checkState(successCallback != null, "Must set a success
callback before completing " + this);
Preconditions.checkState(exceptionCallback != null, "Must set an exception
callback before completing " + this);
Preconditions.checkState(timeoutCallback != null, "Must set a timeout
callback before completing " + this);
+ while (hasUnfinishedTasks()) {
Review comment:
It seems like this loop can burn CPU, could sleep a fraction of the timeout.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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