[SERVER-27526] Get rid of all non-metadata usages of DBConfig::isShardingEnabled Created: 27/Dec/16 Updated: 05/Apr/17 Resolved: 28/Dec/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | 3.5.1 |
| Fix Version/s: | 3.4.2, 3.5.2 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Kaloian Manassiev | Assignee: | Kaloian Manassiev |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||
| Backport Requested: |
v3.4
|
||||||||||||
| Sprint: | Sharding 2017-01-02 | ||||||||||||
| Participants: | |||||||||||||
| Description |
|
The DBConfig::isShardingEnabled function should only be called for metadata commands which want to prevent operations form happening on non-sharding enabled database. The only two such commands are copydb and shardCollection. All other usages should be removed. Also, the DBConfig::getAllShardedCollections function is only used in the database-wide metadata commands movePrimary and dropDatabase. Since these commands must always run with a fully up-to-date metadata, there is no point in them using the cached collections list so DBConfig::getAllShardedCollections is unnecessary and should be removed. |
| Comments |
| Comment by Githook User [ 04/Jan/17 ] |
|
Author: {u'username': u'kaloianm', u'name': u'Kaloian Manassiev', u'email': u'kaloian.manassiev@mongodb.com'}Message: (cherry picked from commit efb9ace86bac133fb9f9c17fbb598a45871206ea) |
| Comment by Githook User [ 28/Dec/16 ] |
|
Author: {u'username': u'kaloianm', u'name': u'Kaloian Manassiev', u'email': u'kaloian.manassiev@mongodb.com'}Message: |