I created a Patroni & Citus cluster with docker compose using https://github.com/zalando/patroni.
Ideally I would like to create 3 Patroni clusters within Citus. 2 Coordinators for HA, 2 worker clusters for querying. CItus nodes would have 3 nodes. 1 leader coordiantor for holding sharding metadata and 2 worker leader nodes for storing shards.
I created such cluster mentioned above, but the result is not quite as expected. Each instance of the cluster has same amount of data. So if I have 6 instances and 1tb of data then i'd have 6tb of data. I imagined that Patroni would replicate coordinator's data to standby coordinator, worker clusters to their respective replicas.
How do I achieve such setup without replicating all of the data to all of the instances?
Patroni uses a
groupabstraction to represent Citus nodes. Group0is always the Coordinator cluster.To set up the replication with patroni as desired, use different groups