Skip to content

Commit 7d82b97

Browse files
committed
Add query to read error log
Signed-off-by: Prithvi Raj <p.r@uber.com>
1 parent 2df4cd0 commit 7d82b97

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

plugin/storage/cassandra/spanstore/reader.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,8 @@ func (s *SpanReader) executeQuery(span opentracing.Span, query cassandra.Query,
410410
tableMetrics.Emit(err, time.Since(start))
411411
if err != nil {
412412
logErrorToSpan(span, err)
413-
s.logger.Error("Failed to exec query", zap.Error(err))
413+
span.LogFields(otlog.String("query", query.String()))
414+
s.logger.Error("Failed to exec query", zap.Error(err), zap.String("query", query.String()))
414415
return nil, err
415416
}
416417
return retMe, nil

0 commit comments

Comments
 (0)