Top Description Constructors Methods
org.springframework.orm.hibernate5

public Class SpringJtaSessionContext

extends JTASessionContext
Class Inheritance
Annotations
@SuppressWarnings:serial
Imports
org.hibernate.FlushMode, .Session, org.hibernate.context.internal.JTASessionContext, org.hibernate.engine.spi.SessionFactoryImplementor, org.springframework.transaction.support.TransactionSynchronizationManager

Spring-specific subclass of Hibernate's JTASessionContext, setting FlushMode.MANUAL for read-only transactions.
Author
Juergen Hoeller
Since
4.2

Constructor Summary

AccessConstructor and Description
public
SpringJtaSessionContext(SessionFactoryImplementor factory)

Deprecated as a consequence of SessionFactoryImplementor being deprecated.

Method Summary

Modifier and TypeMethod and Description
protected Session
buildOrObtainSession()

Overrides org.hibernate.context.internal.JTASessionContext.buildOrObtainSession.

Deprecated as a consequence of Session being deprecated.
Strictly provided for subclassing purposes; specifically to allow long-session support.
Inherited from org.hibernate.context.internal.JTASessionContext:
currentSessiongetConnectionReleaseModeisAutoCloseEnabledisAutoFlushEnabled

Constructor Detail

SpringJtaSessionContextback to summary
public SpringJtaSessionContext(SessionFactoryImplementor factory)

Deprecated

as a consequence of SessionFactoryImplementor being deprecated. See corresponding docs for further information.

Method Detail

buildOrObtainSessionback to summary
protected Session buildOrObtainSession()

Overrides org.hibernate.context.internal.JTASessionContext.buildOrObtainSession.

Doc from org.hibernate.context.internal.JTASessionContext.buildOrObtainSession.

Deprecated

as a consequence of Session being deprecated. See corresponding docs for further information.

Strictly provided for subclassing purposes; specifically to allow long-session support. This implementation always just opens a new session.

Returns:Session

the built or (re)obtained session.

Annotations
@Override