From fd48f442dbcb656f7a46cf1d9e746486131af307 Mon Sep 17 00:00:00 2001 From: nuwang <2070605+nuwang@users.noreply.github.com> Date: Thu, 14 Sep 2023 00:58:15 +0530 Subject: [PATCH] Add max requests to gunicorn --- galaxy/templates/deployment-web.yaml | 2 +- galaxy/values.yaml | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/galaxy/templates/deployment-web.yaml b/galaxy/templates/deployment-web.yaml index 0a1f8c49..9e665a98 100644 --- a/galaxy/templates/deployment-web.yaml +++ b/galaxy/templates/deployment-web.yaml @@ -69,7 +69,7 @@ spec: '{{- if .Values.extraInitCommands -}} {{- tpl .Values.extraInitCommands $ | nindent 13 }}; {{- end -}} - /galaxy/server/.venv/bin/gunicorn "galaxy.webapps.galaxy.fast_factory:factory()" --timeout {{ .Values.webHandlers.gunicorn.timeout | default 300 }} --pythonpath /galaxy/server/lib -k galaxy.webapps.galaxy.workers.Worker -b 0.0.0.0:8080 --workers={{ .Values.webHandlers.gunicorn.workers | default 1 }} --config python:galaxy.web_stack.gunicorn_config --preload {{ .Values.webHandlers.gunicorn.extraArgs | default "" }}'] + /galaxy/server/.venv/bin/gunicorn "galaxy.webapps.galaxy.fast_factory:factory()" --timeout {{ .Values.webHandlers.gunicorn.timeout | default 300 }} --pythonpath /galaxy/server/lib -k galaxy.webapps.galaxy.workers.Worker -b 0.0.0.0:8080 --workers={{ .Values.webHandlers.gunicorn.workers | default 1 }} --config python:galaxy.web_stack.gunicorn_config --preload {{ .Values.webHandlers.gunicorn.extraArgs | default "" }} --max-requests {{ .Values.webHandlers.gunicorn.maxRequests | default "50000" }} --max-requests-jitter {{ .Values.webHandlers.gunicorn.maxRequestsJitter | default "10000" }}'] {{- if .Values.webHandlers.startupProbe.enabled }} startupProbe: httpGet: diff --git a/galaxy/values.yaml b/galaxy/values.yaml index a4f66343..29167d1d 100644 --- a/galaxy/values.yaml +++ b/galaxy/values.yaml @@ -79,6 +79,8 @@ webHandlers: gunicorn: timeout: 300 workers: 1 + maxRequests: 50000 + maxRequestsJitter: 10000 extraArgs: "" jobHandlers: