Skip to main content

4 docs tagged with "transaction"

View all tags

Transaction Management — Where to Place the Consistency Boundary

Explains transaction management using Laravel's DB::transaction(). Covers the ACID properties, when to place transactions inside the Repository (single aggregate) versus the UseCase (multiple aggregates), nested transactions (savepoints), and the implementation and use cases of optimistic and pessimistic locking.

トランザクション — ACID とコミット・ロールバック

トランザクションの基本操作 (開始・コミット・ロールバック) と ACID の 4 特性を解説します。ロールバックが取り消す範囲が自分のトランザクションに限られること、コミット後は取り消せないこと、構文エラーが発生するタイミングを扱います。

ロックと分離レベル — 同時実行の制御

共有ロックと排他ロック、4 つのトランザクション分離レベルと 3 つの読み取り異常、楽観ロックと悲観ロックの使い分け、デッドロックの原因と回避方法を解説します。分離レベルを上げてもロック無しでは競合が防げない理由を扱います。