From d58502dbb14ce8ecdf093f4a39db9507bf682b0d Mon Sep 17 00:00:00 2001 From: Robert Bach Date: Sun, 3 Jan 2021 21:49:12 +0100 Subject: [PATCH] add getPoolNames method to ThreadPoolManager Signed-off-by: Robert Bach --- .../main/java/org/openhab/core/common/ThreadPoolManager.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bundles/org.openhab.core/src/main/java/org/openhab/core/common/ThreadPoolManager.java b/bundles/org.openhab.core/src/main/java/org/openhab/core/common/ThreadPoolManager.java index 790236582a5..66e9a0d0bb0 100644 --- a/bundles/org.openhab.core/src/main/java/org/openhab/core/common/ThreadPoolManager.java +++ b/bundles/org.openhab.core/src/main/java/org/openhab/core/common/ThreadPoolManager.java @@ -14,6 +14,7 @@ import java.util.Map; import java.util.Map.Entry; +import java.util.Set; import java.util.WeakHashMap; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ExecutorService; @@ -167,4 +168,8 @@ protected static int getConfig(String poolName) { Integer cfg = configs.get(poolName); return (cfg != null) ? cfg : DEFAULT_THREAD_POOL_SIZE; } + + public static Set getPoolNames() { + return pools.keySet(); + } }