feat(sync): resume unfinished large-file uploads

Aperta
#157 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@ffumero2003 ci sta già lavorando.

Dal 26/10/2026.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

enhancement

Context

The folder sync engine in #135 restarts an interrupted large-file upload from the beginning. Completed parts are not reused, so a later sync must upload the entire file again. Resume was deliberately deferred from #135, as noted in Jakub's review comment.

Acceptance criteria

  • R1. A later sync resumes an unfinished large-file upload from its completed, matching parts rather than uploading those parts again.
  • R2. A deterministic test interrupts a large-file sync mid-upload, reruns it, and verifies that completed parts are reused and the final object matches the local file.
  • R3. Resume rejects an incompatible unfinished upload instead of publishing incorrect content.

In scope

  • large-file uploads performed by b2/sync and their resume tests.

Out of scope

  • bidirectional sync, conflict policy changes, and resuming downloads.

Verification

Run the repository regression checks with live credentials unset:

unset B2_APPLICATION_KEY_ID B2_APPLICATION_KEY B2_ACCOUNT_ID B2_ACCOUNT_KEY
go build ./...
go vet ./...
go test -race -count=1 ./b2/sync ./b2 ./base
  • Interrupt a controlled large-file sync, rerun it, and assert completed matching parts are reused and the final bytes match the local file.
  • Include a mismatching unfinished-upload case that is rejected without publishing incorrect content; record red/green for the new behavior.
  • Expected result: the checks above succeed and the observable outcomes in Acceptance criteria are demonstrated. If a check cannot run, report Could not run because: ...; if it starts but fails, report Could not complete because: .... A skipped check is not a pass.

Links

Related: #135.

Lingua principale
Go
Stelle
66
Fork
18
Merge medio
1g 10h
PR unite (30g)
132

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Backblaze/blazer

Tutte le issue di Backblaze/blazer

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.