Skip to content

Conversation

lcian
Copy link
Member

@lcian lcian commented Sep 30, 2025

Description

Adds support for combining multiple LogFilters when using our integration for the log crate.
This way, it's possible to map a log record to multiple items in Sentry, for example to both a log and an event.

This is required for #909.
There, we want to enable logs for records at or above INFO by default, in order to remove the double opt-in, while still sending breadcrumbs for them at the same time.

The changes are analogous with the ones we did for the tracing integration here: #847

Issues

Close #908
Close RUST-111

Copy link

linear bot commented Sep 30, 2025

Copy link

github-actions bot commented Sep 30, 2025

Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 2272f4d

Copy link

codecov bot commented Sep 30, 2025

Codecov Report

❌ Patch coverage is 72.72727% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.50%. Comparing base (9ba9a64) to head (2272f4d).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #914      +/-   ##
==========================================
+ Coverage   73.46%   73.50%   +0.03%     
==========================================
  Files          64       64              
  Lines        7518     7533      +15     
==========================================
+ Hits         5523     5537      +14     
- Misses       1995     1996       +1     

@lcian lcian marked this pull request as ready for review October 1, 2025 12:33
@lcian lcian requested a review from szokeasaurusrex October 1, 2025 12:33
cursor[bot]

This comment was marked as outdated.

cursor[bot]

This comment was marked as outdated.

Copy link
Member

@szokeasaurusrex szokeasaurusrex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good in principle, but I have a suggestion for simplifying the code

cursor[bot]

This comment was marked as outdated.

Copy link
Member

@Swatinem Swatinem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One weird thing might be that with bitflags, you can combine Ignore with any of the others just fine, and the compiler won’t complain, even though it does not make sense.
But thats a minor papercut, not worth wasting time over.

@lcian lcian merged commit 3b78cf8 into master Oct 7, 2025
19 checks passed
@lcian lcian deleted the lcian/feat/log-multiple-mappings branch October 7, 2025 09:09
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.

Support multiple mappings in log integration

3 participants