Mixa
postgres connection_limit
Hello. I have PostgreSQL database and user account with max connection = 15. When i try to work actively with my self hosted twenty I get errors in logs like this:
query failed: SQL_QUERY_HERE
error: error: odyssey: c4c33593663c3: too many active clients for user (pool_size for user username.twenty-db reached 15)
When I investigate SELECT ... pg_stat_activity where usename = 'username' i see what all my 15 connection was used. I tried to set connection_limit=1 in PG_DATABASE_URL as described in https://twenty.com/developers/section/self-hosting/self-hosting-var , but it doesn't help.
Is there a way to limit the number of connections to database that can be established by twenty-server?
3 replies