From df7db4ac0767cf9c58e64f3af817ec80ac4fd61c Mon Sep 17 00:00:00 2001 From: Goutham Veeramachaneni Date: Sun, 19 Mar 2017 21:03:09 +0530 Subject: [PATCH] Update kit/log To New API NewContext has been removed couple of weeks back. Ref: https://github.com/go-kit/kit/releases/tag/v0.4.0 --- db.go | 2 +- head.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/db.go b/db.go index 4de657a39..a89665e27 100644 --- a/db.go +++ b/db.go @@ -157,7 +157,7 @@ func Open(dir string, l log.Logger, r prometheus.Registerer, opts *Options) (db if l == nil { l = log.NewLogfmtLogger(os.Stdout) - l = log.NewContext(l).With("ts", log.DefaultTimestampUTC, "caller", log.DefaultCaller) + l = log.With(l, "ts", log.DefaultTimestampUTC, "caller", log.DefaultCaller) } if opts == nil { diff --git a/head.go b/head.go index eed2ff222..4bebb379c 100644 --- a/head.go +++ b/head.go @@ -86,7 +86,7 @@ func createHeadBlock(dir string, seq int, l log.Logger, mint, maxt int64) (*head // openHeadBlock creates a new empty head block. func openHeadBlock(dir string, l log.Logger) (*headBlock, error) { - wal, err := OpenWAL(dir, log.NewContext(l).With("component", "wal"), 5*time.Second) + wal, err := OpenWAL(dir, log.With(l, "component", "wal"), 5*time.Second) if err != nil { return nil, err }