Skip to content

Commit 70dcda9

Browse files
authored
fix(qs-batches): retry running transactions that require db locks (#736)
* fix(qs-batches): retry running transactions that require db locks * docs: add CHANGELOG
1 parent bb286f0 commit 70dcda9

4 files changed

Lines changed: 6 additions & 3 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# api
22

3+
## 9x.0.2 - 07 February 2024
4+
- Retry DB transactions that lock
5+
36
## 9x.0.1 - 23 January 2024
47
- Fix typo when setting visibility on raw assets
58

app/Http/Controllers/Backend/QsController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public function getBatches(Request $request): \Illuminate\Http\Response
2929
$oldestBatch->update(['pending_since' => Carbon::now()]);
3030
$oldestBatch->load(['wiki', 'wiki.wikiQueryserviceNamespace']);
3131
return response([$oldestBatch]);
32-
});
32+
}, 3);
3333

3434
}
3535

app/Jobs/CreateQueryserviceBatchesJob.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public function handle(): void
4747
}
4848

4949
QsCheckpoint::set($latestEventId);
50-
});
50+
}, 3);
5151
}
5252

5353
private function getNewEntities(int $latestCheckpoint): array

app/Jobs/RequeuePendingQsBatchesJob.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ private function markBatchesFailed(): array
4444
'pending_since' => null,
4545
]);
4646
return $failedBatches;
47-
});
47+
}, 3);
4848
}
4949

5050
private function requeueStalledBatches(): void

0 commit comments

Comments
 (0)