Skip to content

Use bulk issue-add endpoint for adding issues to Wave Programs#1946

Open
efstajas wants to merge 1 commit into
mainfrom
bulk-add-issues-endpoint
Open

Use bulk issue-add endpoint for adding issues to Wave Programs#1946
efstajas wants to merge 1 commit into
mainfrom
bulk-add-issues-endpoint

Conversation

@efstajas

Copy link
Copy Markdown
Contributor

Frontend half of drips-network/wave#735 — requires drips-network/wave#739 to be deployed first.

Change

The "add issues to Wave Program" flow now sends one POST /wave-programs/:id/issues/bulk request per chunk of 50 issues (the server's cap), sequentially, instead of one request per issue. Each chunk is a single backend transaction with a single org-lock acquisition, so bulk adds no longer pile up advisory-lock waiters server-side (the cause of today's statement-timeout 503 storms; #1945 was the stopgap).

  • New addIssuesToWaveProgram util + response schemas in $lib/utils/wave.
  • Per-issue failures come from the bulk response's results and feed the same partial-failure error screen as before; whole-chunk failures (network/5xx) mark just that chunk's issues as failed while other chunks proceed.
  • Successful adds are refreshed and wave:issues invalidated exactly as before, including on partial failure.
  • mapWithConcurrency from throttle bulk wave issue adds #1945 is left in place (generic, tested util) but the add flow no longer uses it.

Testing

  • npm run check, eslint, prettier clean; unit tests pass (106).
  • Flow behavior on partial failure (some issues closed/over budget) unchanged: added issues refresh, failed ones listed per-issue on the error screen.

Deploy order

Backend drips-network/wave#739 must ship first — this flow 404s against an API without the bulk route.

Copilot AI review requested due to automatic review settings July 23, 2026 20:21

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants