Messaging - celery.messaging

Sending and Receiving Messages

class celery.messaging.BroadcastConsumer(*args, **kwargs)

Consume broadcast commands

class celery.messaging.BroadcastPublisher(connection, exchange=None, routing_key=None, **kwargs)

Publish broadcast commands

ReplyTo

alias of ControlReplyConsumer

send(type, arguments, destination=None, reply_ticket=None)

Send broadcast command.

class celery.messaging.ConsumerSet(connection, from_dict=None, consumers=None, callbacks=None, **options)

ConsumerSet with an optional decode error callback.

For more information see carrot.messaging.ConsumerSet.

on_decode_error

Callback called if a message had decoding errors. The callback is called with the signature:

callback(message, exception)
class celery.messaging.ControlReplyConsumer(connection, ticket, **kwargs)
collect(limit=None, timeout=1)
class celery.messaging.ControlReplyPublisher(connection, exchange=None, routing_key=None, **kwargs)
class celery.messaging.EventConsumer(connection, queue=None, exchange=None, routing_key=None, **kwargs)

Consume events

class celery.messaging.EventPublisher(connection, exchange=None, routing_key=None, **kwargs)

Publish events

class celery.messaging.TaskConsumer(connection, queue=None, exchange=None, routing_key=None, **kwargs)

Consume tasks

class celery.messaging.TaskPublisher(*args, **kwargs)

Publish tasks.

declare()
delay_task(task_name, task_args=None, task_kwargs=None, countdown=None, eta=None, task_id=None, taskset_id=None, **kwargs)

Delay task for execution by the celery nodes.

celery.messaging.establish_connection(hostname=None, userid=None, password=None, virtual_host=None, port=None, ssl=None, insist=None, connect_timeout=None, backend_cls=None)

Establish a connection to the message broker.

celery.messaging.extract_msg_options(d)
celery.messaging.get_consumer_set(connection, queues=None, **options)

Get the carrot.messaging.ConsumerSet` for a queue configuration.

Defaults to the queues in CELERY_QUEUES.

celery.messaging.reply(*args, **kwargs)
celery.messaging.with_connection(fun)

Decorator for providing default message broker connection for functions supporting the connection and connect_timeout keyword arguments.

Previous topic

Task States - celery.states

Next topic

Contrib: Abortable tasks - celery.contrib.abortable

This Page