]> git.ipfire.org Git - pbs.git/commit
database: Don't keep so many connections open and idle
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 18 Aug 2023 09:51:10 +0000 (09:51 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 18 Aug 2023 09:51:10 +0000 (09:51 +0000)
commitc5167e8c03b5a2e5e08c7e2192e976d4ad55644b
tree4fc2c23445b5b86d36d43bdd779b7af48a416fd3
parent363a5a1240fc12b5356564bf4a1b35127061a28a
database: Don't keep so many connections open and idle

Since we usually peak briefly, we will fork a lot of PostgreSQL
processes that we will never need again. In order to avoid wasting too
much memory, we close those connections quicker, but at least 8 open so
that new tasks will quickly be able to acquire a database connection.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/buildservice/database.py