Skip to content

Commit ca60e02

Browse files
committed
Define FeatureFlag cases for performance monitoring
1 parent 8764eb5 commit ca60e02

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

Experiments/Experiments/FeatureFlag.swift

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,39 @@ public enum FeatureFlag: Int {
8585
/// Store creation MVP.
8686
///
8787
case storeCreationMVP
88+
89+
// MARK: - Performance Monitoring
90+
//
91+
// These flags are not transient. That is, they are not here to help us rollout a feature,
92+
// but to serve a safety switches to granularly turn off performance monitoring if it looks
93+
// like we are consuming too many events.
94+
95+
/// Whether to enable performance monitoring
96+
///
97+
case performanceMonitoring
98+
99+
/// Whether to enable performance monitoring for Core Data operations.
100+
///
101+
/// - Note: The app will ignore this if `performanceMonitoring` is `false`
102+
case performanceMonitoringCoreData
103+
104+
/// Whether to enable performance monitoring for file IO operations.
105+
///
106+
/// - Note: The app will ignore this if `performanceMonitoring` is `false`
107+
case performanceMonitoringFileIO
108+
109+
/// Whether to enable performance monitoring for networking operations.
110+
///
111+
/// - Note: The app will ignore this if `performanceMonitoring` is `false`
112+
case performanceMonitoringNetworking
113+
114+
/// Whether to enable performance monitoring for user interaction events.
115+
///
116+
/// - Note: The app will ignore this if `performanceMonitoring` is `false`
117+
case performanceMonitoringUserInteraction
118+
119+
/// Whether to enable performance monitoring for `UIViewController` life-cycle events.
120+
///
121+
/// - Note: The app will ignore this if `performanceMonitoring` is `false`
122+
case performanceMonitoringViewController
88123
}

0 commit comments

Comments
 (0)