Load balancing of write queries among health-checked nodes

From: me+postgres(at)kotovalexarian(dot)com
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Load balancing of write queries among health-checked nodes
Date: 2024-10-08 03:03:57
Message-ID: E72E2BA7-85BF-4446-B9D8-08F462CB392D@kotovalexarian.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello. I have a PostgreSQL high availability cluster with Pgpool-II, but I don't use the virtual IP feature so my clients don't know which node to send queries to. DNS round-robin is not a solution because it can't distinguish between healthy and dead nodes.

I thought about having a Pgpool-II instance on each client (client Pgpool-II -> cluster Pgpool-II -> PostgreSQL), but AFAIK it can't distribute write queries. I also know that libpq may have multiple nodes to connect, but I need an advanced health check because a node may have connectivity but be separated from the whole cluster so it must be considered dead.

Is there any solution?

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Muhammad Usman Khan 2024-10-08 03:24:48 Re: backup
Previous Message Thomas Munro 2024-10-07 22:01:26 Re: Getting PSQL in Windows to support TAB/Autocomplete via modified readline...