[SERVER-9022] Enable mongos mode which releases ShardConnections to the pool after read ops Created: 19/Mar/13 Updated: 27/Oct/15 Resolved: 20/Mar/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | None |
| Fix Version/s: | 2.2.4, 2.4.2, 2.5.0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Daniel Pasette (Inactive) | Assignee: | Greg Studer |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||
| Backwards Compatibility: | Minor Change | ||||||||||||||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||||||||||||||
| Description |
|
Create a new serverParameter for mongos, "releaseConnectionsAfterResponse," which enables returning ShardConnections from the per-socket pool to the global pool after each read operation. This should reduce the total number of outgoing mongos connections to each shard. Warning: Enabling this option on mongos comes with the caveat that clients can only call getLastError immediately after an actual write operation. This is fine for the vast majority of use cases. However, if an application does:
If your application only ever calls GLE immediately after an actual write op (which is the same as using safe mode), this option will provide a good bit of multiplexing. The behavior is off by default. To turn the behavior on (and off) a running mongos, use the standard setParameter framework -
To turn the behavior on at startup in a 2.4 mongos (this is not available before 2.4), you can also use:
|
| Comments |
| Comment by auto [ 21/Mar/13 ] |
|
Author: {u'date': u'2013-03-21T22:03:39Z', u'name': u'Dan Pasette', u'email': u'dan@10gen.com'}Message: |
| Comment by auto [ 20/Mar/13 ] |
|
Author: {u'date': u'2013-03-20T16:54:47Z', u'name': u'Greg Studer', u'email': u'greg@10gen.com'}Message: |
| Comment by Greg Studer [ 19/Mar/13 ] |
|
Author: {u'date': u'2013-03-14T19:03:03Z', u'name': u'Greg Studer', u'email': u'greg@10gen.com'}Message: |