mirror of
https://github.com/spring-projects/spring-framework.git
synced 2026-10-07 23:49:08 +00:00
Prior to this commit, JpaTransactionManager and HibernateTransactionManager stated that they do not support "running within DataSourceTransactionManager" when encountering a pre-bound JDBC Connection that is not synchronized with a transaction. However, DataSourceTransactionManager marks its ConnectionHolder as synchronized with the transaction and therefore does not trigger this check. Instead, the exception is typically caused by another JpaTransactionManager or HibernateTransactionManager for a different persistence unit exposing a JDBC Connection for the same DataSource, or by a JDBC Connection that has been left bound to the current thread. This commit revises the exception message accordingly so that it no longer points to DataSourceTransactionManager. See gh-14130 Closes gh-37356 Signed-off-by: rene.schakmann <rene.schakmann@reetgroup.com>