luoyuan3471 opened a new pull request, #8887: URL: https://github.com/apache/hadoop/pull/8887
## Problem `FederationRMAdminInterceptor` creates a per-user thread pool but inherits a `shutdown()` method that only delegates to the next interceptor. Its own executor is never shut down, so idle worker threads can remain alive when core thread timeout is disabled. ## Solution - Override `shutdown()` to shut down the executor before calling the parent method. - Guard against a null executor so shutdown is safe before initialization. - Add regression tests for worker termination, repeated shutdown, and shutdown before initialization. - Limit this change to the interceptor's thread-pool shutdown; service-stop, pipeline-wrapper, and finalization behavior are unchanged. ## Validation - Local tests passed with JDK 17 and Maven 3.9.15. - `TestFederationRMAdminInterceptor`: 38 tests, 0 failures, 0 errors, 0 skipped. - The new thread-pool shutdown test fails without the production fix. - Surefire reports and `git diff --check` verified. ## Related Jira [YARN-12049](https://issues.apache.org/jira/browse/YARN-12049) Replaces #8884 with a thread-pool-only fix. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
