Skip to content

Add a virtual node to vdc hashmap for consistent hashing #4

Open
@marrotte

Description

@marrotte

Currently, the geoppinning algorithm is fixed on the number of vdc, hence mod #vdc. This makes scaling harder and harder as the number of vdc increase. By implementing consistent hash, hence an intermediary hashmap, mapping virtual nodes to vdc, the impact from scaling can be minimized, much more manageable and provide much more flexibility. For example, for a 3-site vdc we can start with 4096 vnodes indexed uniformly with vdc numbers 0-2. The geopinning algorithm would fix it's mod operation on 4096 vs 3. As we scale up and add more vdc, we simply adjust our vnode to vdc hashmap as desired -- that is, most likely preserving uniformity and minimizing data migration, but not necessarily. This can even be made backward compatible with existing geopin code/deployments by configuring the hashmap appropriately, e.g. {0-4095}%4096 to {0-4095}%3.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions