Skip to content

Commit 9448248

Browse files
authored
feat(mobile): Explain how sessions work for session replay (#14663)
1 parent 2565378 commit 9448248

File tree

4 files changed

+40
-0
lines changed

4 files changed

+40
-0
lines changed

docs/platforms/android/session-replay/index.mdx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,16 @@ While you're testing, we recommend that you set `sessionSampleRate` to `1.0`. Th
7171

7272
Once testing is complete, **we recommend lowering this value in production**. We still recommend keeping `onErrorSampleRate` set to `1.0`.
7373

74+
## User Session
75+
76+
A user session starts when the Sentry SDK is initialized or when the application enters the foreground. The session will capture screen transitions, navigations, touches and other events until the application is sent to the background. If the application is brought back to the foreground within 30 seconds (default), the same `replay_id` will be used and the session will continue.
77+
78+
The session will be terminated if the application has spent in the background more than 30 seconds or when the maximum duration of 60 minutes is reached. You can adjust the [session tracking interval](/platforms/android/configuration/releases/#sessions) to extend or shorten the duration of a single replay, depending on your needs.
79+
80+
### Replay Captures on Errors Only
81+
82+
If you prefer not to record an entire session, you can elect to capture a replay only if an error occurs. In this case, the integration will buffer up to one minute worth of events prior to the error being thrown. It will continue to record the session, following the rules above regarding session life and activity. Read the [sampling](#sampling) section for configuration options.
83+
7484
## Sampling
7585

7686
Sampling allows you to control how much of your website's traffic will result in a Session Replay. There are two sample rates you can adjust to get the replays relevant to you:

docs/platforms/apple/guides/ios/session-replay/index.mdx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,16 @@ While you're testing, we recommend that you set `sessionSampleRate` to `1.0`. Th
5656

5757
Once testing is complete, **we recommend lowering this value in production**. We still recommend keeping `onErrorSampleRate` set to `1.0`.
5858

59+
## User Session
60+
61+
A user session starts when the Sentry SDK is initialized or when the application enters the foreground. The session will capture screen transitions, navigations, touches and other events until the application is sent to the background. If the application is brought back to the foreground within 30 seconds (default), the same `replay_id` will be used and the session will continue.
62+
63+
The session will be terminated if the application has spent in the background more than 30 seconds or when the maximum duration of 60 minutes is reached. You can adjust the [session tracking interval](/platforms/apple/guides/ios/configuration/releases/#sessions) to extend or shorten the duration of a single replay, depending on your needs.
64+
65+
### Replay Captures on Errors Only
66+
67+
If you prefer not to record an entire session, you can elect to capture a replay only if an error occurs. In this case, the integration will buffer up to one minute worth of events prior to the error being thrown. It will continue to record the session, following the rules above regarding session life and activity. Read the [sampling](#sampling) section for configuration options.
68+
5969
## Sampling
6070

6171
Sampling allows you to control how much of your app's traffic will result in a Session Replay. There are two sample rates you can adjust to get the replays relevant to you:

docs/platforms/dart/guides/flutter/session-replay/index.mdx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,16 @@ While you're testing, we recommend that you set `sessionSampleRate` to `1.0`. Th
5151

5252
Once testing is complete, **we recommend lowering this value in production**. We still recommend keeping `onErrorSampleRate` set to `1.0`.
5353

54+
## User Session
55+
56+
A user session starts when the Sentry SDK is initialized or when the application enters the foreground. The session will capture screen transitions, navigations, touches and other events until the application is sent to the background. If the application is brought back to the foreground within 30 seconds (default), the same `replay_id` will be used and the session will continue.
57+
58+
The session will be terminated if the application has spent in the background more than 30 seconds or when the maximum duration of 60 minutes is reached. You can adjust the [session tracking interval](/platforms/dart/guides/flutter/configuration/releases/#sessions) to extend or shorten the duration of a single replay, depending on your needs.
59+
60+
### Replay Captures on Errors Only
61+
62+
If you prefer not to record an entire session, you can elect to capture a replay only if an error occurs. In this case, the integration will buffer up to one minute worth of events prior to the error being thrown. It will continue to record the session, following the rules above regarding session life and activity. Read the [sampling](#sampling) section for configuration options.
63+
5464
## Sampling
5565

5666
Sampling allows you to control how much of your website's traffic will result in a Session Replay. There are two sample rates you can adjust to get the replays relevant to you:

docs/platforms/react-native/session-replay/index.mdx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,16 @@ While you're testing, we recommend that you set <PlatformIdentifier name="replay
6969

7070
Once testing is complete, **we recommend lowering this value in production**. We still recommend keeping <PlatformIdentifier name="replays-on-error-sample-rate" /> set to `1.0`.
7171

72+
## User Session
73+
74+
A user session starts when the Sentry SDK is initialized or when the application enters the foreground. The session will capture screen transitions, navigations, touches and other events until the application is sent to the background. If the application is brought back to the foreground within 30 seconds (default), the same `replay_id` will be used and the session will continue.
75+
76+
The session will be terminated if the application has spent in the background more than 30 seconds or when the maximum duration of 60 minutes is reached. You can adjust the [session tracking interval](/platforms/react-native/configuration/releases/#sessions) to extend or shorten the duration of a single replay, depending on your needs.
77+
78+
### Replay Captures on Errors Only
79+
80+
If you prefer not to record an entire session, you can elect to capture a replay only if an error occurs. In this case, the integration will buffer up to one minute worth of events prior to the error being thrown. It will continue to record the session, following the rules above regarding session life and activity. Read the [sampling](#sampling) section for configuration options.
81+
7282
## Sampling
7383

7484
Sampling allows you to control how much of your website's traffic will result in a Session Replay. There are two sample rates you can adjust to get the replays relevant to you:

0 commit comments

Comments
 (0)