Skip to content

Instantly share code, notes, and snippets.

@paulozullu
Last active March 5, 2018 12:31
Show Gist options
  • Save paulozullu/c0f93aab486d0d23c7edffa677e92421 to your computer and use it in GitHub Desktop.
Save paulozullu/c0f93aab486d0d23c7edffa677e92421 to your computer and use it in GitHub Desktop.
Comandos para debugar o celery

Iniciar os workers

celery -A ecminer worker -l info -E

Executar tasks agendadas

celery -A ecminer beat -l info

Remover todas as tasks

celery -A ecminer purge

Iniciar workers para determinada queue

celery -A ecminer worker -l info -E --concurrency=1 -Q queue_name

Remover tasks de determinada queue

celery -A ecminer amqp queue.purge queue_name

Verificar o q estiver agendado

celery -A listener.celery inspect scheduled --broker=redis://localhost:6379/0

Monitorar com Flower

You can use pip to install Flower:

$ pip install flower

Running the flower command will start a web-server that you can visit:

$ celery -A proj flower

The default port is http://localhost:5555, but you can change this using the --port argument:

$ celery -A proj flower --port=5555
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment