[SERVER-30148] Move force primary refresh functionality out of the ShardServerCatalogCacheLoader into the ShardingState's refresh logic Created: 14/Jul/17 Updated: 06/Dec/22 Resolved: 17/Dec/21 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Dianna Hohensee (Inactive) | Assignee: | [DO NOT USE] Backlog - Sharding EMEA |
| Resolution: | Won't Do | Votes: | 0 |
| Labels: | ShardingTechDebt | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||
| Assigned Teams: |
Sharding EMEA
|
||||||||||||||||||||||||||||||||||||||||
| Sprint: | Sharding 2017-12-04 | ||||||||||||||||||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||||||||||||||||||
| Description |
|
We want to simplify the ShardServerCatalogCacheLoader by making a simple local loader and reader of chunk metadata. So we want to move the remote call to ensure the primary has refreshed to the latest metadata out of the ShardServerCatalogCacheLoader and instead place this functionality at a higher level in the refresh logic in ShardingState::onStaleShardVersion. A rough sketch:
|
| Comments |
| Comment by Dianna Hohensee (Inactive) [ 15/Nov/17 ] |
|
We're considering creating a new interruptible class/data structure, somewhat similar to the LockManager, except it just handles serializing operations per namespace. Linking |
| Comment by Dianna Hohensee (Inactive) [ 14/Nov/17 ] |
|
Given the fact that ShardingState would seem to need to know primary versus secondary status in order to do the correct operations, and the difficulty of preventing all waiting callers from all sending the forcePrimaryRefresh command (redundantly), I'm wondering about alternatives. We could combine making oplog invalidations kick off the refresh process immediately, and best effort informing the recipient shard of its new chunk, and get pretty solid availability that way. |
| Comment by Dianna Hohensee (Inactive) [ 14/Jul/17 ] |
|
Must be done after |