|
|
|
|
@ -93,13 +93,14 @@ import org.springframework.util.CollectionUtils;
@@ -93,13 +93,14 @@ import org.springframework.util.CollectionUtils;
|
|
|
|
|
* |
|
|
|
|
* <p>This transaction manager supports nested transactions via JDBC Savepoints. |
|
|
|
|
* The {@link #setNestedTransactionAllowed "nestedTransactionAllowed"} flag defaults |
|
|
|
|
* to {@code false} though, since nested transactions will just apply to the JDBC |
|
|
|
|
* Connection, not to the JPA EntityManager and its cached entity objects and related |
|
|
|
|
* context. You can manually set the flag to {@code true} if you want to use nested |
|
|
|
|
* transactions for JDBC access code which participates in JPA transactions (provided |
|
|
|
|
* that your JDBC driver supports Savepoints). <i>Note that JPA itself does not support |
|
|
|
|
* nested transactions! Hence, do not expect JPA access code to semantically |
|
|
|
|
* participate in a nested transaction.</i> |
|
|
|
|
* to "true" but should rather be "false", as nested transactions will just apply to |
|
|
|
|
* the JDBC Connection, not to the JPA EntityManager and its cached entity objects |
|
|
|
|
* and related context. As of Spring Framework 7.0, the default will be "false" in |
|
|
|
|
* alignment with other transaction managers, requiring an explicit switch to "true" |
|
|
|
|
* if you want to use nested transactions for JDBC access code which participates |
|
|
|
|
* in JPA transactions (provided that your JDBC driver supports savepoints). |
|
|
|
|
* <i>Note that JPA itself does not support nested transactions! Hence, do not |
|
|
|
|
* expect JPA access code to semantically participate in a nested transaction.</i> |
|
|
|
|
* |
|
|
|
|
* @author Juergen Hoeller |
|
|
|
|
* @since 2.0 |
|
|
|
|
|