Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shuffle the segments when rebalancing the table to avoid creating hotspot servers #5197

Merged
merged 1 commit into from
Mar 31, 2020

Commits on Mar 30, 2020

  1. Shuffle the segments when rebalancing the table to avoid creating hot…

    …spot servers
    
    When new servers are added to an existing replica-group based table
    and rebalance is triggered, current behavior will assign segments
    in alphabetical order, which might move only the new segments to
    the new added servers. Because queries tend to query the most recent
    segments, this behavior might cause new added servers to become the
    hotspot servers.
    To address this issue, we shuffle the segments so that old and new
    segments can be balanced assigned.
    We use the hash of the table name as the random seed to shuffle the
    segments so that the result is deterministic.
    
    It is a little bit tricky to write a test case for this. Since the
    change is straight-forward and the existing tests already have
    pretty good coverage, after manually verified the expected behavior,
    no new test is added.
    Jackie-Jiang committed Mar 30, 2020
    Configuration menu
    Copy the full SHA
    ceb0eb4 View commit details
    Browse the repository at this point in the history