Closed jonathan-d-zhang closed 3 months ago
Currently, when we get jobs, we make 2 queries to fetch records, then update their status in the database. We aren't doing this atomically, which is :-1:.
We should use a CTE to update and return the rows we updated.
Currently, when we get jobs, we make 2 queries to fetch records, then update their status in the database. We aren't doing this atomically, which is :-1:.
We should use a CTE to update and return the rows we updated.