Package org.hibernate
Class PessimisticLockException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
jakarta.persistence.PersistenceException
org.hibernate.HibernateException
org.hibernate.JDBCException
org.hibernate.PessimisticLockException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
LockAcquisitionException
Thrown when a pessimistic locking conflict occurs.
- See Also:
- API Note:
- When a conflict is detected while acquiring a database-level lock,
LockAcquisitionException
is preferred.
-
Constructor Summary
ConstructorsConstructorDescriptionPessimisticLockException
(String message, SQLException sqlException) Constructs aPessimisticLockException
using the specified information.PessimisticLockException
(String message, SQLException sqlException, String sql) Constructs aPessimisticLockException
using the specified information. -
Method Summary
Methods inherited from class org.hibernate.JDBCException
getErrorCode, getErrorMessage, getSQL, getSQLException, getSQLState
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
PessimisticLockException
Constructs aPessimisticLockException
using the specified information.- Parameters:
message
- A message explaining the exception conditionsqlException
- The underlying SQL exceptionsql
- The sql that led to the exception (possibly null, but usually not)
-
PessimisticLockException
Constructs aPessimisticLockException
using the specified information.- Parameters:
message
- A message explaining the exception conditionsqlException
- The underlying SQL exception
-