Files
seaweedfs/weed/operation
Chris Lu 0a5c22b57e chore(upload): log offset/bytes-read context on chunk ReadFrom errors (#9169)
chore(upload): add offset/bytes-read context to chunk ReadFrom errors

Wrap io.ErrUnexpectedEOF (and siblings) from bytesBuffer.ReadFrom so
the log shows "read chunk at offset N (got M bytes): ..." instead of
a bare "unexpected EOF". The context distinguishes a client disconnect
before any data arrived (offset=0, got=0) from a mid-stream truncation
(offset>0, got<chunkSize) — diagnosing #9149 in the wild.

Verified at this stage that expectedDataSize is already threaded
correctly from upload_chunked.go (actual ReadFrom bytes) through
s3api assignFunc → filer AssignVolume → master PickForWrite.
No behavioral change to what the master receives.
2026-04-20 21:26:34 -07:00
..
2019-02-09 21:56:32 -08:00