refactor(logging): log with the caller's context so records carry trace ids
This commit is contained in:
1 parent
0611e00330
commit
656feab2a4
118 files changed
+512
-511
No files matched your search
@@ -169,7 +169,7 @@ func (s *EDA) InsertCapture(ctx context.Context, c storecontract.CapturedEvent,
|
||||
return "", fmt.Errorf("edastore: insert capture: %w", err)
|
||||
}
|
||||
if err := s.pruneCaptures(ctx, id, retention, maxEvents); err != nil {
|
||||
s.log.Warn("capture stored but not pruned", "capture", id, "err", err)
|
||||
s.log.WarnContext(ctx, "capture stored but not pruned", "capture", id, "err", err)
|
||||
}
|
||||
return id, nil
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user