Two-Phase Commit - CI/CD用語集の定義
Two-phase commit (2PC) は、複数の参加者にまたがってトランザクションをアトミックにコミットするためのプロトコルです。コーディネーターがまず全員に準備を求め、全員がyesと投票した場合にのみコミットを指示し、そうでなければ全員がアボートします。
トレードオフ
2PCは準備後にコーディネーターが障害を起こすとブロックするため、分散システムでは長時間実行されるサービス間の作業にはsaga patternを好むことが多いです。
関連ガイド
Saga Pattern - CI/CD Glossary DefinitionThe saga pattern coordinates a multi-service transaction as a sequence of local steps, each with a compensati…
Consensus - CI/CD Glossary DefinitionConsensus is the problem of getting distributed nodes to agree on a single value despite failures; Raft and P…
Quorum - CI/CD Glossary DefinitionA quorum is the minimum number of nodes that must agree for an operation to count as committed, ensuring over…