Skip to content
Open
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
4 changes: 4 additions & 0 deletions src/Sentry/Platforms/Android/BindableNativeSentryOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ public class NativeOptions
public bool? PrintUncaughtStackTrace { get; set; }
public double? ProfilesSampleRate { get; set; }
public TimeSpan? ReadTimeout { get; set; }
public bool? TombstoneEnabled { get; set; }
public bool? ReportHistoricalTombstones { get; set; }
public bool? EnableTracing { get; set; }
public bool? EnableBeforeSend { get; set; }

Expand Down Expand Up @@ -77,6 +79,8 @@ public void ApplyTo(SentryOptions.NativeOptions options)
options.PrintUncaughtStackTrace = PrintUncaughtStackTrace ?? options.PrintUncaughtStackTrace;
options.ProfilesSampleRate = ProfilesSampleRate ?? options.ProfilesSampleRate;
options.ReadTimeout = ReadTimeout ?? options.ReadTimeout;
options.TombstoneEnabled = TombstoneEnabled ?? options.TombstoneEnabled;
options.ReportHistoricalTombstones = ReportHistoricalTombstones ?? options.ReportHistoricalTombstones;
options.EnableTracing = EnableTracing ?? options.EnableTracing;
options.EnableBeforeSend = EnableBeforeSend ?? options.EnableBeforeSend;

Expand Down
12 changes: 12 additions & 0 deletions src/Sentry/Platforms/Android/NativeOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,18 @@ internal NativeOptions(SentryOptions options)
/// </summary>
public TimeSpan ReadTimeout { get; set; } = TimeSpan.FromSeconds(5);

/// <summary>
/// Gets or sets a value that indicates if native crash reporting via tombstones is enabled.
/// The default value is <c>false</c> (disabled).
/// </summary>
public bool TombstoneEnabled { get; set; } = false;

/// <summary>
/// Gets or sets a value that indicates if historical tombstones should be reported.
/// The default value is <c>false</c> (disabled).
/// </summary>
public bool ReportHistoricalTombstones { get; set; } = false;

// ---------- Other ----------

internal List<string>? InAppExcludes { get; private set; }
Expand Down
2 changes: 2 additions & 0 deletions src/Sentry/Platforms/Android/SentrySdk.cs
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,8 @@ private static void InitSentryAndroidSdk(SentryOptions options)
o.ProfilesSampleRate = (JavaDouble?)options.Native.ProfilesSampleRate;
o.PrintUncaughtStackTrace = options.Native.PrintUncaughtStackTrace;
o.ReadTimeoutMillis = (int)options.Native.ReadTimeout.TotalMilliseconds;
o.TombstoneEnabled = options.Native.TombstoneEnabled;
o.ReportHistoricalTombstones = options.Native.ReportHistoricalTombstones;

// In-App Excludes and Includes to be passed to the Android SDK
options.Native.InAppExcludes?.ForEach(o.AddInAppExclude);
Expand Down
Loading