Reduce gunicorn graceful_timeout to speed up app teardown

The app goes through the usual teardown process quite fast on it's own, so keeping the graceful timeout config high only arbitrarily slows things down.
This is especially releavnt in dev mode, since app reloads should feel snappy when changes are made
This commit is contained in:
Antti Kettunen 2026-04-18 13:43:10 +03:00
parent 832bb07787
commit bbd736e915
2 changed files with 6 additions and 0 deletions

View file

@ -8,6 +8,9 @@ threads = 8
# Keep requests from hanging forever on slow external services.
timeout = 120
# Keep shutdowns under Docker's stop window so container restarts stay graceful.
graceful_timeout = 8
# Logging goes to stdout/stderr so Docker can collect it.
accesslog = "-"
errorlog = "-"

View file

@ -9,6 +9,9 @@ reload = True
# Keep requests from hanging forever on slow external services.
timeout = 120
# Don't let local reloads wait too long for shutdown.
graceful_timeout = 1
# Logging goes to stdout/stderr so the shell launcher can collect it.
accesslog = "-"
errorlog = "-"