mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 09:32:32 +01:00
try to make replacepeer2 more reliable
This commit is contained in:
parent
32a30aa221
commit
94c729f866
@ -44,15 +44,8 @@ doTest = function( signal ) {
|
|||||||
checkWrite( rp.master(), rp.slave() );
|
checkWrite( rp.master(), rp.slave() );
|
||||||
|
|
||||||
// allow slave to finish initial sync
|
// allow slave to finish initial sync
|
||||||
assert.soon(
|
var res = rp.slave().getDB( "admin" ).runCommand( {replacepeer:1} );
|
||||||
function() {
|
assert( res.ok , "replacepeer didn't finish: " + tojson( res ) );
|
||||||
var res = rp.slave().getDB( "admin" ).runCommand( {replacepeer:1} );
|
|
||||||
if ( res.ok == 1 )
|
|
||||||
return true;
|
|
||||||
printjson( res );
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
// Should not be saved to slave.
|
// Should not be saved to slave.
|
||||||
writeOne( rp.master() );
|
writeOne( rp.master() );
|
||||||
|
Loading…
Reference in New Issue
Block a user