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

Splits can fail if the split point was once a chunk boundary

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 2.5.4
    • 2.5.3
    • Sharding
    • None
    • Fully Compatible
    • ALL
    • Hide

      var st = new ShardingTest({ shards: 2, mongos: 2 });
      st.stopBalancer();
       
      var configDB = st.s.getDB('config');
      configDB.adminCommand({ enableSharding: 'test' });
      configDB.adminCommand({ shardCollection: 'test.user', key: { x: 1 }});
      configDB.adminCommand({ split: 'test.user', middle: { x: 0 }});
       
      var configDB2 = st.s1.getDB('config');
      configDB2.adminCommand({ mergeChunks: 'test.user', bounds: [{ x: MinKey }, { x: MaxKey }]});
       
      // This test will pass if flushRouterConfig is called here.
      var res = configDB.adminCommand({ split: 'test.user', middle: { x: 0 }});
      assert(res.ok, 'command failed: ' + tojson(res));
       
      st.stop();

      Show
      var st = new ShardingTest({ shards: 2, mongos: 2 }); st.stopBalancer();   var configDB = st.s.getDB('config'); configDB.adminCommand({ enableSharding: 'test' }); configDB.adminCommand({ shardCollection: 'test.user', key: { x: 1 }}); configDB.adminCommand({ split: 'test.user', middle: { x: 0 }});   var configDB2 = st.s1.getDB('config'); configDB2.adminCommand({ mergeChunks: 'test.user', bounds: [{ x: MinKey }, { x: MaxKey }]});   // This test will pass if flushRouterConfig is called here. var res = configDB.adminCommand({ split: 'test.user', middle: { x: 0 }}); assert(res.ok, 'command failed: ' + tojson(res));   st.stop();

    Attachments

      Activity

        People

          randolph@mongodb.com Randolph Tan
          randolph@mongodb.com Randolph Tan
          Votes:
          0 Vote for this issue
          Watchers:
          1 Start watching this issue

          Dates

            Created:
            Updated:
            Resolved: