PGBouncer - Load balancing options

From: Ravi Varma Addala <advarma(at)microsoft(dot)com>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: PGBouncer - Load balancing options
Date: 2024-10-10 10:02:15
Message-ID: DU4PR83MB067824D472F35F55C12F8444AD782@DU4PR83MB0678.EURPRD83.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello Team,
I wanted to reach out to provide some insight into a request from my customer regarding their multiple PostgreSQL Flex instances with PGbouncer. Currently, they are utilizing an Azure Load Balancer which distributes connections using the Round-robin mechanism. However, they are now seeking a solution that allows for load balancing based on the number of connections, meaning the Load Balancer should route requests to the instance with the least number of connections.
Unfortunately, Azure Standard Load Balancer does not support this capability. However, Application Gateway does offer this functionality - Microsoft.Network/applicationGateways - Bicep, ARM template & Terraform AzAPI reference | Microsoft Learn<https://learn.microsoft.com/en-us/azure/templates/microsoft.network/applicationgateways?pivots=deployment-language-bicep#applicationgatewayloaddistributionpolicypropertiesfo>

ASK:

1. Has anyone implemented this kind of approach and is it possible?
2. Can we do health probe with PostgreSQL to get no of connections metric?

1.
Kind Regards,
Ravi Varma Addala
Cloud Solution Architect
ravivarma(dot)addala(at)microsoft(dot)com<mailto:ravivarma(dot)addala(at)microsoft(dot)com>

[Microsoft]

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dominique Devienne 2024-10-10 12:35:17 Tablespace ACLs
Previous Message Thürmann 2024-10-10 09:54:28 Connection between PostgreSQL and SAP HANA database