Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@
- With this change, we capture errors returned by middleware only if those errors can be classified as server errors.
- There is no change in behavior when it comes to errors returned by services, in which case the Sentry middleware only captures server errors exclusively.

### Behavioral changes

- feat(tracing): send both breadcrumbs and logs by default ([#878](https://github.com/getsentry/sentry-rust/pull/878)) by @lcian
- If the `logs` feature flag is enabled, and `enable_logs: true` is set on your client options, the default Sentry `tracing` layer now sends logs for all events at or above INFO.

### Features

- feat(core): add Response context ([#874](https://github.com/getsentry/sentry-rust/pull/874)) by @lcian
Expand Down
6 changes: 6 additions & 0 deletions sentry-tracing/src/layer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,13 @@ impl From<Vec<EventMapping>> for CombinedEventMapping {
/// `warning` and `info`, and `debug` and `trace` logs are ignored.
pub fn default_event_filter(metadata: &Metadata) -> EventFilter {
match metadata.level() {
#[cfg(feature = "logs")]
&Level::ERROR => EventFilter::Event | EventFilter::Log,
#[cfg(not(feature = "logs"))]
&Level::ERROR => EventFilter::Event,
#[cfg(feature = "logs")]
&Level::WARN | &Level::INFO => EventFilter::Breadcrumb | EventFilter::Log,
#[cfg(not(feature = "logs"))]
&Level::WARN | &Level::INFO => EventFilter::Breadcrumb,
&Level::DEBUG | &Level::TRACE => EventFilter::Ignore,
}
Expand Down
Loading