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

split with find doesn't work if chunk has only 1 document

    • ALL
    • Sharding 2019-12-30, Sharding 2020-01-13, Sharding 2020-01-27

      db.adminCommand({ enableSharding: 'test' });
      db.adminCommand({ shardCollection: 'test.user', key: { x: 1 }});
      db.adminCommand({ split: 'test.user', middle: { x: 0 }})
      db.adminCommand({ split: 'test.user', middle: { x: 100 }})
      db.user.insert({ x: 1 })
      db.adminCommand({ split: 'test.user', find: { x: 1 }})
      

      returns:

      { "cause" : { }, "ok" : 0, "errmsg" : "split failed" }
      

      Note: if the collection was not presplit, the split command will run fine because of special case handling on chunks with MinKey or MaxKey as boundaries.

            Assignee:
            marcos.grillo@mongodb.com Marcos José Grillo Ramirez
            Reporter:
            randolph@mongodb.com Randolph Tan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: