Skip to content

Commit

Permalink
Don't bother waiting for thread to terminate in TrafficHandler
Browse files Browse the repository at this point in the history
  • Loading branch information
bertrik committed Aug 17, 2024
1 parent 7df9c9f commit e01a11b
Showing 1 changed file with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,7 @@ private void schedule(Runnable action, Duration interval) {

@Override
public void stop() {
try {
executor.shutdownNow();
if (!executor.awaitTermination(5, TimeUnit.SECONDS)) {
LOG.warn("Executor did not terminate");
}
} catch (InterruptedException e) {
LOG.warn("Error stopping executor", e);
}
executor.shutdownNow();
}

private void downloadTrafficSpeed() {
Expand Down

0 comments on commit e01a11b

Please sign in to comment.