diff options
author | Mark Schaller <mschaller@google.com> | 2015-10-30 22:15:34 +0000 |
---|---|---|
committer | Florian Weikert <fwe@google.com> | 2015-11-02 16:55:28 +0000 |
commit | 5350b3154665ebb37e10e6261686eb646ea23220 (patch) | |
tree | 8bce3e4c5e8e708577ad01d3e361f93a2a008548 /src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java | |
parent | e45a363cf7c2abfdf1dd67cfb7ed0a54d1ed52c2 (diff) |
Introduce QuiescingExecutor
This interface (mostly) encapsulates what the ValueVisitor expects
from the AbstractQueueVisitor class it currently inherits from. This
makes it easier for a future CL to change ValueVisitor's strategy of
code reuse from inheritance to composition.
RELNOTES:
--
MOS_MIGRATED_REVID=106728863
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java')
-rw-r--r-- | src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java b/src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java index 35e84d3b15..e5f78c1fd2 100644 --- a/src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java +++ b/src/main/java/com/google/devtools/build/lib/query2/LabelVisitor.java @@ -306,7 +306,7 @@ final class LabelVisitor { @ThreadSafe public boolean finish() throws InterruptedException { - work(true); + awaitQuiescence(/*interruptWorkers=*/ true); return !errorObserver.hasErrors(); } @@ -338,7 +338,7 @@ final class LabelVisitor { !blockNewActions() && count < RECURSION_LIMIT) { newVisitRunnable(from, attr, label, depth, count + 1).run(); } else { - enqueue(newVisitRunnable(from, attr, label, depth, 0)); + execute(newVisitRunnable(from, attr, label, depth, 0)); } } |