MCPcopy
hub / github.com/celery/celery / reset_rate_limits

Method reset_rate_limits

celery/worker/consumer/consumer.py:264–267  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

262 return TokenBucket(limit, capacity=1) if limit else None
263
264 def reset_rate_limits(self):
265 self.task_buckets.update(
266 (n, self.bucket_for_task(t)) for n, t in self.app.tasks.items()
267 )
268
269 def _update_prefetch_count(self, index=0):
270 """Update prefetch count after pool/shrink grow operations.

Callers 3

__init__Method · 0.95
rate_limitFunction · 0.45
reloadMethod · 0.45

Calls 3

bucket_for_taskMethod · 0.95
updateMethod · 0.45
itemsMethod · 0.45

Tested by

no test coverage detected