-
Type:
Task
-
Resolution: Done
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Sharding EMEA 2022-11-28
-
None
-
3
-
None
-
None
-
None
-
None
-
None
-
None
Milestone 2 of the "no more auto-splitter" project will require the implementation of an automatic procedure to merge contiguous chunks belonging to the same shard [when possible].
This proof of concept is aimed to prematurely identify potential roadblocks for the project by implementing the most basic merger respecting the following requirements:
- Two or more chunks can be auto-merged only when:
- They belong to the same shard
- Their bounds are contiguous
- The history array of each chunk to merge:
- Is empty
OR - The first entry has a validAfter value so that (currentTime - minSnapshotHistoryWindowInSeconds > validAfter)
- Is empty
- Auto-merging happens when the balancer is active as part of balancing rounds:
- Every N seconds (either auto-merging or migrations can happen during a round)
- If a merge was issued during the last balancing round, then keep on merging. Else, start issuing migrations again.
- Auto-merging is enabled by default and can be disabled via a field in config.settings. Similar to the autosplit field.