0
: worker1에종료 셀러리 노동자 예를 들어
셀러리는 worker1에 0 배포 -n
@app.task()
def f(num):
if num == 0:
# shutdown this worker
# celery will not distribute any tasks to this worker
else:
return num
셀러리 -A 작업 노동자 --loglevel = 정보는 worker1에 살해됩니다. 다큐먼트에서 , The broadcast() function
>>> broadcast("shutdown") # shutdown all workers
>>> broadcast("shutdown, destination="worker1.example.com")
하지만 잘못, 나는 그것도 작동하지 않습니다
>>> broadcast("shutdown", destination=["worker1"])
로 변경.
그래서이 기능을 어떻게 달성할까요?
음이 방송에서 같은과가 누락 된 셀러리 문서를 찾습니다 견적 – user2097159
@ user2097159 그래,하지만 견적을 추가 할 때도 작동하지 않았다. – kthh7