jojochuang opened a new pull request, #11667: URL: https://github.com/apache/ozone/pull/11667
## What changes were proposed in this pull request? Client background executors and timers can keep the JVM alive after the application returns from `main` if the associated resources remain open. This patch makes the streaming-write response executor, short-circuit connection timer, domain socket factory timer, and default low-level EC reconstruction executor use daemon threads. The default EC reconstruction executor also retires its worker after 60 seconds of inactivity while retaining single-worker task execution. Caller-supplied executors and existing explicit cleanup paths are unchanged. Applications still need to close streams to complete writes. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/HDDS-17254 ## How was this patch tested? * Added four isolated-JVM regression cases. Against the original code, each worker started successfully and the JVM remained alive past the 30-second exit timeout. With the fixes, all four JVMs exited normally. * Added a regression case for idle default EC workers: it fails against the original implementation and passes with the fix. It also checks that the executor accepts new work after the previous worker retires. * The short-circuit cases mock native sockets or enable timer initialization without opening a native socket. The EC case activates the default executor directly. These tests isolate thread lifecycle rather than exercising a live cluster. * All 113 targeted tests passed across `TestClientThreadShutdown`, `TestBlockDataStreamOutput`, `TestBlockInputStreamFactoryImpl`, `TestECBlockInputStream`, `TestECBlockReconstructedInputStream`, and `TestECBlockReconstructedStripeInputStream`. A final rerun of all five new cases passed in approximately 3 seconds. * Repository checkstyle and the hdds-client RAT check passed. Repository-wide RAT found unrelated existing local files under dev-support, including Bats support files and prior reproduction build artifacts. Validation used JDK 21 with `-DskipShade -DskipRecon -DskipDocs`. Generated-by: Codex (GPT-6) -- 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]
