Configure a minimum connection pool size
Is it possible to configure the postgres client to maintain a minimum connection pool size?
Creating connections is an expensive process, I'm looking to ensure a minimum baseline of connections to mitigate latency as the pool warms up to it's max
I see, so you'd like to have let's say max: 20, but let them close with idle_timeout, except for a specific min number that should stay open ready to take queries. That's a neat idea! Would it be fine simply to have a min option which would set the amount of connections not being targeted by idle_timeout, and also being opened on first query by default?
Yes exactly @porsager 🙂
This is something I've experienced in a few database drivers, mostly in the Java ecosystem. Not 100% sure how they are typically implemented but the behaviour you describe sounds quite good