dd-trace-go
dd-trace-go copied to clipboard
contrib/sirupsen/logrus: support 128-bit Trace IDs and make IDs strings
What does this PR do?
- The logrus hook was always using 64-bit Trace IDs, which broke correlation since the default now is using 128-bit.
- When using JSON output some systems may treat JSON numbers specially and remove precision. Formatting them as string from the get-go will preserve them.
Fixes #3324
Motivation
Enabling correlation of logs and traces as presented in https://docs.datadoghq.com/tracing/other_telemetry/connect_logs_and_traces/go/
Reviewer's Checklist
- [ ] Changed code has unit tests for its functionality at or near 100% coverage.
- [ ] Add an appropriate team label so this PR gets put in the right place for the release notes.