MCPcopy
hub / github.com/celery/celery / include_if

Method include_if

celery/worker/consumer/delayed_delivery.py:54–63  ·  view source on GitHub ↗

Determine if this bootstep should be included. Args: c: The Celery consumer instance Returns: bool: True if quorum queues are detected, False otherwise

(self, c: Consumer)

Source from the content-addressed store, hash-verified

52 requires = (Tasks,)
53
54 def include_if(self, c: Consumer) -> bool:
55 """Determine if this bootstep should be included.
56
57 Args:
58 c: The Celery consumer instance
59
60 Returns:
61 bool: True if quorum queues are detected, False otherwise
62 """
63 return detect_quorum_queues(c.app, c.app.connection_for_write().transport.driver_type)[0]
64
65 def start(self, c: Consumer) -> None:
66 """Initialize delayed delivery for all broker URLs.

Calls 2

detect_quorum_queuesFunction · 0.90
connection_for_writeMethod · 0.45