pgbouncer - leverage multiple standby nodes for reads

Description

Right now the setup that we have is the following:

  1. pgBouncer (connection pooler) points to Primary node of the cluster

    1. all reads and writes go to one node

  2. we also have replicas Kubernetes Service that points to Replica nodes of the cluster, but these connections are not pooled

 

The problem here, is that users cannot leverage scaling capabilities of PostgreSQL cluster on Kubernetes in full, cause connections to replicas are not pooled. 

We need to come up with the design and implement it, that is going to provide easy failover and scalability for PostgreSQL on Kubernetes.

 

 is researching the approach that we are using on non-Kubernetes environments.

Environment

None

Smart Checklist

Activity

Show:

Details

Assignee

Reporter

Needs Review

Yes

Needs QA

Yes

Needs Doc

Yes

Priority

Smart Checklist

Created December 15, 2021 at 8:00 AM
Updated March 5, 2024 at 3:58 PM