fix: Avoid applying pinning optimization on RQ (#28896)
We only need it for gunicorn workers.
This commit is contained in:
parent
aa5455e281
commit
8db2e1e2a6
1 changed files with 3 additions and 0 deletions
|
|
@ -97,6 +97,9 @@ def optimize_for_gil_contention():
|
|||
if not os.environ.get("FRAPPE_PERF_PIN_WORKERS"):
|
||||
return
|
||||
|
||||
if "gunicorn" not in str(sys.argv[0]):
|
||||
return
|
||||
|
||||
if os.environ.get("FRAPPE_PERF_PIN_WORKERS_DETERMINISTIC"):
|
||||
# Ensure same pinning order every time.
|
||||
# This is only useful for benchmarking, DO NOT enable this in production.
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue