Selaa lähdekoodia

feat(graph_engine): yield control to other threads before node run. (#17689)

Signed-off-by: -LAN- <laipz8200@outlook.com>
tags/1.2.0
-LAN- 6 kuukautta sitten
vanhempi
commit
ec29bcf013
No account linked to committer's email address
1 muutettua tiedostoa jossa 2 lisäystä ja 0 poistoa
  1. 2
    0
      api/core/workflow/graph_engine/graph_engine.py

+ 2
- 0
api/core/workflow/graph_engine/graph_engine.py Näytä tiedosto

@@ -641,6 +641,8 @@ class GraphEngine:
try:
# run node
retry_start_at = datetime.now(UTC).replace(tzinfo=None)
# yield control to other threads
time.sleep(0.001)
generator = node_instance.run()
for item in generator:
if isinstance(item, GraphEngineEvent):

Loading…
Peruuta
Tallenna