This document describes the current stable version of Celery (4.0). For development docs, go here.

celery.worker.components

Worker-level Bootsteps.

class celery.worker.components.Timer(parent, **kwargs)[source]

Timer bootstep.

create(w)[source]
name = u'celery.worker.components.Timer'
on_timer_error(exc)[source]
on_timer_tick(delay)[source]
class celery.worker.components.Hub(w, **kwargs)[source]

Worker starts the event loop.

create(w)[source]
include_if(w)[source]
name = u'celery.worker.components.Hub'
requires = (step:celery.worker.components.Timer{()},)
start(w)[source]
stop(w)[source]
terminate(w)[source]
class celery.worker.components.Pool(w, autoscale=None, **kwargs)[source]

Bootstep managing the worker pool.

Describes how to initialize the worker pool, and starts and stops the pool during worker start-up/shutdown.

Adds attributes:

  • autoscale
  • pool
  • max_concurrency
  • min_concurrency
close(w)[source]
create(w)[source]
info(w)[source]
name = u'celery.worker.components.Pool'
register_with_event_loop(w, hub)[source]
requires = (step:celery.worker.components.Hub{(step:celery.worker.components.Timer{()},)},)
terminate(w)[source]
class celery.worker.components.Beat(w, beat=False, **kwargs)[source]

Step used to embed a beat process.

Enabled when the beat argument is set.

conditional = True
create(w)[source]
label = u'Beat'
name = u'celery.worker.components.Beat'
class celery.worker.components.StateDB(w, **kwargs)[source]

Bootstep that sets up between-restart state database file.

create(w)[source]
name = u'celery.worker.components.StateDB'
class celery.worker.components.Consumer(parent, **kwargs)[source]

Bootstep starting the Consumer blueprint.

create(w)[source]
last = True
name = u'celery.worker.components.Consumer'