gnodet opened a new pull request, #24359: URL: https://github.com/apache/camel/pull/24359
_Claude Code on behalf of Guillaume Nodet_ ## Summary - Close `InputStream` from `HttpExchange.getRequestBody()` using try-with-resources in `AudioTranscriptionRequestHandler`, `EmbeddingRequestHandler`, and `RequestHandler` - Close `HttpClient` instances in all 7 test classes using a `finally` block with `instanceof AutoCloseable` guard -- compatible with `--release 17` compilation while correctly closing the client on Java 21+ runtimes where `HttpClient` implements `AutoCloseable` Fixes all 17 SonarCloud S2095 (Resources should be closed) blocker issues reported for `test-infra/camel-test-infra-openai-mock`, plus 3 additional `InputStream` leaks in the handler classes. ## Test plan - [x] `mvn clean install -f test-infra/camel-test-infra-openai-mock/pom.xml -Dquickly` passes - [x] `mvn formatter:format impsort:sort` reports no changes needed - [ ] CI build passes 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- 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]
