Skip to content

open-telemetry/opentelemetry-android

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Folders and files

NameName
Last commit message
Last commit date
Nov 18, 2024
Aug 12, 2024
Nov 21, 2024
Nov 19, 2024
Nov 14, 2024
Nov 18, 2024
Nov 19, 2024
Oct 28, 2024
May 7, 2024
May 17, 2024
Oct 21, 2024
Oct 28, 2024
Jul 21, 2023
Oct 21, 2024
Oct 29, 2024
Nov 21, 2023
May 29, 2024
Aug 22, 2023
Oct 30, 2024
Jul 11, 2024
Jul 11, 2024
Jul 31, 2024

Repository files navigation

OpenTelemetry Icon OpenTelemetry Android

Continuous Build Maven Central

Status: Experimental

About

The repository contains the OpenTelemetry Android SDK for generating mobile client telemetry for real user monitoring (RUM). It is built on top of the OpenTelemetry Java SDK.

Getting Started

If your project's minSdk is lower than 26, then you must enable corelib desugaring. See #73 for more information. If your project's minSdk is lower than 24, in order to run instrumentation tests or run the app built on debug, you must use AGP 8.3.0+ and set the android.useFullClasspathForDexingTransform property in gradle.properties to true to ensure desugaring runs properly. For the full context for this workaround, please see this issue.

For an overview of how to contribute, see the contributing guide in CONTRIBUTING.md.

We are also available in the #otel-android channel in the CNCF slack. Please join us there for further discussions.

Gradle

To use this android instrumentation library in your application, first add a dependency in your gradle build script:

dependencies {
    //...
    implementation("io.opentelemetry.android:android-agent:0.8.0-alpha")
    //...
}

Features

This android library builds on top of the OpenTelemetry Java SDK. Some of the additional features provided include:

  • Crash reporting
  • ANR detection
  • Network change detection
  • Full Android Activity and Fragment lifecycle monitoring
  • Access to the OpenTelemetry APIs for manual instrumentation
  • Helpers to redact any span from export, or change span attributes before export
  • Slow / frozen render detection
  • Offline buffering of telemetry via storage

Note: Use of these features is not yet well documented.

Contributing

See CONTRIBUTING.md.