aglinxinyuan opened a new issue, #7413:
URL: https://github.com/apache/texera/issues/7413

   ### Task Summary
   
   `onClickAbortUploadProgress` is the largest uncovered block in 
`DatasetDetailComponent` (roughly 60 lines) and the one with the most ways to 
go wrong.
   
   Aborting an in-flight upload has to survive the backend still finalizing a 
previous attempt, so the abort call is retried on 409:
   
   | Response | Behaviour |
   |---|---|
   | success | notify, report the abort |
   | 404 | already gone — report the abort, no error |
   | 409, attempt < `ABORT_RETRY_MAX_ATTEMPTS` | retry after 
`ABORT_RETRY_BACKOFF_BASE_MS * (attempt + 1)` |
   | 409 at the limit, or any other status | give up, but still report the 
abort |
   
   Alongside the retry ladder: the progress subscription is unsubscribed so a 
late event cannot resurrect the task, the concurrency slot is released via 
`onUploadComplete()` so a queued upload can start, the task moves to `aborted`, 
and `cancelExistingUpload` delegates here for an upload that is still running.
   
   Both constants are exported, so the backoff growth and the attempt bound can 
be asserted rather than hard-coded. `vi.useFakeTimers()` is needed to step the 
backoff.
   
   The existing "upload queue" describe already has the harness: a 
`multipartUpload` stub handing back a `Subject` per file, and a 
`finalizeMultipartUpload` stub to drive the responses above.
   
   ### Task Type
   
   - [ ] Refactor / Cleanup
   - [ ] DevOps / Deployment / CI
   - [x] Testing / QA
   - [ ] Documentation
   - [ ] Performance
   - [ ] Other
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to