summaryrefslogtreecommitdiff
path: root/src/mongo/client/parallel.cpp
diff options
context:
space:
mode:
authorRandolph Tan <randolph@10gen.com>2014-10-06 17:36:18 -0400
committerRandolph Tan <randolph@10gen.com>2014-10-15 11:03:20 -0400
commit126069374744c62c65fac86a492531d658961f40 (patch)
tree9ea6d5070815c5e1dba6119cee7dcf19b4aaf67c /src/mongo/client/parallel.cpp
parent8cbf581a2694c496681b8fd12e2cc03747358869 (diff)
downloadmongo-126069374744c62c65fac86a492531d658961f40.tar.gz
SERVER-15402 Improve ShardPtr/ConnectionString management for commands and setVersion
Make Shard almost logically immutable. The only non-const method remaining is reset(), which will eventually be removed.
Diffstat (limited to 'src/mongo/client/parallel.cpp')
-rw-r--r--src/mongo/client/parallel.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mongo/client/parallel.cpp b/src/mongo/client/parallel.cpp
index a1dd6811386..9995ee4c46a 100644
--- a/src/mongo/client/parallel.cpp
+++ b/src/mongo/client/parallel.cpp
@@ -660,7 +660,9 @@ namespace mongo {
warning() << "Weird shift of primary detected" << endl;
compatiblePrimary = primary && state->primary && primary == state->primary;
- compatibleManager = manager && state->manager && manager->compatibleWith( state->manager, shard );
+ compatibleManager = manager &&
+ state->manager &&
+ manager->compatibleWith(*state->manager, shard.getName());
if( compatiblePrimary || compatibleManager ){
// If we're compatible, don't need to retry unless forced