You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
>The sessions will only be uploaded when the app isin the background.
684
+
685
+
TheSDK can be configured to fetch configuration asynchronously to improve app startup time. When enabled, the SDK uses cached configuration for immediate startup and fetches fresh configuration from the server in the background.
686
+
687
+
> [!NOTE]
688
+
>This setting should be called before `startRecording()` for it to take effect. Defaultis disabled for backward compatibility.
<divclass="platform-hinted " data-platform-hinted="data-platform-hinted"><divclass="content sourceset-dependent-content" data-active="" data-togglable=":core/main"><divclass="symbol monospace"><spanclass="token keyword">fun </span><ahref="-dev-rev/index.html">DevRev</a><spanclass="token punctuation">.</span><ahref="set-async-config-fetch-enabled.html"><spanclass="token function">setAsyncConfigFetchEnabled</span></a><spanclass="token punctuation">(</span><spanclass="parameters "><spanclass="parameter ">context<spanclass="token operator">: </span><ahref="https://developer.android.com/reference/kotlin/android/content/Context.html">Context</a><spanclass="token punctuation">, </span></span><spanclass="parameter ">enabled<spanclass="token operator">: </span><ahref="https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html">Boolean</a></span></span><spanclass="token punctuation">)</span></div><pclass="paragraph">Enables or disables async config fetch optimization to improve app startup time.</p><pclass="paragraph">When enabled, the SDK uses cached configuration for immediate startup and fetches fresh configuration from the server in the background. This significantly improves app startup time on slow networks.</p><pclass="paragraph"><strong>Behavior when enabled:</strong></p><ul><li><pclass="paragraph">Uses cached config immediately to decide whether to start recording</p></li><li><pclass="paragraph">If cached config says recording disabled, recording won't start (respects dashboard setting)</p></li><li><pclass="paragraph">Fetches fresh config in background without blocking startup</p></li><li><pclass="paragraph">If fresh config disables recording after it started, recording stops immediately</p></li></ul><pclass="paragraph"><strong>Important:</strong> This should be called before <ahref="start-recording.html">startRecording</a> for the setting to take effect. Default is disabled (false) for backward compatibility.</p><h4class="tableheader">Parameters</h4><divclass="table"><divclass="table-row table-row_content" data-filterable-current=":core/main" data-filterable-set=":core/main"><divclass="main-subrow keyValue "><divclass=""><spanclass="inline-flex"><div><u><span><span>context</span></span></u></div></span></div><div><divclass="title"><pclass="paragraph">An application context</p></div></div></div></div><divclass="table-row table-row_content" data-filterable-current=":core/main" data-filterable-set=":core/main"><divclass="main-subrow keyValue "><divclass=""><spanclass="inline-flex"><div><u><span><span>enabled</span></span></u></div></span></div><div><divclass="title"><pclass="paragraph">true to enable async config fetch, false to use blocking fetch (default)</p></div></div></div></div></div></div></div>
0 commit comments