Skip to main content

# python-citus-rebalancer A python command to get recommendations on commands to run to rebalance an unbalaned citus cluster.

Sometimes when your cluster grows, you can have an uneven size on nodes: for example if one customers ingests more data than other. This simple commands helps you figure out what master_move_shard commands to run on your coordinator.

## Installation ### Install with pip install

  1. Run pip install py-citus-rebalancer

### Install from source code

  1. Clone the github repository

  2. Run python setup.py develop

## Running the command

This command has different options:

  • –host: is your postgres connection string

  • –delta: is the maximum difference you expect between the node size and the idea size. For example if you have 4 nodes and 20GB of data, the idea size would be 5GB per node. The delta that you can give is for example 10% difference. It’s an integer representing the percent.

  • –file: path to the file where you want the command to be written: example /path/to/rebalance.sql. You can then run the file on your coordinator

  1. Run the command citus-rebalancer –host=postgres://user:pwd@host:5432/dbname –delta=10

  2. It will return commands to run, run them on your coordinator to rebalance the cluster.

Release files for py-citus-rebalancer 1.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py-citus-rebalancer 1.0.2
File Size Uploaded
py-citus-rebalancer-1.0.2.tar.gz 4.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for py-citus-rebalancer 1.0.2
File Interpreter ABI Platform
py_citus_rebalancer-1.0.2-py3-none-any.whl Python 3 none any Details

Total release size: 10.9 kB

Release files / py-citus-rebalancer-1.0.2.tar.gz

Download URL py-citus-rebalancer-1.0.2.tar.gz
Size 4.5 kB
Tags Source
SHA-256 checksum
How to use checksums
953c2a335222893e79b1e1e4f7b5bb3a999c4c2462d72f9a3012662a5408232d
BLAKE2b-256 checksum
How to use checksums
9fdf75e5b74c2d1cde383561b3fecb2dc57917f38778e08ba339810e0ed4e828
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.1 requests-toolbelt/0.9.1 tqdm/4.39.0 CPython/3.7.4

Release files / py_citus_rebalancer-1.0.2-py3-none-any.whl

Download URL py_citus_rebalancer-1.0.2-py3-none-any.whl
Size 6.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4bef50f088daf8400920287f2e09c054768c91bd67a46f8c3f1cbd3d0de85cce
BLAKE2b-256 checksum
How to use checksums
b592601aad97a3da8ea1119984d4668d3f95ed48dff56b17d7eb9bda0d4ddc41
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.1 requests-toolbelt/0.9.1 tqdm/4.39.0 CPython/3.7.4

Release history Release notifications | RSS feed

1.0.4

2 release files

1.0.3

2 release files

This release

1.0.2 This release

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page