public Session openSession() throws HibernateException { return withOptions().openSession(); }
private Session buildEntityManager(SynchronizationType synchronizationType, Map map) { assert !isClosed; SessionBuilderImplementor builder = withOptions(); if ( synchronizationType == SynchronizationType.SYNCHRONIZED ) { builder.autoJoinTransactions( true ); } else { builder.autoJoinTransactions( false ); } final Session session = builder.openSession(); if ( map != null ) { map.keySet().forEach( key -> { if ( key instanceof String ) { session.setProperty( (String) key, map.get( key ) ); } } ); } return session; }
public Session openTemporarySession() throws HibernateException { return withOptions() .autoClose( false ) .flushMode( FlushMode.MANUAL ) .connectionHandlingMode( PhysicalConnectionHandlingMode.DELAYED_ACQUISITION_AND_RELEASE_AFTER_STATEMENT ) .openSession(); }
public Session openSession() throws HibernateException { return withOptions().openSession(); }
public Session openSession() throws HibernateException { return withOptions().openSession(); }
public Session openSession() throws HibernateException { return withOptions().openSession(); }
private Session buildEntityManager(SynchronizationType synchronizationType, Map map) { assert !isClosed; SessionBuilderImplementor builder = withOptions(); if ( synchronizationType == SynchronizationType.SYNCHRONIZED ) { builder.autoJoinTransactions( true ); } else { builder.autoJoinTransactions( false ); } final Session session = builder.openSession(); if ( map != null ) { map.keySet().forEach( key -> { if ( key instanceof String ) { session.setProperty( (String) key, map.get( key ) ); } } ); } return session; }
public Session openTemporarySession() throws HibernateException { return withOptions() .autoClose( false ) .flushBeforeCompletion( false ) .connectionReleaseMode( ConnectionReleaseMode.AFTER_STATEMENT ) .openSession(); }
public Session openTemporarySession() throws HibernateException { return withOptions() .autoClose( false ) .flushMode( FlushMode.MANUAL ) .connectionHandlingMode( PhysicalConnectionHandlingMode.DELAYED_ACQUISITION_AND_RELEASE_AFTER_STATEMENT ) .openSession(); }
public Session openTemporarySession() throws HibernateException { return withOptions() .autoClose( false ) .flushBeforeCompletion( false ) .connectionReleaseMode( ConnectionReleaseMode.AFTER_STATEMENT ) .openSession(); }