diff options
Diffstat (limited to 'jstests/sharding')
-rw-r--r-- | jstests/sharding/shard3.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/jstests/sharding/shard3.js b/jstests/sharding/shard3.js index e27316e..8ee566e 100644 --- a/jstests/sharding/shard3.js +++ b/jstests/sharding/shard3.js @@ -61,7 +61,7 @@ function doCounts( name , total , onlyItCounts ){ } var total = doCounts( "before wrong save" ) -secondary.save( { num : -3 } ); +secondary.save( { _id : 111 , num : -3 } ); printjson( secondary.getDB().getLastError() ) doCounts( "after wrong save" , total , true ) e = a.find().explain(); @@ -69,6 +69,12 @@ assert.eq( 3 , e.n , "ex1" ) assert.eq( 4 , e.nscanned , "ex2" ) assert.eq( 1 , e.nChunkSkips , "ex3" ) + +// SERVER-4612 +// make sure idhack obeys chunks +x = a.findOne( { _id : 111 } ) +assert( ! x , "idhack didn't obey chunk boundaries " + tojson(x) ); + // --- move all to 1 --- print( "MOVE ALL TO 1" ); |