FeatureFuel
1

Allow configuring PostgREST pool and pooler in Supabase CLI (api.db_pool, api.use_pooler)

Source: supabase/supabase#41709 · opened by @3h4x
Problem: In local development with Supabase CLI, the PostgREST container is hardcoded to use a max pool size of 10 (PGRST_DB_POOL=10). Under integration test load, this saturates the pool and results in intermittent 502s (e.g., “Connection reset by peer” / “Invalid response from upstream”). There is currently no supported way to increase the PostgREST connection pool or route PostgREST through the built-in pooler (Supavisor) via config.toml. Current behavior: PostgREST connects directly to Postgres (docker internal host/port). Pool size is fixed at 10 (logs show “Connection Pool initialized with a maximum size of 10 connections”). db.pooler settings in config.toml don’t affect PostgREST because it bypasses the pooler. Setting PGRST_DB_POOL in .env doesn’t propagate to the CLI-managed API container. What I tried Enabled [db.pooler] with default_pool_size = 20 — no effect on PostgREST. Set PGRST_DB_POOL=50 in .env — not passed through to container. Changed external ports …

No pledges yet. Be the first to back this.

Make a pledge

Pledge your monetary support if this feature is added.

$

Comments

No comments yet.

Replying to

Add a comment

What do you think about this feature request?


Similar requests