Skip to content

Commit 562a93a

Browse files
authored
Add comments outlining the worries against using FirebaseSessionsEnabled (#10784)
1 parent e5b11ab commit 562a93a

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

FirebaseSessions/README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,9 @@ You can access command line parameters by following: Press `CMD-Shift-,` => Run
3434
#### Overriding Settings
3535
You can override the Settings values fetched from the server using the app's Info.plist. The full list of override plist keys can be found in `LocalOverrideSettings.swift`.
3636

37-
- **FirebaseSessionsEnabled**: Bool representing whether to make any network calls
37+
- **FirebaseSessionsEnabled**: Bool representing whether to send Session Events (does not affect Settings requests). We would recommend apps against using this to disable data collection, and instead disable it via products' public data collection APIs.
38+
- If any apps use this flag to disable the Firebase Sessions SDK, keep in mind this may break future metrics features with products like FirePerf and Crashlytics.
39+
- This flag is internal and may break in a future version of FirebaseSessions
3840
- **FirebaseSessionsTimeout**: Float number of seconds representing the time that an app must be backgrounded before generating a new session
3941
- **FirebaseSessionsSampingRate**: Float between 0 and 1 representing how often events are sent. 0 is drop everything, 1 is send everything.
4042

FirebaseSessions/Sources/Settings/LocalOverrideSettings.swift

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,13 @@ import Foundation
1717

1818
/// Class that manages the local overrides configs related to the library.
1919
class LocalOverrideSettings: SettingsProvider {
20+
// This will disable Sessions SDK Events, but not Settings requests.
21+
// If any apps use this flag to disable the Firebase Sessions SDK,
22+
// keep in mind this may break metrics future features with products like
23+
// FirePerf and Crashlytics. As a result, we would recommend apps
24+
// use another way to disable data collection (like disabling it via
25+
// the product public data collection APIs themselves).
26+
// This flag is internal and may break in the future.
2027
static let PlistKey_sessions_enabled = "FirebaseSessionsEnabled"
2128
static let PlistKey_sessions_timeout = "FirebaseSessionsTimeout"
2229
static let PlistKey_sessions_samplingRate = "FirebaseSessionsSampingRate"

0 commit comments

Comments
 (0)