Remove unnecessary ThreadSafeBatchCallback interface.
Its superinterface, BatchCallback, is already annotated @ThreadSafe.
PiperOrigin-RevId: 318828127
diff --git a/src/main/java/com/google/devtools/build/lib/cmdline/TargetPattern.java b/src/main/java/com/google/devtools/build/lib/cmdline/TargetPattern.java
index 178286f..e50cd62 100644
--- a/src/main/java/com/google/devtools/build/lib/cmdline/TargetPattern.java
+++ b/src/main/java/com/google/devtools/build/lib/cmdline/TargetPattern.java
@@ -27,7 +27,6 @@
import com.google.devtools.build.lib.cmdline.LabelValidator.BadLabelException;
import com.google.devtools.build.lib.cmdline.LabelValidator.PackageAndTarget;
import com.google.devtools.build.lib.concurrent.BatchCallback;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.util.StringUtilities;
import com.google.devtools.build.lib.vfs.PathFragment;
import com.google.errorprone.annotations.CheckReturnValue;
@@ -174,7 +173,7 @@
TargetPatternResolver<T> resolver,
ImmutableSet<PathFragment> ignoredSubdirectories,
ImmutableSet<PathFragment> excludedSubdirectories,
- ThreadSafeBatchCallback<T, E> callback,
+ BatchCallback<T, E> callback,
Class<E> exceptionClass) {
try {
eval(resolver, ignoredSubdirectories, excludedSubdirectories, callback, exceptionClass);
@@ -203,7 +202,7 @@
TargetPatternResolver<T> resolver,
ImmutableSet<PathFragment> ignoredSubdirectories,
ImmutableSet<PathFragment> excludedSubdirectories,
- ThreadSafeBatchCallback<T, E> callback,
+ BatchCallback<T, E> callback,
Class<E> exceptionClass,
ListeningExecutorService executor) {
return evalAdaptedForAsync(
@@ -615,7 +614,7 @@
TargetPatternResolver<T> resolver,
ImmutableSet<PathFragment> ignoredSubdirectories,
ImmutableSet<PathFragment> excludedSubdirectories,
- ThreadSafeBatchCallback<T, E> callback,
+ BatchCallback<T, E> callback,
Class<E> exceptionClass,
ListeningExecutorService executor) {
return resolver.findTargetsBeneathDirectoryAsync(
diff --git a/src/main/java/com/google/devtools/build/lib/cmdline/TargetPatternResolver.java b/src/main/java/com/google/devtools/build/lib/cmdline/TargetPatternResolver.java
index a556086..05d20a4 100644
--- a/src/main/java/com/google/devtools/build/lib/cmdline/TargetPatternResolver.java
+++ b/src/main/java/com/google/devtools/build/lib/cmdline/TargetPatternResolver.java
@@ -19,7 +19,6 @@
import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.ListeningExecutorService;
import com.google.devtools.build.lib.concurrent.BatchCallback;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.vfs.PathFragment;
import java.util.Collection;
@@ -112,7 +111,7 @@
boolean rulesOnly,
ImmutableSet<PathFragment> blacklistedSubdirectories,
ImmutableSet<PathFragment> excludedSubdirectories,
- ThreadSafeBatchCallback<T, E> callback,
+ BatchCallback<T, E> callback,
Class<E> exceptionClass,
ListeningExecutorService executor) {
try {
diff --git a/src/main/java/com/google/devtools/build/lib/concurrent/ParallelVisitor.java b/src/main/java/com/google/devtools/build/lib/concurrent/ParallelVisitor.java
index decd9ef..64d2589 100644
--- a/src/main/java/com/google/devtools/build/lib/concurrent/ParallelVisitor.java
+++ b/src/main/java/com/google/devtools/build/lib/concurrent/ParallelVisitor.java
@@ -48,7 +48,7 @@
OutputKeyT,
OutputResultT,
ExceptionT extends Exception,
- CallbackT extends ThreadSafeBatchCallback<OutputResultT, ExceptionT>> {
+ CallbackT extends BatchCallback<OutputResultT, ExceptionT>> {
protected final CallbackT callback;
protected final Class<ExceptionT> exceptionClass;
private final int visitBatchSize;
@@ -143,7 +143,7 @@
OutputKeyT,
OutputResultT,
ExceptionT extends Exception,
- CallbackT extends ThreadSafeBatchCallback<OutputResultT, ExceptionT>> {
+ CallbackT extends BatchCallback<OutputResultT, ExceptionT>> {
ParallelVisitor<InputT, VisitKeyT, OutputKeyT, OutputResultT, ExceptionT, CallbackT> create();
}
diff --git a/src/main/java/com/google/devtools/build/lib/concurrent/ThreadSafeBatchCallback.java b/src/main/java/com/google/devtools/build/lib/concurrent/ThreadSafeBatchCallback.java
deleted file mode 100644
index 542adc9..0000000
--- a/src/main/java/com/google/devtools/build/lib/concurrent/ThreadSafeBatchCallback.java
+++ /dev/null
@@ -1,21 +0,0 @@
-// Copyright 2016 The Bazel Authors. All rights reserved.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-package com.google.devtools.build.lib.concurrent;
-
-import com.google.devtools.build.lib.concurrent.ThreadSafety.ThreadSafe;
-
-/** Marker interface for a {@link BatchCallback} that is {@link ThreadSafe}. */
-@ThreadSafe
-public interface ThreadSafeBatchCallback<T, E extends Exception> extends BatchCallback<T, E> {
-}
\ No newline at end of file
diff --git a/src/main/java/com/google/devtools/build/lib/pkgcache/RecursivePackageProvider.java b/src/main/java/com/google/devtools/build/lib/pkgcache/RecursivePackageProvider.java
index 429a159..316bd23 100644
--- a/src/main/java/com/google/devtools/build/lib/pkgcache/RecursivePackageProvider.java
+++ b/src/main/java/com/google/devtools/build/lib/pkgcache/RecursivePackageProvider.java
@@ -17,8 +17,8 @@
import com.google.devtools.build.lib.cmdline.Label;
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
import com.google.devtools.build.lib.cmdline.RepositoryName;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
import com.google.devtools.build.lib.packages.NoSuchPackageException;
import com.google.devtools.build.lib.packages.NoSuchTargetException;
@@ -50,7 +50,7 @@
* @param excludedSubdirectories a set of {@link PathFragment}s specifying transitive
*/
void streamPackagesUnderDirectory(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
ExtendedEventHandler eventHandler,
RepositoryName repository,
PathFragment directory,
@@ -116,7 +116,7 @@
@Override
public void streamPackagesUnderDirectory(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
ExtendedEventHandler eventHandler,
RepositoryName repository,
PathFragment directory,
diff --git a/src/main/java/com/google/devtools/build/lib/query2/engine/Callback.java b/src/main/java/com/google/devtools/build/lib/query2/engine/Callback.java
index 21054df..cf4524f 100644
--- a/src/main/java/com/google/devtools/build/lib/query2/engine/Callback.java
+++ b/src/main/java/com/google/devtools/build/lib/query2/engine/Callback.java
@@ -14,16 +14,15 @@
package com.google.devtools.build.lib.query2.engine;
import com.google.devtools.build.lib.concurrent.BatchCallback;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.concurrent.ThreadSafety.ThreadSafe;
/**
* Query callback to be called by a {@link QueryExpression} when it has part of the computation
- * result. Assuming the {@code QueryEnvironment} supports it, it would allow the caller
- * to stream the results.
+ * result. Assuming the {@code QueryEnvironment} supports it, it would allow the caller to stream
+ * the results.
*/
@ThreadSafe
-public interface Callback<T> extends ThreadSafeBatchCallback<T, QueryException> {
+public interface Callback<T> extends BatchCallback<T, QueryException> {
/**
* According to the {@link BatchCallback} interface, repeated elements may be passed in here.
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/EnvironmentBackedRecursivePackageProvider.java b/src/main/java/com/google/devtools/build/lib/skyframe/EnvironmentBackedRecursivePackageProvider.java
index 6d204af..aaf7a40 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/EnvironmentBackedRecursivePackageProvider.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/EnvironmentBackedRecursivePackageProvider.java
@@ -21,8 +21,8 @@
import com.google.devtools.build.lib.actions.InconsistentFilesystemException;
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
import com.google.devtools.build.lib.cmdline.RepositoryName;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.events.Event;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
import com.google.devtools.build.lib.packages.BuildFileContainsErrorsException;
@@ -142,7 +142,7 @@
@Override
public void streamPackagesUnderDirectory(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
ExtendedEventHandler eventHandler,
RepositoryName repository,
PathFragment directory,
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/GraphBackedRecursivePackageProvider.java b/src/main/java/com/google/devtools/build/lib/skyframe/GraphBackedRecursivePackageProvider.java
index a405221..05fd3fd 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/GraphBackedRecursivePackageProvider.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/GraphBackedRecursivePackageProvider.java
@@ -26,8 +26,8 @@
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
import com.google.devtools.build.lib.cmdline.RepositoryName;
import com.google.devtools.build.lib.cmdline.TargetPattern;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.concurrent.ThreadSafety.ThreadSafe;
import com.google.devtools.build.lib.events.Event;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
@@ -201,7 +201,7 @@
@Override
public void streamPackagesUnderDirectory(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
ExtendedEventHandler eventHandler,
RepositoryName repository,
PathFragment directory,
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/PackageIdentifierBatchingCallback.java b/src/main/java/com/google/devtools/build/lib/skyframe/PackageIdentifierBatchingCallback.java
index 2bdb14f..f7bd24b 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/PackageIdentifierBatchingCallback.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/PackageIdentifierBatchingCallback.java
@@ -15,8 +15,8 @@
import com.google.common.collect.ImmutableList;
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.concurrent.ThreadSafety.ThreadSafe;
import javax.annotation.concurrent.GuardedBy;
@@ -24,16 +24,16 @@
* A callback for {@link
* com.google.devtools.build.lib.pkgcache.RecursivePackageProvider#streamPackagesUnderDirectory}
* that buffers the PackageIdentifiers it receives into fixed-size batches that it delivers to a
- * supplied {@code ThreadSafeBatchCallback<PackageIdentifier, RuntimeException>}.
+ * supplied {@code BatchCallback<PackageIdentifier, RuntimeException>}.
*
* <p>The final batch delivered to the delegate callback may be smaller than the fixed size; the
* callback must be {@link #close() closed} to deliver this final batch.
*/
@ThreadSafe
public class PackageIdentifierBatchingCallback
- implements ThreadSafeBatchCallback<PackageIdentifier, UnusedException>, AutoCloseable {
+ implements BatchCallback<PackageIdentifier, UnusedException>, AutoCloseable {
- private final ThreadSafeBatchCallback<PackageIdentifier, UnusedException> batchResults;
+ private final BatchCallback<PackageIdentifier, UnusedException> batchResults;
private final int batchSize;
@GuardedBy("this")
@@ -43,7 +43,7 @@
private int bufferedPackageIds;
public PackageIdentifierBatchingCallback(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> batchResults, int batchSize) {
+ BatchCallback<PackageIdentifier, UnusedException> batchResults, int batchSize) {
this.batchResults = batchResults;
this.batchSize = batchSize;
reset();
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePackageProviderBackedTargetPatternResolver.java b/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePackageProviderBackedTargetPatternResolver.java
index d401c57..30766f6 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePackageProviderBackedTargetPatternResolver.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePackageProviderBackedTargetPatternResolver.java
@@ -33,7 +33,6 @@
import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.MultisetSemaphore;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.concurrent.ThreadSafety.ThreadCompatible;
import com.google.devtools.build.lib.events.Event;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
@@ -117,7 +116,7 @@
Target target = recursivePackageProvider.getTarget(eventHandler, label);
return policy.shouldRetain(target, true)
? ResolvedTargets.of(target)
- : ResolvedTargets.<Target>empty();
+ : ResolvedTargets.empty();
} catch (NoSuchThingException e) {
throw new TargetParsingException(e.getMessage(), e);
}
@@ -173,24 +172,6 @@
return target.getTargetKind();
}
- /**
- * A {@link ThreadSafeBatchCallback} that trivially delegates to a {@link BatchCallback} in a
- * synchronized manner.
- */
- private static class SynchronizedBatchCallback<T, E extends Exception>
- implements ThreadSafeBatchCallback<T, E> {
- private final BatchCallback<T, E> delegate;
-
- SynchronizedBatchCallback(BatchCallback<T, E> delegate) {
- this.delegate = delegate;
- }
-
- @Override
- public synchronized void process(Iterable<T> partialResult) throws E, InterruptedException {
- delegate.process(partialResult);
- }
- }
-
@Override
public <E extends Exception> void findTargetsBeneathDirectory(
final RepositoryName repository,
@@ -204,17 +185,17 @@
throws TargetParsingException, E, InterruptedException {
try {
findTargetsBeneathDirectoryAsyncImpl(
- repository,
- originalPattern,
- directory,
- rulesOnly,
- blacklistedSubdirectories,
- excludedSubdirectories,
- new SynchronizedBatchCallback<Target, E>(callback),
- MoreExecutors.newDirectExecutorService()).get();
+ repository,
+ originalPattern,
+ directory,
+ rulesOnly,
+ blacklistedSubdirectories,
+ excludedSubdirectories,
+ callback,
+ MoreExecutors.newDirectExecutorService())
+ .get();
} catch (ExecutionException e) {
- Throwable cause = e.getCause();
- Throwables.propagateIfPossible(cause, TargetParsingException.class, exceptionClass);
+ Throwables.propagateIfPossible(e.getCause(), TargetParsingException.class, exceptionClass);
throw new IllegalStateException(e.getCause());
}
}
@@ -227,7 +208,7 @@
boolean rulesOnly,
ImmutableSet<PathFragment> blacklistedSubdirectories,
ImmutableSet<PathFragment> excludedSubdirectories,
- ThreadSafeBatchCallback<Target, E> callback,
+ BatchCallback<Target, E> callback,
Class<E> exceptionClass,
ListeningExecutorService executor) {
return findTargetsBeneathDirectoryAsyncImpl(
@@ -248,13 +229,13 @@
boolean rulesOnly,
ImmutableSet<PathFragment> blacklistedSubdirectories,
ImmutableSet<PathFragment> excludedSubdirectories,
- ThreadSafeBatchCallback<Target, E> callback,
+ BatchCallback<Target, E> callback,
ListeningExecutorService executor) {
FilteringPolicy actualPolicy =
rulesOnly ? FilteringPolicies.and(FilteringPolicies.RULES_ONLY, policy) : policy;
ArrayList<ListenableFuture<Void>> futures = new ArrayList<>();
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> getPackageTargetsCallback =
+ BatchCallback<PackageIdentifier, UnusedException> getPackageTargetsCallback =
(pkgIdBatch) ->
futures.add(
executor.submit(
@@ -294,13 +275,13 @@
private final Iterable<PackageIdentifier> packageIdentifiers;
private final String originalPattern;
private final FilteringPolicy actualPolicy;
- private final ThreadSafeBatchCallback<Target, E> callback;
+ private final BatchCallback<Target, E> callback;
GetTargetsInPackagesTask(
Iterable<PackageIdentifier> packageIdentifiers,
String originalPattern,
FilteringPolicy actualPolicy,
- ThreadSafeBatchCallback<Target, E> callback) {
+ BatchCallback<Target, E> callback) {
this.packageIdentifiers = packageIdentifiers;
this.originalPattern = originalPattern;
this.actualPolicy = actualPolicy;
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePkgValueRootPackageExtractor.java b/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePkgValueRootPackageExtractor.java
index e541c0b..ac1ea8a 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePkgValueRootPackageExtractor.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/RecursivePkgValueRootPackageExtractor.java
@@ -19,8 +19,8 @@
import com.google.common.collect.Iterables;
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
import com.google.devtools.build.lib.cmdline.RepositoryName;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
import com.google.devtools.build.lib.vfs.PathFragment;
import com.google.devtools.build.lib.vfs.Root;
@@ -33,7 +33,7 @@
@Override
public void streamPackagesFromRoots(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
WalkableGraph graph,
List<Root> roots,
ExtendedEventHandler eventHandler,
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/RootPackageExtractor.java b/src/main/java/com/google/devtools/build/lib/skyframe/RootPackageExtractor.java
index e0bba766..b92e8e1 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/RootPackageExtractor.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/RootPackageExtractor.java
@@ -16,8 +16,8 @@
import com.google.common.collect.ImmutableSet;
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
import com.google.devtools.build.lib.cmdline.RepositoryName;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
import com.google.devtools.build.lib.vfs.PathFragment;
import com.google.devtools.build.lib.vfs.Root;
@@ -45,7 +45,7 @@
* searched exhaustively
*/
void streamPackagesFromRoots(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
WalkableGraph graph,
List<Root> roots,
ExtendedEventHandler eventHandler,
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/TraversalInfoRootPackageExtractor.java b/src/main/java/com/google/devtools/build/lib/skyframe/TraversalInfoRootPackageExtractor.java
index 4d0da0e..ec89243 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/TraversalInfoRootPackageExtractor.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/TraversalInfoRootPackageExtractor.java
@@ -23,9 +23,9 @@
import com.google.common.util.concurrent.ThreadFactoryBuilder;
import com.google.devtools.build.lib.cmdline.PackageIdentifier;
import com.google.devtools.build.lib.cmdline.RepositoryName;
+import com.google.devtools.build.lib.concurrent.BatchCallback;
import com.google.devtools.build.lib.concurrent.ParallelVisitor;
import com.google.devtools.build.lib.concurrent.ParallelVisitor.UnusedException;
-import com.google.devtools.build.lib.concurrent.ThreadSafeBatchCallback;
import com.google.devtools.build.lib.events.Event;
import com.google.devtools.build.lib.events.ExtendedEventHandler;
import com.google.devtools.build.lib.vfs.PathFragment;
@@ -53,7 +53,7 @@
@Override
public void streamPackagesFromRoots(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> results,
+ BatchCallback<PackageIdentifier, UnusedException> results,
WalkableGraph graph,
List<Root> roots,
ExtendedEventHandler eventHandler,
@@ -97,14 +97,14 @@
TraversalInfo,
PackageIdentifier,
UnusedException,
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException>> {
+ BatchCallback<PackageIdentifier, UnusedException>> {
private final ExtendedEventHandler eventHandler;
private final RepositoryName repository;
private final WalkableGraph graph;
PackageCollectingParallelVisitor(
- ThreadSafeBatchCallback<PackageIdentifier, UnusedException> callback,
+ BatchCallback<PackageIdentifier, UnusedException> callback,
int visitBatchSize,
int processResultsBatchSize,
int minPendingTasks,
diff --git a/src/test/java/com/google/devtools/build/lib/concurrent/ParallelVisitorTest.java b/src/test/java/com/google/devtools/build/lib/concurrent/ParallelVisitorTest.java
index 9e7a7f8..da54868 100644
--- a/src/test/java/com/google/devtools/build/lib/concurrent/ParallelVisitorTest.java
+++ b/src/test/java/com/google/devtools/build/lib/concurrent/ParallelVisitorTest.java
@@ -44,7 +44,7 @@
}
@ThreadSafe
- private interface TestCallback<T> extends ThreadSafeBatchCallback<T, SampleException> {
+ private interface TestCallback<T> extends BatchCallback<T, SampleException> {
@Override
void process(Iterable<T> partialResult) throws SampleException, InterruptedException;