public class TransactionException extends IgniteException
CacheAtomicityMode.TRANSACTIONALcache - any method throwing this or nested exception have transactional behaviour (it can be rolled back and not seen outside transaction before committed). In case of
CacheAtomicityMode.ATOMICcache - every action is committed when it done.
Before doing main thing, all transactional methods (commit, rollback and close) must obtain a readLock from context's gateway to prevent simultaneous actions which can break result of transaction. Then method delegates action to internal transaction representation which can fail in some cases and throw exception. Anyway, if there is success or fail, method must free gateway lock.
TransactionDeadlockException If deadlock detected within transaction.
TransactionHeuristicException If operation performs within transaction that entered an unknown state.
TransactionOptimisticException If operation with optimistic behavior failed.
TransactionRollbackException If operation performs within transaction that automatically rolled back.
TransactionTimeoutException If operation performs within transaction and timeout occurred.
TransactionSerializationException If operation performs within mvcc transaction and write conflict occurred.
|Constructor and Description|
Creates empty exception.
Creates new exception with given error message.
Creates new exception with given error message and optional nested exception.
Creates new transaction exception with given throwable as a cause and source of error message.
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
public TransactionException(String msg)
msg- Error message.
public TransactionException(Throwable cause)
cause- Non-null throwable cause.