diff options
author | Patrick Steinhardt <psteinhardt@gitlab.com> | 2020-08-25 09:07:22 +0300 |
---|---|---|
committer | Patrick Steinhardt <psteinhardt@gitlab.com> | 2020-08-25 09:07:22 +0300 |
commit | 890f511cf4ee2b1e78c57e590b39ebbdf0840f5e (patch) | |
tree | d67f734a2e061984c74945f606820d0e3c496403 | |
parent | 27e1cf71e40a27e829dfeee1eb237af190a13244 (diff) | |
parent | 2e0d27f899cc75815962514e44e7def76b01563f (diff) |
Merge branch 'pks-transaction-terminology' into 'master'
Document transaction-related terminology
See merge request gitlab-org/gitaly!2477
-rw-r--r-- | doc/design_ha.md | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/design_ha.md b/doc/design_ha.md index e00238a07..16a733ec6 100644 --- a/doc/design_ha.md +++ b/doc/design_ha.md @@ -15,6 +15,30 @@ The following terminology may be used within the context of the Gitaly Cluster p - RPC categories (#1496): - Accessor - a side effect free (or read-only) RPC; does not modify the git repo (!228) - Mutator - an RPC that modifies the data in the git repo (!228) +- Transaction - mechanism used to ensure that a set of voters agree on the same + modifications. + - Voter - a node registered in a transaction. Only registered voters may + cast votes in transactions. + - Vote - the change a voter intends to commit if the transaction succeeds. + This is e.g. the hash of all references which are to be updated in their + old and new state. + - Quorum - minimum number of voters required to agree in order to commit a + transaction. + - Voting strategy - defines how many nodes are required to reach quorum. + - strong - all nodes need to agree. + - primary-wins - the transaction always succeeds as long as the primary + has cast a vote. + - majority-wins - the transaction succeeds when the primary and at least + half of the secondaries agree. + - Subtransactions - ordered list of voting processes of a transaction. For + each vote cast by a voter, a new subtransaction is created. For a + transaction to be successful, all subtransactions need to be successful. + This is done so that Gitaly may perform multiple modifications in a single + transaction. + - reference-transaction - Git mechanism to update references. The + [reference-transaction hook](https://git-scm.com/docs/githooks#_reference_transaction) + directly hooks into this mechanism whenever a reference is being updated + via Git. ## Design The high level design takes a reverse proxy approach to fanning out write requests to the appropriate nodes: |