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
1 change: 1 addition & 0 deletions CHANGELOG-v9.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Removes deprecated `setExtraValue` from SentrySpan (#5864)
Removes `integrations` property from `SentryOptions` (#5749)
Makes `SentryEventDecodable` internal (#5808)
The `span` property on `SentryScope` is now readonly (#5866)
Removes `enablePerformanceV2` option and makes this the default (#6008)

### Fixes

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,9 @@ public struct SentrySDKWrapper {
options.enableCrashHandler = !SentrySDKOverrides.Other.disableCrashHandling.boolValue
options.enablePersistingTracesWhenCrashing = true
options.enableTimeToFullDisplayTracing = !SentrySDKOverrides.Performance.disableTimeToFullDisplayTracing.boolValue
#if !SDK_V9
options.enablePerformanceV2 = !SentrySDKOverrides.Performance.disablePerformanceV2.boolValue
#endif
options.failedRequestStatusCodes = [ HttpStatusCodeRange(min: 400, max: 599) ]

#if targetEnvironment(simulator)
Expand Down
2 changes: 2 additions & 0 deletions Sources/Sentry/Public/SentryOptions.h
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,7 @@ NS_SWIFT_NAME(Options)
*/
@property (nonatomic, assign) BOOL enableAutoPerformanceTracing;

#if !SDK_V9
/**
* We're working to update our Performance product offering in order to be able to provide better
* insights and highlight specific actions you can take to improve your mobile app's overall
Expand All @@ -296,6 +297,7 @@ NS_SWIFT_NAME(Options)
* UIWindowDidBecomeVisibleNotification. This change will be the default in the next major version.
*/
@property (nonatomic, assign) BOOL enablePerformanceV2;
#endif // !SDK_V9

/**
* @warning This is an experimental feature and may still have bugs.
Expand Down
7 changes: 6 additions & 1 deletion Sources/Sentry/SentryAppStartTrackingIntegration.m
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,17 @@ - (BOOL)installWithOptions:(SentryOptions *)options
SentryAppStateManager *appStateManager =
[SentryDependencyContainer sharedInstance].appStateManager;

# if SDK_V9
BOOL usePerformanceV2 = YES;
# else
BOOL usePerformanceV2 = options.enablePerformanceV2;
# endif // SDK_V9
self.tracker = [[SentryAppStartTracker alloc]
initWithDispatchQueueWrapper:[[SentryDispatchQueueWrapper alloc] init]
appStateManager:appStateManager
framesTracker:SentryDependencyContainer.sharedInstance.framesTracker
enablePreWarmedAppStartTracing:options.enablePreWarmedAppStartTracing
enablePerformanceV2:options.enablePerformanceV2];
enablePerformanceV2:usePerformanceV2];
[self.tracker start];

return YES;
Expand Down
2 changes: 2 additions & 0 deletions Sources/Sentry/SentryOptions.m
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,9 @@ - (instancetype)init
self.maxAttachmentSize = 20 * 1024 * 1024;
self.sendDefaultPii = NO;
self.enableAutoPerformanceTracing = YES;
#if !SDK_V9
self.enablePerformanceV2 = NO;
#endif // !SDK_V9
self.enablePersistingTracesWhenCrashing = NO;
self.enableCaptureFailedRequests = YES;
self.environment = kSentryDefaultEnvironment;
Expand Down
2 changes: 2 additions & 0 deletions Sources/Sentry/SentyOptionsInternal.m
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,10 @@ + (BOOL)validateOptions:(NSDictionary<NSString *, id> *)options
[self setBool:options[@"enableAutoPerformanceTracing"]
block:^(BOOL value) { sentryOptions.enableAutoPerformanceTracing = value; }];

#if !SDK_V9
[self setBool:options[@"enablePerformanceV2"]
block:^(BOOL value) { sentryOptions.enablePerformanceV2 = value; }];
#endif // !SDK_V9

[self setBool:options[@"enablePersistingTracesWhenCrashing"]
block:^(BOOL value) { sentryOptions.enablePersistingTracesWhenCrashing = value; }];
Expand Down
2 changes: 2 additions & 0 deletions Sources/Swift/Helper/SentryEnabledFeaturesBuilder.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ import Foundation
features.append("captureFailedRequests")
}

#if !SDK_V9
if options.enablePerformanceV2 {
features.append("performanceV2")
}
#endif // !SDK_V9

if options.enableTimeToFullDisplayTracing {
features.append("timeToFullDisplayTracing")
Expand Down
Loading