Skip to content
This repository has been archived by the owner on Jun 24, 2021. It is now read-only.

scripts: add peers distribution of table regions #739

Merged
merged 2 commits into from
Apr 29, 2019
Merged

Conversation

nolouch
Copy link
Member

@nolouch nolouch commented Apr 23, 2019

the output like:

[RECORD - sbtest1.sbtest1] - Leaders Distribution:
  total leader count: 4
  store: 10, num_leaders: 1, percentage: 25.00%
  store: 8, num_leaders: 2, percentage: 50.00%
  store: 5, num_leaders: 1, percentage: 25.00%
[RECORD - sbtest1.sbtest1] - Peers Distribution:
  total peers count: 12
  store: 10, num_peers: 3, percentage: 25.00%
  store: 4, num_peers: 2, percentage: 16.67%
  store: 6, num_peers: 1, percentage: 8.33%
  store: 8, num_peers: 2, percentage: 16.67%
  store: 1, num_peers: 2, percentage: 16.67%
  store: 5, num_peers: 1, percentage: 8.33%
  store: 9, num_peers: 1, percentage: 8.33%
[INDEX - k_1] - Leaders Distribution:
  total leader count: 3
  store: 6, num_leaders: 1, percentage: 33.33%
  store: 7, num_leaders: 1, percentage: 33.33%
  store: 10, num_leaders: 1, percentage: 33.33%
[INDEX - k_1] - Peers Distribution:
  total peers count: 9
  store: 6, num_peers: 2, percentage: 22.22%
  store: 4, num_peers: 3, percentage: 33.33%
  store: 10, num_peers: 2, percentage: 22.22%
  store: 7, num_peers: 1, percentage: 11.11%
  store: 9, num_peers: 1, percentage: 11.11%

Signed-off-by: nolouch <nolouch@gmail.com>
scripts/table-regions.py Outdated Show resolved Hide resolved
@disksing
Copy link
Contributor

How about using 20.15% instead of 20.155038759689923%?

Signed-off-by: nolouch <nolouch@gmail.com>
@nolouch nolouch merged commit dabf60b into master Apr 29, 2019
@nolouch nolouch deleted the impr-table-analyze branch April 29, 2019 17:48
liubo0127 pushed a commit that referenced this pull request Apr 30, 2019
* scripts: add peers distribution of table regions

Signed-off-by: nolouch <nolouch@gmail.com>
liubo0127 pushed a commit that referenced this pull request Apr 30, 2019
* scripts: add peers distribution of table regions

Signed-off-by: nolouch <nolouch@gmail.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants