Transactions

From sheep
Revision as of 21:27, 14 September 2021 by Martin (talk | contribs) (Created page with "= ACID Atomic, Consistent, Isolatable, Durable = * Atomic - change whole or nothing (rolled back) * Consistent - get the right result when you make a request * Isolated - inde...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
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
  1. Declaritive
  2. 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