-
Type:
New Feature
-
Resolution: Done
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: Diagnostics, Sharding
-
None
-
Fully Compatible
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Currently, the connPoolStats will only get stats from the extern pool object. This is linked to the pool ScopedDBConnection uses and it does not include the shardConnectionPool.
Add a new command called "shardConnPoolStats" which will show information on the per thread (incoming connection) connection status. Sample output for a sharded cluster with a single replica set below:
mongos> db.runCommand( { 'shardConnPoolStats': 1 } )
{
"hosts" : {
"test-rs0/dan-tm2:31100,dan-tm2:31101,dan-tm2:31102::0" : {
"available" : 0,
"created" : 2
}
},
"replicaSets" : {
"test-rs0" : {
"hosts" : [
{
"addr" : "dan-tm2:31100",
"ok" : true,
"ismaster" : true,
"hidden" : false,
"secondary" : false,
"pingTimeMillis" : 0
},
{
"addr" : "dan-tm2:31101",
"ok" : true,
"ismaster" : false,
"hidden" : false,
"secondary" : true,
"pingTimeMillis" : 0
},
{
"addr" : "dan-tm2:31102",
"ok" : true,
"ismaster" : false,
"hidden" : false,
"secondary" : true,
"pingTimeMillis" : 0
}
],
"master" : 0,
"nextSlave" : 0
}
},
"createdByType" : {
"set" : 2
},
"totalAvailable" : 0,
"totalCreated" : 2,
"threads" : [
{
"hosts" : [
{
"host" : "test-rs0/dan-tm2:31100,dan-tm2:31101,dan-tm2:31102",
"created" : NumberLong(1),
"avail" : true
}
],
"seenNS" : [
"test.data"
]
},
{
"hosts" : [
{
"host" : "test-rs0/dan-tm2:31100,dan-tm2:31101,dan-tm2:31102",
"created" : NumberLong(1),
"avail" : true
}
],
"seenNS" : [
"test.data"
]
}
],
"ok" : 1
}
- is duplicated by
-
SERVER-8812 connPoolStats and connPoolSync should operate on all connection pools
-
- Closed
-
- is related to
-
SERVER-6611 Add a new field in connPoolStats to indicate how many connections are in use
-
- Closed
-
- related to
-
SERVER-9022 Enable mongos mode which releases ShardConnections to the pool after read ops
-
- Closed
-