Add configurable retry logic to request queue:

- Introduce retry settings for specific HTTP status codes with exponential backoff and jitter.
- Refactor `requestQueue` to support method-based concurrency limits and retry configuration.
- Update `RequestQueueProgress` to respect minimum batch size for progress visibility.
- Add unit tests for retry logic, progress visibility, and updated queue behavior.
- Centralize request queue configuration in `REQUEST_QUEUE_CONFIG`.
This commit is contained in:
Jeppe Bundgaard
2026-03-19 14:15:12 +01:00
parent 73b838cf28
commit 861e263dfa
7 changed files with 250 additions and 45 deletions
+6 -1
View File
@@ -41,7 +41,12 @@ describe('authenticatedRequest', () => {
beforeEach(() => {
axiosMock.mockReset();
__resetRequestQueueForTests();
__configureRequestQueueForTests({ maxConcurrentGet: 1, maxConcurrentOther: 1, spacingMs: 0 });
__configureRequestQueueForTests({
maxConcurrentGet: 1,
maxConcurrentOther: 1,
spacingMs: 0,
retryByStatusCode: {}
});
localStorage.clear();
localStorage.setItem('token', 'token');
});