Skip to content
This repository has been archived by the owner on Sep 26, 2023. It is now read-only.

Commit

Permalink
fix: do not shut down executor when WatchDog is shut down (#871)
Browse files Browse the repository at this point in the history
Fixes #870
  • Loading branch information
chrisribble committed Feb 18, 2020
1 parent ee90c2c commit 327cd8d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
1 change: 0 additions & 1 deletion gax/src/main/java/com/google/api/gax/rpc/Watchdog.java
Expand Up @@ -124,7 +124,6 @@ public void run() {
@Override
public void shutdown() {
future.cancel(false);
executor.shutdown();
}

@Override
Expand Down
1 change: 0 additions & 1 deletion gax/src/test/java/com/google/api/gax/rpc/WatchdogTest.java
Expand Up @@ -188,7 +188,6 @@ public void testWatchdogBeingClosed() {
.scheduleAtFixedRate(
underTest, checkInterval.toMillis(), checkInterval.toMillis(), TimeUnit.MILLISECONDS);
Mockito.verify(future, Mockito.times(2)).cancel(false);
Mockito.verify(mockExecutor, Mockito.times(2)).shutdown();

underTest.shutdownNow();
Mockito.verify(future).cancel(true);
Expand Down

0 comments on commit 327cd8d

Please sign in to comment.