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

dbcheck doesn't check MinKey

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major - P3 Major - P3
    • None
    • None
    • None
    • Replication
    • ALL

    Description

      dbcheck always uses a BoundInclusion::kIncludeEndKeyOnly, and always passes into the InternalPlanner a minimum value of MinKey, so that minimum value is excluded from the hash.

      If in dbcheck.js you add the godinsert below (an insert that doesn't go into the oplog), you would expect the test to fail but it does not. This will be partially fixed in SERVER-74681, but likely not fully fixed.

      // Name for a collection which takes multiple batches to check and which shouldn't be modified
      // by any of the tests.
      const multiBatchSimpleCollName = "dbcheck-simple-collection";
      const multiBatchSimpleCollSize = 10000;
      replSet.getPrimary().getDB(dbName)[multiBatchSimpleCollName].insertMany(
          [...Array(10000).keys()].map(x => ({_id: x})), {ordered: false});
       
      // This should cause this test to fail.
      assert.commandWorked(replSet.getPrimary().getDB(dbName).runCommand(
          {godinsert: multiBatchSimpleCollName, obj: {_id: MinKey}}));
      }}
      

      Attachments

        Activity

          People

            backlog-server-repl Backlog - Replication Team
            judah.schvimer@mongodb.com Judah Schvimer
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: