mirror of
https://github.com/langflow-ai/langflow.git
synced 2026-07-26 01:11:09 +08:00
perf: enable Gunicorn preload_app to reduce memory per worker (#12364)
* fix: enable preload_app option in LangflowApplication configuration * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes * Make flag configurable * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * [autofix.ci] apply automated fixes (attempt 3/3) --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@logspace.ai> Co-authored-by: ogabrielluiz <gabriel@langflow.org> Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com> Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>
This commit is contained in:
@ -413,6 +413,7 @@ def run(
|
||||
"certfile": ssl_cert_file_path,
|
||||
"keyfile": ssl_key_file_path,
|
||||
"log_level": log_level.lower() if log_level is not None else "info",
|
||||
"preload_app": os.environ.get("LANGFLOW_GUNICORN_PRELOAD", "false").lower() == "true",
|
||||
}
|
||||
server = LangflowApplication(app, options)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user