Add Graylog logging configuration #252 - #264
Conversation
ZohebShaikh
left a comment
There was a problem hiding this comment.
Looks good only few minor things
bda4336 to
831a990
Compare
- Extract GraylogOptions into its own struct, independent of TracingOptions - Remove .vscode/launch.json (to be added in a separate PR) - Remove version/build additional_field calls from Graylog logger - Switch let-else to if-let in init_graylog - Warn when Graylog URL has no port rather than silently defaulting - Add reconnect loop so dropped connections recover automatically - Improve connection error messages to distinguish DNS failure from TCP errors
831a990 to
0a86a82
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #264 +/- ##
==========================================
+ Coverage 76.44% 78.75% +2.31%
==========================================
Files 13 13
Lines 1944 2057 +113
==========================================
+ Hits 1486 1620 +134
+ Misses 458 437 -21 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
tpoliaw
left a comment
There was a problem hiding this comment.
Looks pretty good, thanks for looking at it. A couple of changes could make the error handling a bit cleaner and keep it more consistent with what is already there though.
498354e to
59d5002
Compare
59d5002 to
926a966
Compare
… removed, unwrapped method body from the if and relaxed the graylog filter
tpoliaw
left a comment
There was a problem hiding this comment.
I think this looks good now, thanks. We should release it to staging and see how it gets on for a while.
|
@Alexj9837 BTW When this was merged the configuration for graylog was not added so currently at numtracker-staging it does not have graylog enabled I couldn't tag you on the GitLab so putting it here |
#252
Summary
tracing-gelflayer to ship structured logs to a Graylog instance via GELF TCP--graylog <URL>and--logging-level <LEVEL>CLI flags (also viaNUMTRACKER_GRAYLOG/NUMTRACKER_GRAYLOG_LOG_LEVELenv vars)numtracker.graylog.enabled/host/levelvalues