Aias00 opened a new issue, #6668:
URL: https://github.com/apache/shenyu/issues/6668

   - severity: High (leak) / Medium (bottleneck)
   - files: 
`shenyu-common/src/main/java/org/apache/shenyu/common/timer/HierarchicalWheelTimer.java:83-86`
 (`ShenyuThreadFactory.create(executorName, false)` → non-daemon), `:84-85` 
(`taskExecutor = new ThreadPoolExecutor(1,1,0L,MS,new 
LinkedBlockingQueue<>())`), `:146-148` (`shutdown` only stops `taskExecutor`, 
never `workerThread`), `:164-170` (`Worker.run` `while(true)` swallows 
`InterruptedException`)
   - description: `shutdown()` never stops/interrupts the non-daemon 
`workerThread`, so its `while(true)` loop keeps running and ignores interrupts 
→ thread leak + JVM hangs on redeploy. All expired timer tasks run on a 
single-thread executor with an *unbounded* `LinkedBlockingQueue` → burst of 
simultaneous expirations or any slow task creates head-of-line blocking and 
unbounded queue growth. Used by `FailbackRegistryRepository` (client) and 
`FallbackShenyuClientRegisterService` (admin).
   - impact: Leaked non-daemon thread on redeploy; retry backpressure 
bottleneck.
   - suggested_fix: Make `workerThread` a daemon (or interrupt+join in 
`shutdown`); bound `taskExecutor`'s queue with a real rejection handler.
   - confidence: High
   
   ---
   _Identified during the 2026-08-02 deep re-scan; full list in 
[`docs/scan2-2026-08-02/00-consolidated-critical-high.md`](docs/scan2-2026-08-02/00-consolidated-critical-high.md)._


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to