diff options
author | Alex Taskov <alex.taskov@mongodb.com> | 2019-10-22 01:26:01 +0000 |
---|---|---|
committer | evergreen <evergreen@mongodb.com> | 2019-10-22 01:26:01 +0000 |
commit | 563dc7451690efa475db5feda913098e777471da (patch) | |
tree | d2aff492e3e35eac18df3d0dd3f684a49f5be463 | |
parent | db9291bfafb17427adb031ba0326d1acfc52bde0 (diff) | |
download | mongo-563dc7451690efa475db5feda913098e777471da.tar.gz |
SERVER-43689 getShardDistribution() incorrectly shows 0 chunks
-rw-r--r-- | src/mongo/shell/collection.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/shell/collection.js b/src/mongo/shell/collection.js index a6a81cf66a6..50bf9ac9008 100644 --- a/src/mongo/shell/collection.js +++ b/src/mongo/shell/collection.js @@ -1120,7 +1120,7 @@ DBCollection.prototype.getShardDistribution = function() { var shardStats = stats.shards[shard]; - var chunks = config.chunks.find({_id: sh._collRE(this), shard: shard}).toArray(); + var chunks = config.chunks.find({ns: stats.ns, shard: shard}).toArray(); numChunks += chunks.length; |