Trying to figure out best practice here as I am learning celery.
I want to fan out a bunch of small jobs in another job. I understand groups is a great way to get the results from a bunch of enqueued smaller jobs, but what if I don't care about results? I just want to split a big job into a bunch of smaller tasks. Is calling delay in a loop the same thing in this case?
Is it still best practice to use groups when wanting to fan out, and queue up a bunch of smaller jobs in a parent job? Below is some pseudo code as an example.
@app.task
def call_job(job_args):
groups([for small_job.s(x) for x in job_args]).delay()
@app.task
def small_job(x):
# do something
vs
@app.task
def call_job(job_args):
for x in job_args:
small_job.delay(x)
@app.task
def small_job(x):
# do something