diff options
author | Esha Maharishi <esha.maharishi@mongodb.com> | 2016-09-13 15:33:30 -0400 |
---|---|---|
committer | Esha Maharishi <esha.maharishi@mongodb.com> | 2016-09-15 15:40:11 -0400 |
commit | 5b0901ea6a1b9b90d2cee8263b8c60013d7c6979 (patch) | |
tree | 521e4f207f6c844a47c0112f4b142ae3af09f64f /src/mongo/db/s/sharding_state.h | |
parent | eec91f97a655486892f6c75342adcffc68109f0e (diff) | |
download | mongo-5b0901ea6a1b9b90d2cee8263b8c60013d7c6979.tar.gz |
SERVER-25458 unit tests for ShardingState::initializeShardingAwarenessIfNeeded
Diffstat (limited to 'src/mongo/db/s/sharding_state.h')
-rw-r--r-- | src/mongo/db/s/sharding_state.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/mongo/db/s/sharding_state.h b/src/mongo/db/s/sharding_state.h index d9acc7a7eb9..bd06604b79f 100644 --- a/src/mongo/db/s/sharding_state.h +++ b/src/mongo/db/s/sharding_state.h @@ -259,8 +259,13 @@ public: * on disk, if there is one. * If started with --shardsvr in queryableBackupMode, initializes sharding awareness from the * shardIdentity document passed through the --overrideShardIdentity startup parameter. + * + * If returns true, the ShardingState::_globalInit method was called, meaning all the core + * classes for sharding were initialized, but no networking calls were made yet (with the + * exception of the duplicate ShardRegistry reload in ShardRegistry::startup() (see + * SERVER-26123). Outgoing networking calls to cluster members can now be made. */ - Status initializeShardingAwarenessIfNeeded(OperationContext* txn); + StatusWith<bool> initializeShardingAwarenessIfNeeded(OperationContext* txn); /** * Check if a command is one of the whitelisted commands that can be accepted with shardVersion |