diff --git a/CHANGELOG.md b/CHANGELOG.md index 578b58e5ae..45457b0063 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ - Ensure all buffered logs are sent to Sentry when the application terminates unexpectedly ([#4425](https://github.com/getsentry/sentry-dotnet/pull/4425)) - `InvalidOperationException` potentially thrown during a race condition, especially in concurrent high-volume logging scenarios ([#4428](https://github.com/getsentry/sentry-dotnet/pull/4428)) - Blocking calls are no longer treated as unhandled crashes ([#4458](https://github.com/getsentry/sentry-dotnet/pull/4458)) +- Only apply Session Replay masks to specific control types when necessary to avoid performance issues in MAUI apps with complex UIs ([#4445](https://github.com/getsentry/sentry-dotnet/pull/4445)) ### Dependencies diff --git a/samples/Sentry.Samples.Maui/MauiProgram.cs b/samples/Sentry.Samples.Maui/MauiProgram.cs index 909851b7d4..1a8a6a30a7 100644 --- a/samples/Sentry.Samples.Maui/MauiProgram.cs +++ b/samples/Sentry.Samples.Maui/MauiProgram.cs @@ -45,15 +45,18 @@ public static MauiApp CreateMauiApp() options.AddCommunityToolkitIntegration(); #if __ANDROID__ - // Currently experimental support is only available on Android + // Currently, experimental support is only available on Android options.Native.ExperimentalOptions.SessionReplay.OnErrorSampleRate = 1.0; options.Native.ExperimentalOptions.SessionReplay.SessionSampleRate = 1.0; // Mask all images and text by default. This can be overridden for individual view elements via the // sentry:SessionReplay.Mask XML attribute (see MainPage.xaml for an example) options.Native.ExperimentalOptions.SessionReplay.MaskAllImages = true; options.Native.ExperimentalOptions.SessionReplay.MaskAllText = true; - // Alternatively the masking behaviour for entire classes of VisualElements can be configured here as + // Alternatively, the masking behaviour for entire classes of VisualElements can be configured here as // an exception to the default behaviour. + // WARNING: In apps with complex user interfaces, consisting of hundreds of visual controls on a single + // page, this option may cause performance issues. In such cases, consider applying the + // sentry:SessionReplay.Mask="Unmask" attribute to individual controls instead. options.Native.ExperimentalOptions.SessionReplay.UnmaskControlsOfType