Timeout
Hi what's the timeout of postgres container on railway? Couldn't find that setting
12 Replies
Project ID:
N/A
do you mean connection timeout?
Yes
that would be a configuration with your postgres client
sometimes its a query parameter on the url
?connect_timeout=10
(for prisma)I am using sqlalchemy, and it seems like old connections are not recycled. I am not setting connection timeout for the database so I assume it just uses default, but I am also not setting time out on the sqlalchemy pool as after some time new sessions are impossible.
I think this is out of scope of railway, but just wanted to make sure
I mean set the pool minimum to zero, or set an equivalent setting to zero, so that unused connections can be cleaned up
nah this question is not out of scope
There doesn't seem to be pool minimum on sqlalchemy
there has to be something similar
What's pool minimum according to you?
There is pool_size, max_overflow, pool_recycle, pool_timeout
max_overflow defaults to 10, pool_size to 5, timeout seems to default to 30, this is for the queue pool
not too sure, I'm just trying to set you in the right direction
I mean when you said
set the pool minimum to zero
what did you mean exactly?I clarified