Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Add log sampling #709

Merged
merged 4 commits into from
Aug 27, 2024
Merged

chore: Add log sampling #709

merged 4 commits into from
Aug 27, 2024

Conversation

Eric-Warehime
Copy link
Collaborator

Adds log sampling to reduce logging. The log sampler wraps our core logger whenever we're not at debug log level. It limits logging output to a single entry per 10 seconds if the entries have the same message.

Some logs which happen on startup I've added provider names to in order to avoid having them sampled.

Copy link

codecov bot commented Aug 27, 2024

Codecov Report

Attention: Patch coverage is 78.57143% with 3 lines in your changes missing coverage. Please review.

Project coverage is 56.56%. Comparing base (f174ff2) to head (4d91d18).
Report is 1 commits behind head on main.

Files Patch % Lines
pkg/log/zap.go 0.00% 3 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #709   +/-   ##
=======================================
  Coverage   56.55%   56.56%           
=======================================
  Files         257      257           
  Lines       13495    13505   +10     
=======================================
+ Hits         7632     7639    +7     
- Misses       5126     5129    +3     
  Partials      737      737           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Eric-Warehime Eric-Warehime enabled auto-merge (squash) August 27, 2024 14:45
@Eric-Warehime Eric-Warehime merged commit 7391885 into main Aug 27, 2024
14 of 15 checks passed
@Eric-Warehime Eric-Warehime deleted the eric/reduce-logging branch August 27, 2024 14:53
aljo242 pushed a commit that referenced this pull request Dec 11, 2024
aljo242 pushed a commit that referenced this pull request Dec 11, 2024
Co-authored-by: Eric Warehime <eric.warehime@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants