mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-12-04 10:07:28 +01:00
0b8ea2f2e62481d89d2e9abab238327c7b8a85c0
The chunk layer fills chunkCutStats for every cut, but the /chunk/cut body dropped them (the W2 placeholder said "added when W3 fills them"). The body now carries a "stats" object that mirrors storage.ChunkCutStats field for field: barrier pause, sync, copy, candidate/uploaded/zeroed/unchanged chunks, uploaded bytes, upload and CAS time and result, total time, and the staging counters. A reflection test keeps the body in step with the layer's struct, so a new layer statistic cannot be dropped silently. This lets a caller (the CLI, a test harness) see what one cut cost without reading logs: the barrier pause against the chunks it copied, and the bytes each cut uploaded to the store. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Languages
Go
84.5%
Rust
7.9%
Shell
2.7%
templ
1.6%
Java
1%
Other
2%