HHH-14903 The new getConfiguredJdbcBatchSize method optimisation should apply to StatelessSession as well
This commit is contained in:
parent
f9bc1a279a
commit
6c53a9d1ab
|
@ -233,6 +233,20 @@ public abstract class AbstractSharedSessionContract implements SharedSessionCont
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Override the implementation provided on SharedSessionContractImplementor
|
||||||
|
* which is not very efficient: this method is hot in Hibernate Reactive, and could
|
||||||
|
* be hot in some ORM contexts as well.
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public Integer getConfiguredJdbcBatchSize() {
|
||||||
|
final Integer sessionJdbcBatchSize = this.jdbcBatchSize;
|
||||||
|
return sessionJdbcBatchSize == null ?
|
||||||
|
fastSessionServices.defaultJdbcBatchSize :
|
||||||
|
sessionJdbcBatchSize;
|
||||||
|
}
|
||||||
|
|
||||||
protected void addSharedSessionTransactionObserver(TransactionCoordinator transactionCoordinator) {
|
protected void addSharedSessionTransactionObserver(TransactionCoordinator transactionCoordinator) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -300,20 +300,6 @@ public class SessionImpl
|
||||||
return new ActionQueue( this );
|
return new ActionQueue( this );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Override the implementation provided on SharedSessionContractImplementor
|
|
||||||
* which is not very efficient: this method is hot in Hibernate Reactive, and could
|
|
||||||
* be hot in some ORM contexts as well.
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
public Integer getConfiguredJdbcBatchSize() {
|
|
||||||
final Integer sessionJdbcBatchSize = getJdbcBatchSize();
|
|
||||||
return sessionJdbcBatchSize == null ?
|
|
||||||
fastSessionServices.defaultJdbcBatchSize :
|
|
||||||
sessionJdbcBatchSize;
|
|
||||||
}
|
|
||||||
|
|
||||||
private LockOptions getLockOptionsForRead() {
|
private LockOptions getLockOptionsForRead() {
|
||||||
return this.lockOptions == null ? fastSessionServices.defaultLockOptions : this.lockOptions;
|
return this.lockOptions == null ? fastSessionServices.defaultLockOptions : this.lockOptions;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue