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

Background indexes created through applyOps should run on the command thread

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.6.11, 4.0.7, 4.1.7
    • Affects Version/s: 3.6.9, 4.0.5, 4.1.6
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • v4.0, v3.6
    • Hide

      The following test reproduces this issue:

      (function() {
          "use strict";
      
          const dbName = "applyOpsReplicatedCreateIndexCrash";
          const collName = "coll";
      
          const rst = new ReplSetTest({nodes: 2});
          rst.startSet();
          rst.initiate();
          const db = rst.getPrimary().getDB(dbName);
          const coll = db.getCollection(collName);
      
          db.coll.drop();
          db.coll.insert({});
          db.adminCommand({
              applyOps: [{
                  op: 'c', ns: coll.getFullName(), o: {
                      createIndexes: coll.getName(),
                      v: 2,
                      background: {a: 1},
                      name: 'a_1_create_v2',
                      unknown: 1
                  }
              }]
          });
      
          rst.stopSet();
      })();
      
      Show
      The following test reproduces this issue: (function() { "use strict" ; const dbName = "applyOpsReplicatedCreateIndexCrash" ; const collName = "coll" ; const rst = new ReplSetTest({nodes: 2}); rst.startSet(); rst.initiate(); const db = rst.getPrimary().getDB(dbName); const coll = db.getCollection(collName); db.coll.drop(); db.coll.insert({}); db.adminCommand({ applyOps: [{ op: 'c' , ns: coll.getFullName(), o: { createIndexes: coll.getName(), v: 2, background: {a: 1}, name: 'a_1_create_v2' , unknown: 1 } }] }); rst.stopSet(); })();
    • Storage NYC 2019-01-14, Storage NYC 2019-01-28
    • 6
    • 5

      Fatal Assertion 50769 on invalid replicated index build, created via applyOps

            Assignee:
            louis.williams@mongodb.com Louis Williams
            Reporter:
            james.wahlin@mongodb.com James Wahlin
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: