Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

SERVER-6162 adapt sharding/no_empty_reset.js for v2.0

The test jstests/sharding/no_empty_reset.js was using some
functionality that wasn't present in the 2.0 shell.  Add code
to find the shard name manually to adapt for this.
  • Loading branch information...
commit dd36d37c09408cd0fac5c40b48c071afd7491b1e 1 parent 75fa25b
@tadmarshall tadmarshall authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  jstests/sharding/no_empty_reset.js
View
1  jstests/sharding/no_empty_reset.js
@@ -25,6 +25,7 @@ jsTestLog( "Migrating via first mongos..." )
var fullShard = st.getShard( coll, { _id : 1 } )
var emptyShard = st.getShard( coll, { _id : -1 } )
+fullShard.shardName = st.s.getDB( "config" ).chunks.findOne({ "min._id" : 0 }).shard
var admin = st.s.getDB( "admin" )
printjson( admin.runCommand({ moveChunk : "" + coll, find : { _id : -1 }, to : fullShard.shardName }) )
Please sign in to comment.
Something went wrong with that request. Please try again.