Description
new ThreadPoolExecutor(threadCount, MAX_ALLOW_THREADS, 60000L, TimeUnit.MICROSECONDS, …) — 60000L with TimeUnit.MICROSECONDS = 60 ms, not the intended 60 seconds. Burst-spawned non-core threads die after only 60 ms of idle.
Location
shenyu-plugin/shenyu-plugin-logging/shenyu-plugin-logging-tencent-cls/src/main/java/org/apache/shenyu/plugin/tencent/cls/client/TencentClsLogCollectClient.java:163
shenyu-plugin/shenyu-plugin-logging/shenyu-plugin-logging-aliyun-sls/src/main/java/org/apache/shenyu/plugin/aliyun/sls/client/AliyunSlsLogCollectClient.java:184
Impact
Callback-executor threads cycle rapidly on any pause in traffic; wasted thread creation/teardown.
Suggested fix
Use TimeUnit.MILLISECONDS (or SECONDS with 60L).
Related existing
None — distinct from #6794 (Logging pools AbortPolicy + unit bug) which covers the send pools in different clients.
Description
new ThreadPoolExecutor(threadCount, MAX_ALLOW_THREADS, 60000L, TimeUnit.MICROSECONDS, …)—60000LwithTimeUnit.MICROSECONDS= 60 ms, not the intended 60 seconds. Burst-spawned non-core threads die after only 60 ms of idle.Location
shenyu-plugin/shenyu-plugin-logging/shenyu-plugin-logging-tencent-cls/src/main/java/org/apache/shenyu/plugin/tencent/cls/client/TencentClsLogCollectClient.java:163shenyu-plugin/shenyu-plugin-logging/shenyu-plugin-logging-aliyun-sls/src/main/java/org/apache/shenyu/plugin/aliyun/sls/client/AliyunSlsLogCollectClient.java:184Impact
Callback-executor threads cycle rapidly on any pause in traffic; wasted thread creation/teardown.
Suggested fix
Use
TimeUnit.MILLISECONDS(orSECONDSwith60L).Related existing
None — distinct from #6794 (Logging pools AbortPolicy + unit bug) which covers the send pools in different clients.