From 9d5623218051d36e447a50515fad0f0252e48d65 Mon Sep 17 00:00:00 2001 From: Andrew McKnight Date: Wed, 22 Mar 2023 16:18:10 -0800 Subject: [PATCH] docs: call out beta status for all public-facing profiling APIs (#2804) --- Sources/Sentry/Public/SentryOptions.h | 24 ++++++++++++-------- Sources/SentrySwiftUI/SentryTracedView.swift | 7 ++---- 2 files changed, 17 insertions(+), 14 deletions(-) diff --git a/Sources/Sentry/Public/SentryOptions.h b/Sources/Sentry/Public/SentryOptions.h index 782609f45b3..9adbf503085 100644 --- a/Sources/Sentry/Public/SentryOptions.h +++ b/Sources/Sentry/Public/SentryOptions.h @@ -160,8 +160,8 @@ NS_SWIFT_NAME(Options) @property (nonatomic, assign) BOOL attachStacktrace; /** - * Attention: This is an experimental feature. Turning this feature on can have an impact on - * the grouping of your issues. + * @warning This is an experimental feature and may still have bugs. Turning this feature on can + * have an impact on the grouping of your issues. * * When enabled, the SDK stitches stack traces of asynchronous code together. * @@ -213,7 +213,7 @@ NS_SWIFT_NAME(Options) @property (nonatomic, assign) BOOL attachScreenshot; /** - * This feature is EXPERIMENTAL. + * @warning This is an experimental feature and may still have bugs. * * Automatically attaches a textual representation of the view hierarchy when capturing an error * event. @@ -235,7 +235,7 @@ NS_SWIFT_NAME(Options) @property (nonatomic, assign) NSTimeInterval idleTimeout; /** - * This feature is EXPERIMENTAL. + * @warning This is an experimental feature and may still have bugs. * * Report pre-warmed app starts by dropping the first app start spans if pre-warming paused during * these steps. This approach will shorten the app start duration, but it represents the duration a @@ -349,7 +349,8 @@ NS_SWIFT_NAME(Options) #if SENTRY_TARGET_PROFILING_SUPPORTED /** - * This feature is experimental. Profiling is not supported on watchOS or tvOS. + * @warning This is a beta feature and may still have bugs. + * @note Profiling is not supported on watchOS or tvOS. * * Indicates the percentage profiles being sampled out of the sampled transactions. * @@ -363,7 +364,8 @@ NS_SWIFT_NAME(Options) @property (nullable, nonatomic, strong) NSNumber *profilesSampleRate; /** - * This feature is experimental. Profiling is not supported on watchOS or tvOS. + * @warning This is a beta feature and may still have bugs. + * @note Profiling is not supported on watchOS or tvOS. * * A callback to a user defined profiles sampler function. This is similar to setting * `profilesSampleRate`, but instead of a static value, the callback function will be called to @@ -372,6 +374,9 @@ NS_SWIFT_NAME(Options) @property (nullable, nonatomic) SentryTracesSamplerCallback profilesSampler; /** + * @warning This is a beta feature and may still have bugs. + * @note Profiling is not supported on watchOS or tvOS. + * * If profiling should be enabled or not. Returns YES if either a profilesSampleRate > 0 and * <=1 or a profilesSampler is set otherwise NO. */ @@ -380,11 +385,12 @@ NS_SWIFT_NAME(Options) /** * DEPRECATED: Use `profilesSampleRate` instead. Setting `enableProfiling` to YES is the equivalent * of setting `profilesSampleRate` to `1.0`. If `profilesSampleRate` is set, it will take precedence + * @warning This is a beta feature and may still have bugs. + * @note Profiling is not supported on watchOS or tvOS. + * * over this setting. * * Whether to enable the sampling profiler. Default is NO. - * @note This is a beta feature that is currently not available to all Sentry customers. This - * feature is not supported on watchOS or tvOS. */ @property (nonatomic, assign) BOOL enableProfiling DEPRECATED_MSG_ATTRIBUTE( "Use profilesSampleRate or profilesSampler instead. This property will be removed in a future " @@ -460,7 +466,7 @@ NS_SWIFT_NAME(Options) #if SENTRY_HAS_METRIC_KIT /** - * ATTENTION: This is an experimental feature. + * @warning This is an experimental feature and may still have bugs. * * This feature is disabled by default. When enabled, the SDK sends * ``MXDiskWriteExceptionDiagnostic``, ``MXCPUExceptionDiagnostic`` and ``MXHangDiagnostic`` to diff --git a/Sources/SentrySwiftUI/SentryTracedView.swift b/Sources/SentrySwiftUI/SentryTracedView.swift index 36ca4afc72c..f1a791a5637 100644 --- a/Sources/SentrySwiftUI/SentryTracedView.swift +++ b/Sources/SentrySwiftUI/SentryTracedView.swift @@ -5,8 +5,7 @@ import SwiftUI import SentryInternal #endif -/// -/// This feature is EXPERIMENTAL. +/// - warning: This is an experimental feature and may still have bugs. /// /// A control to measure the performance of your views and send the result as a transaction to Sentry.io. /// @@ -93,11 +92,9 @@ public struct SentryTracedView: View { } } -/// -/// This feature is EXPERIMENTAL. -/// @available(iOS 13, macOS 10.15, tvOS 13, watchOS 6.0, *) public extension View { + /// - warning: This is an experimental feature and may still have bugs. func sentryTrace(_ viewName: String? = nil) -> some View { return SentryTracedView(viewName) { return self