From dc4befd077d65b56e6f1c8667ec4ee4fa1000cb6 Mon Sep 17 00:00:00 2001 From: Artem Glazychev Date: Mon, 17 May 2021 17:40:07 +0700 Subject: [PATCH] Add fields to logger on Close (#194) Signed-off-by: Artem Glazychev --- main.go | 1 + 1 file changed, 1 insertion(+) diff --git a/main.go b/main.go index b89c399..fb7e2dc 100644 --- a/main.go +++ b/main.go @@ -229,6 +229,7 @@ func main() { defer func() { closeCtx, cancelClose := context.WithTimeout(context.Background(), c.RequestTimeout) + closeCtx = log.WithFields(closeCtx, log.Fields(ctx)) defer cancelClose() _, _ = nsmClient.Close(closeCtx, resp) }()