Movatterモバイル変換


[0]ホーム

URL:


Dev guideRecipesAPI ReferenceChangelog
Dev guideAPI ReferenceRecipesChangelogUser GuideGitHubDev CommunityOptimizely AcademySubmit a ticketLog InFeature Experimentation
Dev guide
All
Pages
Start typing to search…

Customize the Android SDK error handler

How to create your own error handler logic for the Optimizely Feature Experimentation Android SDK.

To standardize error reporting across your production environment, you can provide your own customerror handler logic in the Optimizely Feature Experimentation Android SDK.

This error handler is called when an unknown feature flag key is referenced.

See the code example below. If the error handler is not overridden, a no-op error handler is used by default.

// Error handler that raises exceptionsval errorHandler: ErrorHandler = RaiseExceptionErrorHandler()val optimizelyManager = OptimizelyManager.builder()         .withSDKKey("<Your_SDK_Key>")         .withErrorHandler(errorHandler)         .withDatafileDownloadInterval(15, TimeUnit.MINUTES)         .build(context)
// Error handler that raises exceptionsErrorHandler errorHandler = new RaiseExceptionErrorHandler();OptimizelyManager optimizelyManager = OptimizelyManager.builder()        .withSDKKey("<Your_SDK_Key>")        .withErrorHandler(errorHandler)        .withDatafileDownloadInterval(15, TimeUnit.MINUTES)        .build(context);

Updated 17 days ago



[8]ページ先頭

©2009-2025 Movatter.jp