recordIdsReplicated:true collections can trigger dassert

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Gone away
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Storage Execution
    • ALL
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      This dassert that enforces that recordIds are strictly increasing seems like it can be triggered by clustered collections.

      Not sure how that hasn't happened already, and if it's impossible to be triggered, why is that the case?

      Edit: see comments for why it's not possible on clustered collections.

      We still need to fix this for replicated recordIds. Easy way to reproduce this bug:

      db.runCommand({create: "newcoll", recordIdsReplicated: true});
      let ops = [];
      for (let i = 0; i < 100; i++) {
          ops.push({
              op: 'i',
              ns: "test.newcoll",
              o: {
                  _id: i - 1000,
              },
              o2: {
                  _id: i - 1000,
              },
              rid: 100 - i
          });
      }
      db.runCommand({
          applyOps: ops
      });
      

      The secondary will crash on the dassert.

            Assignee:
            [DO NOT USE] Backlog - Storage Execution Team
            Reporter:
            Vishnu Kaushik
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: