mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2026-06-24 02:58:14 +03:00
Zero-length blocks indicate file corruption. Valid blocks should always
have a non-zero length. Previously, PR
https://github.com/VictoriaMetrics/VictoriaMetrics/pull/6241 worked
around this at the client level by [silently skipping such
blocks](b1dea965aa/app/vmagent/remotewrite/client.go (L314)).
Move the check into readBlock, consistent with how other corrupted
headers are handled there, and remove the now-redundant empty-block
guards from the client.
Follow-up on discussion
https://github.com/VictoriaMetrics/VictoriaMetrics/pull/10932#discussion_r3264924234