DjangoPostgreSQL

Django CONN_MAX_AGE interferes with PgBouncer connection pooling

warning
configurationUpdated Mar 15, 2026(via Exa)
How to detect:

Django's persistent connection feature (CONN_MAX_AGE > 0) conflicts with PgBouncer's connection pooling, preventing effective connection reuse and pool management.

Recommended action:

Set CONN_MAX_AGE = 0 in Django DATABASES configuration to disable persistent connections and ensure PgBouncer manages all connection pooling.