_______ ___ _______ ___ _____ ___ ______ ___
__________ ____ _______ ____________ __ ______ _____________ _____ ____ ____ __________ _ ___ _______________ _____ ___ ______
___ ___ __________ ____ _______ ____________ ___ ______ ___ _____ ___ _______ ___ _____ ____ ___ ______ _____________ _______________ ___ ________
__ __________ ____ _______ ___________ ___ ___ ____ ____ ______ ____ ______ ___ ____________ __ ____ _____
______ _____ _______ __ ___ __ ____ ___________
___ ______ _______ _______ _____________ ________ ______ ___ ________ _ ___ ________ __ _______________ ___ ______ __ ___ ___ ___ ____ ______ _______ __ ______ ____ __ __________ _____________ ___ ___ ______ _______ _____ ___ __________ ______ __ ______________ ___ ______ ___ __________ _______ __ _ _______ ______
_____ _____________ ___ ____________
________ __________ __ ____ ___________
__ __________ ____________ ____ ___ __ _______ ___ ______ __ __ ___ ___ ____ ________ ___________
__ ________ __________ __ ____ ____________ ____ ___ ____________ ____ ___ ____ ___ ______ ___ ______ ___ ______________ ___ ____________ ________ __ __ ___ _________ _________
- ______
-
android { compileOptions { //... coreLibraryDesugaringEnabled = true sourceCompatibility = JavaVersion.VERSION_1_8 // Java 8 and higher targetCompatibility = JavaVersion.VERSION_1_8 // Java 8 and higher //... } } dependencies { //... coreLibraryDesugaring("com.android.tools:desugar_jdk_libs:1.1.5") //... } - ______
-
android { compileOptions { //... coreLibraryDesugaringEnabled true sourceCompatibility JavaVersion.VERSION_1_8 // Java 8 and higher targetCompatibility JavaVersion.VERSION_1_8 // Java 8 and higher //... } } dependencies { //... coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5' //... }
____ ___ ____ ____ _______ __ _________ __________ __ ____ ____________
_______ ___ _______ _____ __ _ __________
__ ________ ___ ______ ___ ____ _______ ___ _______ ___ _____ __ _ __________ __________ __ ____ _______ ____________
______ _____ _____ __ _______ ___ _______ ___ _____ _____ _____ ________
-
____ ____ _____ _______ __ __ ___ ____________ _______ __ ____ ____ ____________ _____
allprojects { repositories { google() //... mavenCentral() } } -
___ ___ ______ _______ ___ _____ _______ __ _ __________ __ ___ ____________ ____ __ ____ ____________
- ______
-
dependencies { //... // Set the desired version of the RUM agent. // See available releases: https://github.com/signalfx/splunk-otel-android/releases implementation("com.splunk:splunk-otel-android:+") implementation("io.opentelemetry.android:instrumentation:+") //... } - ______
-
dependencies { //... // Set the desired version of the RUM agent. // See available releases: https://github.com/signalfx/splunk-otel-android/releases implementation 'com.splunk:splunk-otel-android:+' implementation 'io.opentelemetry.android:instrumentation:+' //... }
-
_________ ___ __________ ___ _______ ___ _____ __ _______ _ _____________ ______ __ ___ ______________ ____ __
_______________________import com.splunk.rum.SplunkRum import com.splunk.rum.StandardAttributes import io.opentelemetry.api.common.Attributes class MyApplication extends Application { private final String realm = "<realm>"; private final String rumAccessToken = "<your_RUM_access_token>"; @Override public void onCreate() { super.onCreate(); SplunkRum.builder() .setApplicationName("<name_of_app>") .setDeploymentEnvironment("<name_of_env>") // Environment .setRealm(realm) .setRumAccessToken(rumAccessToken) .setGlobalAttributes( Attributes.builder() // Add the application version. Alternatively, you // can pass BuildConfig.VERSION_NAME as the value. .put(StandardAttributes.APP_VERSION, "<version_of_app>") .build() ) // Turn off instrumentation of background processes .disableBackgroundTaskReporting(BuildConfig.<id_of_application>) // Activates debug logging if needed //.enableDebug() .build(this); } }-
___ _____ ______ __
__________ ___ ______ _____________ _____ ______ ___ ____________ __ ____ ___ _____ ____ __ ____ ________ ______ _____ ______-
____ ___ __________ ____ __ ______ _____________ ______
-
______ _________
-
______ ____ _________
___ _____ ____ _______ __ ___ _____________ ________
-
-
__ ________ _ ___ ______ ______ ___ ________ ____ ___ ______ _____ __ ______ _____________ _____No Content found for /db/organizations/splunk/repositories/portal-production/content/documents/ObservabilityCloud/gdi/rum/set-up-rum.dita#dc2a8f93d3cb342bd894094b8db4b2738/rum-access-token_
-
-
__________ ____ ____ _______ ___ ________ ___ _________ ________ ___________ _______
private fun buildOkHttpClient(splunkRum: SplunkRum): Call.Factory { return splunkRum.createRumOkHttpCallFactory(OkHttpClient()) }___ ____ _______________ ________ ___ ____ ____________
注: ____ ____ __ _______ ___ ______ __ __________ __ ______ ___ __ __ ________ __ _____ _______________________________________________ ________________ __ _________ __ ____ __ _______ __ _ ______ ________ ___ ________ ____ __ ______ ___ _________ _______________ __ _______ __ _ ___ ___ ___ ______ ________________ -
_______ ___ _______ __ ___ _______ ____________
-
________ ____ ____ ________ __ ____ ____________ _____ ______ __________ ____ ___ ____________ ______ ____ ___ ____ __ _________ __ ___ ___ __________
注: ___ ___ _____ _______ ___ _______ ___ _____ ___ ____ ___________ __ _______ __________________________________ ________ __ ____ _____
___ _ ______ ___________ _____ _______ ____ ___ ___ ______ ___________ __ ______ _
_____ ___ _______ ___ _______ _______
__ ________ ___ _____ ___ _______ ___ _______ ________ ______ _____ ______
-
_____ ___ __________ __ ____ ________
git clone https://github.com/signalfx/splunk-otel-android.git -
_____ _______ ___ _______ __ ____ _____ _____ ___________
./gradlew publishToMavenLocal -
____ ____ __ ___
______________ ___ __________ __ ____ ____________ _____allprojects { repositories { google() //... mavenLocal() } } -
___ ___ _______ ______ _____ __ _ __________ __ ___ ____________ _____
dependencies { //... implementation ("com.splunk:splunk-otel-android:<version>") //... }
__________ _______ ________ _____ ___ _______ ___ _____
___ ___ ___ ______ ___ _______________ ___ _______ ___ _______________ ______________ __ _______ ___ ___________________ _______ ____ ________________ __ ___ ___ ____ ________ __ ___ _______
___ _________ _______ _____ ___ __ _________ _______ ___ ____ ______ _______ ____
import android.webkit.WebView
import com.splunk.rum.SplunkRum
//...
/*
Make sure that the WebView instance only loads pages under
your control and instrumented with Splunk Browser RUM. The
integrateWithBrowserRum() method can expose the splunk.rumSessionId
of your user to every site/page loaded in the WebView instance.
*/
override fun onViewCreated(view: View, @Nullable savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
binding.webView.setWebViewClient(LocalContentWebViewClient(assetLoader))
binding.webView.loadUrl("https://subdomain.example.com/instrumented-page.html")
binding.webView.getSettings().setJavaScriptEnabled(true)
binding.webView.addJavascriptInterface(WebAppInterface(getContext()), "Android")
SplunkRum.getInstance().integrateWithBrowserRum(binding.webView)
}
____ ___ ____ ______ ___
______ ___ ____ ______ ______ __ _________ ___ ________ ____ _______ ___ _____ ___ ___ ____ ___ __ ____ ____________ ___ __ ____ ___ _________ ___ ________ ______ ___ __________ ___________
__ ________ ___ ______ _____________ __ _____________ _______ ____ ___ _____________ _______ ___ ______ _____ _____ ____ ___ _______ ____ ________ _____ ___ _______
___ ___ ___________ ________ ___ ___________ ___ _____________ ______ __ __________________________________________ ___ _________________________________________ __ ____ __ ______ ____
______ __________ ______ _______ _________
__ ______ __ ______ __________ __ ____ ______ ____ __ __________ ____________ ___________ ______ ___ ______ ______
___ __ __________
___ ______ _____________ _______________ ___ _______ __ ___________ _________ ___ ___ __________ __ ___ ___________ __ ________ ____ ________ __ _______ __ _____ _____ ___ ___ ____________ __________ __ _______
____ _____
-
__ ___ ______ ___________ _____ ___ _______________ __ ____ ___________ ___ ____________ _________ _________ ___ _____ ___ _________ ___ ______ _______ ___ ________________
-
__ _____ ____ ____ ____ __ __ ____ ______ ___ ___ ______ _________ ___ _____ ____ ____ ____ __ ______ __No Content found for /db/organizations/splunk/repositories/portal-production/content/documents/ObservabilityCloud/gdi/rum/set-up-rum.dita#dc2a8f93d3cb342bd894094b8db4b2738/rum-check-mobile-data_
-
__ _____________ ___ ____________ _______ _______________ ___ ______ _____________ ______