davsclaus opened a new pull request, #24791: URL: https://github.com/apache/camel/pull/24791
## Summary - Fix `JpaPollingConsumer.receive()` leaking an `EntityManager` on every successful call - The root cause was passing `null` instead of the exchange to `getTargetEntityManager()`, which skipped registering `JpaCloseEntityManagerOnCompletion` on the exchange - The fix moves exchange creation before the EM acquisition so the exchange is passed, enabling the automatic cleanup synchronization ## Test plan - [x] All existing `JpaPollingConsumer*` tests pass (4 tests) _Claude Code on behalf of davsclaus_ 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.6 <[email protected]> -- 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]
