File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change 11# Changelog
22
3+ ## Unreleased
4+
5+ ### Features
6+
7+ - Add `beforeErrorSampling` callback to Session Replay ([#5214](https://github.com/getsentry/sentry-java/pull/5214))
8+ - Allows filtering which errors trigger replay capture before the `onErrorSampleRate` is checked
9+ - Returning `false` skips replay capture entirely for that error; returning `true` proceeds with the normal sample rate check
10+ - Example usage:
11+ ```java
12+ SentryAndroid.init(context) { options ->
13+ options.sessionReplay.beforeErrorSampling =
14+ SentryReplayOptions.BeforeErrorSamplingCallback { event, hint ->
15+ // Skip replay for handled exceptions
16+ val dominated = event.exceptions?.lastOrNull()
17+ val isHandled = dominated?.mechanism?.isHandled == true
18+ !isHandled
19+ }
20+ }
21+ ```
22+
323## 8.36.0
424
525### Features
You can’t perform that action at this time.
0 commit comments