<p>How to get quantity of tasks in Celery and Redis from the default queue.</p>
</br>
<code>
import redis
from django.conf import settings
queue_name = "celery"
client = redis.Redis.from_url(settings.REDIS_URL)
length = client.llen(queue_name)
</code>
By clicking “Accept all”, you agree to the storing of cookies on your device to enhance site navigation, analyze site usage and assist in our marketing efforts. Check our privacy policies.