mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 09:32:32 +01:00
reload option for getShardManager
This commit is contained in:
parent
d58828ebb0
commit
d417bc0802
@ -72,9 +72,9 @@ namespace mongo {
|
||||
|
||||
}
|
||||
|
||||
ShardManager* DBConfig::getShardManager( const string& ns ){
|
||||
ShardManager* DBConfig::getShardManager( const string& ns , bool reload ){
|
||||
ShardManager* m = _shards[ns];
|
||||
if ( m )
|
||||
if ( m && ! reload )
|
||||
return m;
|
||||
|
||||
uassert( (string)"not sharded:" + ns , sharded( ns ) );
|
||||
|
@ -62,7 +62,7 @@ namespace mongo {
|
||||
*/
|
||||
bool sharded( const string& ns );
|
||||
|
||||
ShardManager* getShardManager( const string& ns );
|
||||
ShardManager* getShardManager( const string& ns , bool reload = false );
|
||||
|
||||
/**
|
||||
* @return the correct for machine for the ns
|
||||
|
Loading…
Reference in New Issue
Block a user