Reputation: 542
When I send a task and I try to revoke:
app=Celery()
app.control.revoke(task.id)
#or
app.control.revoke(task.id, terminate=True)
I get that error:
[2019-09-05 05:27:50,110: ERROR/MainProcess] pidbox command error: NotImplementedError("<class 'celery.concurrency.gevent.TaskPool'> does not implement kill_job",)
I'm using gevent.
celery -A MyApp worker -l info -P gevent
what's wrong?
Upvotes: 3
Views: 2457
Reputation: 19787
gevent concurrency does not allow killing of the jobs. Pre-fork does allow it as it is as simple as killing the worker-process that is running the task that you want to terminate, same goes for threading.
There is an issue about this, with a proposed solution - https://github.com/celery/celery/issues/4019 - but nobody made a PR.
Upvotes: 1