[bug] Global axios-retry side-effect in wxccRoutes.js #4

Closed
opened 2026-07-01 16:06:32 -04:00 by jmcqueen · 1 comment
Owner

src/routes/wxccRoutes.js:10 calls axiosRetry(axios, { retries: 3, ... }) on the global axios instance, in addition to the per-instance retry applied to jiraClient. This causes any bare axios.get(...) — including the S3 download inside attachFileToJira — to double-retry with exponential backoff, which is at best wasteful and at worst causes stampedes on transient failures.

Fix:

  • Remove the global axiosRetry(axios, ...) call.
  • Keep retry only on the shared jiraClient.
  • If raw S3 downloads need retry, create a dedicated axios instance for them with its own tuned policy.
`src/routes/wxccRoutes.js:10` calls `axiosRetry(axios, { retries: 3, ... })` on the **global** axios instance, in addition to the per-instance retry applied to `jiraClient`. This causes any bare `axios.get(...)` — including the S3 download inside `attachFileToJira` — to double-retry with exponential backoff, which is at best wasteful and at worst causes stampedes on transient failures. **Fix:** - Remove the global `axiosRetry(axios, ...)` call. - Keep retry only on the shared `jiraClient`. - If raw S3 downloads need retry, create a dedicated axios instance for them with its own tuned policy.
jmcqueen added this to the v1: Jira lifecycle GA milestone 2026-07-01 16:06:32 -04:00
jmcqueen added the
bug
label 2026-07-01 16:06:32 -04:00
Author
Owner

Fixed in commit c4a0a69.

  • wxccRoutes.js no longer imports axios / axios-retry and no longer calls axiosRetry(axios, ...). That global mutation was the whole side-effect.
  • Added a private downloadClient in services/jira/client.js (own timeout, own retry policy) used by attachFileToJira and fetchAndConvertTranscript for pre-signed S3 URLs.
  • The remaining bare axios.get/axios.post calls in services/jira/assets.js (AQL, runAssetsGet) are intentional — they're one-shot diagnostic calls that should not auto-retry.

Commits on cursor/hardening-4-5-6-7:

  • c4a0a69 Fix #4
  • 312448f Fix #5
  • b8f2eab Refactor #6

Branch: cursor/hardening-4-5-6-7
Compare: init-repo-and-jira-lifecycle...hardening-4-5-6-7

Fixed in commit `c4a0a69`. - `wxccRoutes.js` no longer imports `axios` / `axios-retry` and no longer calls `axiosRetry(axios, ...)`. That global mutation was the whole side-effect. - Added a private `downloadClient` in `services/jira/client.js` (own timeout, own retry policy) used by `attachFileToJira` and `fetchAndConvertTranscript` for pre-signed S3 URLs. - The remaining bare `axios.get`/`axios.post` calls in `services/jira/assets.js` (AQL, `runAssetsGet`) are intentional — they're one-shot diagnostic calls that should not auto-retry. **Commits on `cursor/hardening-4-5-6-7`:** - `c4a0a69` Fix #4 - `312448f` Fix #5 - `b8f2eab` Refactor #6 Branch: [cursor/hardening-4-5-6-7](https://git.joesjavajoint.com/jmcqueen/wxccai/src/branch/cursor/hardening-4-5-6-7) Compare: [init-repo-and-jira-lifecycle...hardening-4-5-6-7](https://git.joesjavajoint.com/jmcqueen/wxccai/compare/cursor/init-repo-and-jira-lifecycle...cursor/hardening-4-5-6-7)
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: jmcqueen/wxccai#4
No description provided.