Most scaling bottlenecks attributed to PostgreSQL are actually configuration and indexing inefficiencies. In this technical deep dive, we break down the exact parameters and query optimization strategies Pageup uses to extract maximum performance from PostgreSQL.
1. Memory Configuration: Beyond Default Settings
The default postgresql.conf values are notoriously conservative:
shared_buffers: Set to 25% to 40% of total system RAM for dedicated database instances.work_mem: Allocate per-operation memory (e.g. 32MB - 64MB) to prevent disk-based sorting and hashing.effective_cache_size: Set to 75% of available RAM to give the query planner an accurate estimate of OS filesystem cache.
2. Connection Pooling with PgBouncer
Direct connections to PostgreSQL allocate heavy process memory (5MB–10MB per connection). Deploying PgBouncer in transaction pooling mode allows thousands of concurrent microservices to multiplex over 100 dedicated backend connections with zero latency penalty.


