aboutsummaryrefslogtreecommitdiff
path: root/spark-common/src/main/java/me/lucko/spark/common/sampler
diff options
context:
space:
mode:
authorJames58899 <james58899@users.noreply.github.com>2023-03-13 19:19:25 +0800
committerGitHub <noreply@github.com>2023-03-13 11:19:25 +0000
commit20f4b4d9a3977b0d7b95e47f632fd299a397a988 (patch)
tree6806e960b06c7d3b7bdd384eda01855cae48d384 /spark-common/src/main/java/me/lucko/spark/common/sampler
parent0f30d2983ec6ef487fd1966c1c22fa4a73e081f9 (diff)
downloadspark-20f4b4d9a3977b0d7b95e47f632fd299a397a988.tar.gz
spark-20f4b4d9a3977b0d7b95e47f632fd299a397a988.tar.bz2
spark-20f4b4d9a3977b0d7b95e47f632fd299a397a988.zip
Close worker thread pool on profiler stop (#305, #298, #281)
Diffstat (limited to 'spark-common/src/main/java/me/lucko/spark/common/sampler')
-rw-r--r--spark-common/src/main/java/me/lucko/spark/common/sampler/java/JavaSampler.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/spark-common/src/main/java/me/lucko/spark/common/sampler/java/JavaSampler.java b/spark-common/src/main/java/me/lucko/spark/common/sampler/java/JavaSampler.java
index e9d7e0d..2e40406 100644
--- a/spark-common/src/main/java/me/lucko/spark/common/sampler/java/JavaSampler.java
+++ b/spark-common/src/main/java/me/lucko/spark/common/sampler/java/JavaSampler.java
@@ -110,6 +110,8 @@ public class JavaSampler extends AbstractSampler implements Runnable {
// collect statistics for the final window
this.windowStatisticsCollector.measureNow(this.lastWindow.get());
}
+
+ this.workerPool.shutdown();
}
@Override