psycopg: SSL SYSCALL error: EOF detected

Hello, English is not my native language so sorry for the mistakes In general, the problem is as follows: When I deploy the application, after a few hours it shuts down the connection with postgres and writes it in the logs psycopg library, how can this be fixed?
No description
7 Replies
Percy
Percy11mo ago
Project ID: 1a4094a5-8dec-4ed3-a791-e7ddfc8cbd08
Компостер
КомпостерOP11mo ago
1a4094a5-8dec-4ed3-a791-e7ddfc8cbd08
Brody
Brody11mo ago
this can usually happen when you are keeping connections open, postgres closes the connection but the client doesn't know the connection was closed
Компостер
КомпостерOP11mo ago
And how to keep them open? Or do I need to initialize a new connection every few hours?
Brody
Brody11mo ago
unfortunately I don't have an exact answer to that, it's something you would have to reference the client libraries documentation for
Компостер
КомпостерOP11mo ago
When I hadn't upgraded to version 2 yet, it always worked fine. Maybe that's the point? Or is it possible to do something on the server so that it does not reset the connection?
Brody
Brody11mo ago
no sorry this isnt an issue with postgres or railway, its how your database client is handling closed connections, or should i say, not handling closed connections
Want results from more Discord servers?
Add your server