Merge branch 'persistant-db-connection' into 'develop'

Keep persistent connections to the database instead of recreating a new one for each request

See merge request funkwhale/funkwhale!727
This commit is contained in:
Eliot Berriot 2019-04-19 14:33:25 +02:00
commit 0bb487aa7d
2 changed files with 2 additions and 0 deletions

View File

@ -220,6 +220,7 @@ DATABASES = {
"default": env.db("DATABASE_URL")
}
DATABASES["default"]["ATOMIC_REQUESTS"] = True
DATABASES["default"]["CONN_MAX_AGE"] = env("DB_CONN_MAX_AGE", default=60 * 60)
MIGRATION_MODULES = {
# see https://github.com/jazzband/django-oauth-toolkit/issues/634

View File

@ -0,0 +1 @@
Keep persistent connections to the database instead of recreating a new one for each request