Change kPrimaryDriven from an IndexBuildMethod to IndexBuildProtocol

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Storage Execution
    • Storage Execution 2025-09-01, Storage Execution 2025-09-15, Storage Execution 2025-09-29, Storage Execution 2025-11-10, Storage Execution 2025-11-24, Storage Execution 2025-12-8
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Index builds have both a concept of a "protocol" and a concept of a "method".

      The protocol defines how the index build is replicated; a single-phase index build is replicated via a single "createIndexes" oplog entry, a two-phase index build is replicated via "startIndexBuild" and "commitIndexBuild" oplog entries, and primary-driven index builds are replicated via "startIndexBuild", "commitIndexBuild", and ci/cd oplog entries.

      The method defines whether the index build blocks concurrent writes or not; a foreground index build requires exclusive write access to the collection while a hybrid index build allows for concurrent writes.

      Currently "primary-driven" is defined in the code as a method, despite it conceptually much more closely aligning with protocol. Thus, we should see if we can change it to be a protocol.

            Assignee:
            Jess Balint
            Reporter:
            Stephanie Eristoff
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: