@freemo Well, I'm occassionaly experiencing deadlock situations when all queries go into idle mode. Specifically in the puma workers, there is 0 reason for any query to ever take longer than 5s to execute, on any environment. So adding a timeout there would let the problem fix itself. However, I am not sure it works with transaction pooling, because a session doesn't really exist with transaction pooling. Every query you execute, might get a different underlying connection to postgres.