Transactions
Jump to navigation
Jump to search
ACID Atomic, Consistent, Isolatable, Durable
- Atomic - change whole or nothing (rolled back)
- Consistent - get the right result when you make a request
- Isolated - independent from other transactions
- Durable - survive power/system failure
- Declaritive
- Progamatic
Declaritive types
Required
Container must have a transaction
- start new transaction if none exist
- continue transaction if exists
Requires New
Container must always start a new transaction
- existing transaction must be suspended and a new transaction started
- new transaction independent of first/existing transaction
Not supported
- existing transaction suspended before calling method
Supports
- Transactions may continue but a new transaction is not started if none exists
Mandatory
- Transaction must always exist
- if none exists then TransactionRequiredException thrown
Never
- Transactions not allowed
- RemoteException thrown if client has a transaction