mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
8a879c6fed
This commit uses a local variable for the creation of a new JMS Connection so that a rare failure in prepareConnection(...) does not leave the connection field in a partially initialized state. If such a JMSException occurs, the intermediary connection is closed. This commit further defends against close() failures at that point, by logging the close exception at DEBUG level. As a result, the original JMSException is always re-thrown. See gh-29116 Closes gh-30051