|
|
@ -112,8 +112,13 @@ print len(q)
|
|
|
|
queued_job_ids = q.job_ids # Gets a list of job IDs from the queue
|
|
|
|
queued_job_ids = q.job_ids # Gets a list of job IDs from the queue
|
|
|
|
queued_jobs = q.jobs # Gets a list of enqueued job instances
|
|
|
|
queued_jobs = q.jobs # Gets a list of enqueued job instances
|
|
|
|
job = q.fetch_job('my_id') # Returns job having ID "my_id"
|
|
|
|
job = q.fetch_job('my_id') # Returns job having ID "my_id"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Deleting the queue
|
|
|
|
|
|
|
|
q.delete(delete_jobs=True) # Passing in `True` will remove all jobs in the queue
|
|
|
|
|
|
|
|
# queue is unusable now unless re-instantiated
|
|
|
|
{% endhighlight %}
|
|
|
|
{% endhighlight %}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### On the Design
|
|
|
|
### On the Design
|
|
|
|
|
|
|
|
|
|
|
|
With RQ, you don't have to set up any queues upfront, and you don't have to
|
|
|
|
With RQ, you don't have to set up any queues upfront, and you don't have to
|
|
|
|