HHH-11542 - Allow the auto-commit resolution to be configurable for RESOURCE_LOCAL transactions (default methods)

This commit is contained in:
Steve Ebersole 2017-04-13 22:30:29 -05:00 committed by Andrea Boriero
parent db528238d8
commit 97942914c8
2 changed files with 6 additions and 2 deletions

View File

@ -666,7 +666,9 @@ public interface SessionFactoryBuilder {
/**
* @see org.hibernate.cfg.AvailableSettings#CONNECTION_PROVIDER_DISABLES_AUTOCOMMIT
*/
SessionFactoryBuilder applyConnectionProviderDisablesAutoCommit(boolean providerDisablesAutoCommit);
default SessionFactoryBuilder applyConnectionProviderDisablesAutoCommit(boolean providerDisablesAutoCommit) {
return this;
}
/**
* Should Hibernate apply comments to SQL it generates?

View File

@ -181,7 +181,9 @@ public interface SessionFactoryOptions {
PhysicalConnectionHandlingMode getPhysicalConnectionHandlingMode();
boolean doesConnectionProviderDisableAutoCommit();
default boolean doesConnectionProviderDisableAutoCommit() {
return false;
}
/**
* @deprecated Use {@link #getPhysicalConnectionHandlingMode()} instead