mirror of
https://github.com/prometheus/prometheus.git
synced 2024-12-24 21:24:05 -08:00
48efdf8b81
* refactor NewSegmentsRangeReader to take multi WAL ranges In case of an error when checkpointing the WAL the error doesn't show the exact WAL index that is corrupter. this is because it uses MultiReader to read multiply WAL files. This refactoring allows the NewSegmentsRangeReader to take more than a single WAL range and it reads all of the ranges by iterating each one. this changes the logs from create checkpoint: read segments: corruption after 4841144384 bytes:... to create checkpoint: read segments: corruption in segment data/wal/00017351 at 123142208: ... Signed-off-by: Krasi Georgiev <kgeorgie@redhat.com>
327 B
327 B
master / unreleased
LastCheckpoint
used to return just the segment name and now it returns the full relative path.NewSegmentsRangeReader
can now read over miltiple wal ranges by using the newSegmentRange
struct.CorruptionErr
now also exposes the SegmentDir
which is added when displaying any errors.