Package com.atlassian.bamboo.persistence
Class BambooSessionFactoryUtils
java.lang.Object
com.atlassian.bamboo.persistence.BambooSessionFactoryUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidapplyTransactionTimeout(org.hibernate.Criteria criteria, org.hibernate.SessionFactory sessionFactory) static voidapplyTransactionTimeout(org.hibernate.query.Query query, org.hibernate.SessionFactory sessionFactory) Apply the current transaction timeout, if any, to the given Hibernate Query object.static @NotNull ConnectiongetConnection(org.hibernate.Session session) static org.hibernate.SessiongetNewSession(org.hibernate.SessionFactory sessionFactory)
-
Constructor Details
-
BambooSessionFactoryUtils
public BambooSessionFactoryUtils()
-
-
Method Details
-
getNewSession
public static org.hibernate.Session getNewSession(org.hibernate.SessionFactory sessionFactory) -
getConnection
-
applyTransactionTimeout
public static void applyTransactionTimeout(org.hibernate.query.Query query, org.hibernate.SessionFactory sessionFactory) Apply the current transaction timeout, if any, to the given Hibernate Query object.- Parameters:
query- the Hibernate Query objectsessionFactory- Hibernate SessionFactory that the Query was created for (may benull)- See Also:
-
Query.setTimeout(int)
-
applyTransactionTimeout
public static void applyTransactionTimeout(org.hibernate.Criteria criteria, org.hibernate.SessionFactory sessionFactory)
-