Skip to content

feat(tracing): send both breadcrumbs and logs by default #878

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

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

lcian
Copy link
Member

@lcian lcian commented Aug 1, 2025

Introduces a new function default_event_filter_with_logs which is the same as the default one but also sends logs for anything above INFO.
If the sentry crate is used with the logs feature and there's already a Hub active, grab enable_logs from the associated client and use the new default filter with logs if possible.
Users still need to opt into sending logs by enabling the feature flag and setting enable_logs: true, but this makes it easier if you don't want to set up a custom event filter, and it also makes the onboarding docs simpler.

An alternative to implement this would be to map tracing events to logs just by looking at the logs feature flag being enabled, but that way the user would still incur a performance penalty in the case they have enable_logs: false in their options, as we would anyways convert each tracing event to a Sentry log unnecessarily.

Close #871

Copy link

github-actions bot commented Aug 1, 2025

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

Generated by 🚫 dangerJS against 480a59c

Copy link

codecov bot commented Aug 1, 2025

Codecov Report

❌ Patch coverage is 87.50000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.13%. Comparing base (4c4fc9d) to head (480a59c).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #878      +/-   ##
==========================================
- Coverage   73.14%   73.13%   -0.01%     
==========================================
  Files          64       64              
  Lines        7365     7375      +10     
==========================================
+ Hits         5387     5394       +7     
- Misses       1978     1981       +3     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

In sentry-tracing, enable EventFilter::Log by default when enable_logs: true
2 participants