Now that we have pretty decisively decided that we are not going to have multiple databases in CME, we can potentially consider further improving the work done in #9356 by having a dictionary per slot. Since we have to compute the slot before executing a command, and commands bound to single slots, we should already know which one of the dictionaries a command operates on before executing it.
This work enables us to remove the linked list structure that overlays the current dictionary, since we will have a slot->key mapping, which is required for slot migration.
Some implementation notes:
- SCAN becomes more complex, as we need to embed which of the dictionaries we are located in. We should be able to handle this.
- The memory overhead should be better amortized, as each individual dict would rehash independently. In the degenerate case of owning 1 slot, this doesn't change that much though.
Documented from the idea outlined here: #9356 (comment).