diff --git a/cmd/promtool/rules.go b/cmd/promtool/rules.go index d8d6bb83e..5a1864484 100644 --- a/cmd/promtool/rules.go +++ b/cmd/promtool/rules.go @@ -234,17 +234,3 @@ func (m *multipleAppender) flushAndCommit(ctx context.Context) error { } return nil } - -func max(x, y int64) int64 { - if x > y { - return x - } - return y -} - -func min(x, y int64) int64 { - if x < y { - return x - } - return y -} diff --git a/tsdb/head_append.go b/tsdb/head_append.go index 58d24ceb9..23c2c0fbd 100644 --- a/tsdb/head_append.go +++ b/tsdb/head_append.go @@ -198,13 +198,6 @@ func (h *Head) AppendableMinValidTime() (int64, bool) { return h.appendableMinValidTime(), true } -func max(a, b int64) int64 { - if a > b { - return a - } - return b -} - func (h *Head) getAppendBuffer() []record.RefSample { b := h.appendPool.Get() if b == nil { diff --git a/tsdb/wlog/live_reader.go b/tsdb/wlog/live_reader.go index 905bbf00d..6eaef5f39 100644 --- a/tsdb/wlog/live_reader.go +++ b/tsdb/wlog/live_reader.go @@ -327,10 +327,3 @@ func (r *LiveReader) readRecord() ([]byte, int, error) { return rec, length + recordHeaderSize, nil } - -func min(i, j int) int { - if i < j { - return i - } - return j -}