Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-88158

Remove support for 'alwaysUpsert' in applyOps

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Replication
    • Minor Change
    • Repl 2024-11-11

      Back when we had atomic applyOps, we had an "alwaysUpsert" field in applyOps which would tell secondaries whether a 'u' operation should be treated as an upsert. Confusingly, this field defaults to "true" for applyOps operations without a transaction number. We haven't had atomic applyOps since 6.2, so we should be able to remove support for alwaysUpsert and treat it as always false.

      This will make things easier if we support batching of updates in applyOps entries; right now such updates will be treated as upserts, which, while it should not result in incorrect operation, bypasses checks for consistency.

            Assignee:
            joy.wang@mongodb.com Joy Wang
            Reporter:
            matthew.russotto@mongodb.com Matthew Russotto
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: