Consumer
Bootstep starting the Consumer blueprint.
Attributes
| Attribute | Type | Description |
|---|---|---|
| last | bool = True | A boolean flag indicating that this bootstep must be executed last in the blueprint sequence. |
Constructor
Signature
def Consumer()
Methods
create()
@classmethod
def create(
w: [Worker](../../events/state/worker.md?sid=celery_events_state_worker)
) - > celery.worker.consumer.Consumer
Instantiates and initializes the consumer instance for the worker, calculating the initial prefetch count based on concurrency settings.
Parameters
| Name | Type | Description |
|---|---|---|
| w | [Worker](../../events/state/worker.md?sid=celery_events_state_worker) | The worker instance providing configuration, pool, timer, and application context for the consumer. |
Returns
| Type | Description |
|---|---|
celery.worker.consumer.Consumer | The newly created consumer instance attached to the worker. |