resume_after_against_oplog.js assumes no background oplog writes during awaitData

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Minor - P4
    • 9.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Replication
    • Fully Compatible
    • ALL
    • Repl 2026-08-17
    • 200
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      jstests/replsets/resume_after_against_oplog.js tails the oplog and asserts that a getMore returning no results leaves the resume token unchanged. But the oplog resume token tracks the last oplog entry the scan passed over, not the last one matching the filter, so any unrelated write during the wait moves it. This was seen on disagg replica sets, where background HMAC key generation created admin.system.keys right as the test was waiting, and the token advanced.

      The assertion has been racy since the resume token behavior was introduced in SERVER-51227; the test was only recently enabled on disagg (SERVER-132203), which is what exposed it. Timing-dependent, so it will be flaky rather than consistent.

      Failing assertion: line 169, assert.eq(timestampCmp(resumeToken3.ts, resumeToken2.ts), 0)

      Fix: relax the assertion to allow the token to advance, or make the test deterministic by waiting for key generation before starting the tailable query. The relaxation is preferable, since background oplog writes can come from any source, not just key generation.

      Failing task: mongodb_mongo_master_enterprise_amazon_linux2023_arm64_all_feature_flags_extra_system_deps_disagg_replica_sets_3 @ 904c9585f3ce

            Assignee:
            Denis Trailin
            Reporter:
            Denis Trailin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: