Multi-leader store without a conflict policy

warningmulti-leader-store-without-conflict-policy

Multi-leader replication accepts concurrent writes in several regions. With no conflict resolution policy declared, divergent replicas are reconciled by accident rather than by design.

Severity
warning
Selects
every node of kind nosql-database
Components in scope
47
What it checks

It looks at every node of kind nosql-database, and fires when:

  • — all of these hold:
  • — the node's `replication` is "multi-region-multi-leader"
  • — any of these hold:
  • — the node's `conflictResolution` has no value
  • — the node's `conflictResolution` is "none"
Message
Store '{{node.id}}' is multi-leader across regions with no conflict resolution policy. Declare last-writer-wins, vector-clock or app-merge.

{{node.id}} style paths are filled in from the node, the edge or the design the finding is about.

Applies to · 47 components
Tripped by · 10

Reference designs whose broken twin names this rule in its header. The gate reads the same header, and fails when a rule no design trips.

Source
# yaml-language-server: $schema=../schema/rule.schema.json
# Multi-leader replication accepts concurrent writes in several regions. Without a declared
# conflict resolution policy, divergent replicas are reconciled by accident.
# Tripped by: designs/object-storage.broken.yaml
schemaVersion: "1"
type: "rule"
id: "multi-leader-store-without-conflict-policy"
severity: "warning"
select:
  node:
    kind: "nosql-database"
when:
  all:
    - prop: "replication"
      equals: "multi-region-multi-leader"
    - any:
        - prop: "conflictResolution"
          exists: false
        - prop: "conflictResolution"
          equals: "none"
message: "Store '{{node.id}}' is multi-leader across regions with no conflict resolution policy. Declare last-writer-wins, vector-clock or app-merge."

The same page as markdown, for an agent: /catalogue/rules/multi-leader-store-without-conflict-policy.md