From df6f17b82c642b9795191f77197f260d3eb36604 Mon Sep 17 00:00:00 2001 From: Aliaksandr Valialkin Date: Wed, 10 Jul 2019 00:41:18 +0300 Subject: [PATCH] app/vmselect/promql: mention `-search.logSlowQueryDuration` flag value in the slow query log message --- app/vmselect/promql/exec.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/vmselect/promql/exec.go b/app/vmselect/promql/exec.go index bec9fc9f62..42ffbd6ae4 100644 --- a/app/vmselect/promql/exec.go +++ b/app/vmselect/promql/exec.go @@ -34,8 +34,8 @@ func Exec(ec *EvalConfig, q string, isFirstPointOnly bool) ([]netstorage.Result, defer func() { d := time.Since(startTime) if d >= *logSlowQueryDuration { - logger.Infof("slow query: duration=%s, start=%d, end=%d, step=%d, accountID=%d, projectID=%d, query=%q", - d, ec.Start/1000, ec.End/1000, ec.Step/1000, ec.AuthToken.AccountID, ec.AuthToken.ProjectID, q) + logger.Infof("slow query according to -search.logSlowQueryDuration=%s: duration=%s, start=%d, end=%d, step=%d, accountID=%d, projectID=%d, query=%q", + *logSlowQueryDuration, d, ec.Start/1000, ec.End/1000, ec.Step/1000, ec.AuthToken.AccountID, ec.AuthToken.ProjectID, q) } }() }