I am looking into Cloud Run Jobs, but I'm having trouble with the documentation and (rare) examples for the product.
I want to create a Cloud Run Job that runs on a Cloud Schedule. The number of tasks depends on the number of items in a table. I want to run a task for each row.
Given each task runs individually and there's no "parent" container holding the task information, the only solution that comes to mind is a limit 1 offset ${BATCH_TASK_INDEX}
query to get one row for each task - which doesn't seem very efficient. Also, with this method I wouldn't know the task count before.
I've seen there's a newer product "Batch" which has a script for the job and a container for the task, which kind of works for my use case. But I fail to understand what Cloud Run Jobs is actually good for. Maybe someone can shed some light?