Skip to content

fix(upload): serialize concurrent stream writes - #208

Merged
athNdev merged 1 commit into
mainfrom
fix/reject-invalid-archive-paths
Oct 20, 2026
Merged

athNdev merged 1 commit into
mainfrom
fix/reject-invalid-archive-paths

Conversation

@athNdev

@athNdev athNdev commented Oct 20, 2026

Copy link
Copy Markdown
Owner

Scope\nSerialize concurrent WriteStream calls per upload session. The previous implementation allowed two requests to race on shared file writes, progress accounting, and completion-time close, causing corrupted uploads or errors under concurrent resume requests.\n\n## Validation\n- go test ./pkg/upload -run TestSession_WriteStreamSerializesConcurrentRequests -count=1\n- go vet ./pkg/upload\n\nFocused regression test uses a blocked reader to prove a second stream cannot run until the first completes.

Concurrent streaming requests shared one file and progress counter without synchronization, allowing overlapping writes and close races.

Co-authored-by: Copilot <[email protected]>
@athNdev
athNdev merged commit d261281 into main Oct 20, 2026
8 checks passed
@athNdev
athNdev deleted the fix/reject-invalid-archive-paths branch October 20, 2026 13:25
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.

1 participant