Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 0 additions & 19 deletions buildSrc/src/main/java/Config.kt
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ object Config {
val springBoot3StarterSecurity = "org.springframework.boot:spring-boot-starter-security:$springBoot3Version"
val springBoot3StarterJdbc = "org.springframework.boot:spring-boot-starter-jdbc:$springBoot3Version"
val springBoot3StarterActuator = "org.springframework.boot:spring-boot-starter-actuator:$springBoot3Version"
val springBoot3StarterOpenTelemetry = "io.opentelemetry.instrumentation:opentelemetry-spring-boot-starter:${OpenTelemetry.otelInstrumentationVersion}"

val springWeb = "org.springframework:spring-webmvc"
val springWebflux = "org.springframework:spring-webflux"
Expand Down Expand Up @@ -126,24 +125,6 @@ object Config {
val apolloKotlin4 = "com.apollographql.apollo:apollo-runtime:4.1.1"

val sentryNativeNdk = "io.sentry:sentry-native-ndk:0.8.4"

object OpenTelemetry {
val otelVersion = "1.44.1"
val otelAlphaVersion = "$otelVersion-alpha"
val otelInstrumentationVersion = "2.10.0"
val otelInstrumentationAlphaVersion = "$otelInstrumentationVersion-alpha"
val otelSemanticConvetionsVersion = "1.28.0-alpha" // check https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/dependencyManagement/build.gradle.kts#L49 for release version above to find a compatible version

val otelSdk = "io.opentelemetry:opentelemetry-sdk:$otelVersion"
val otelSemconv = "io.opentelemetry.semconv:opentelemetry-semconv:$otelSemanticConvetionsVersion"
val otelSemconvIncubating = "io.opentelemetry.semconv:opentelemetry-semconv-incubating:$otelSemanticConvetionsVersion"
val otelJavaAgent = "io.opentelemetry.javaagent:opentelemetry-javaagent:$otelInstrumentationVersion"
val otelJavaAgentExtensionApi = "io.opentelemetry.javaagent:opentelemetry-javaagent-extension-api:$otelInstrumentationAlphaVersion"
val otelJavaAgentTooling = "io.opentelemetry.javaagent:opentelemetry-javaagent-tooling:$otelInstrumentationAlphaVersion"
val otelExtensionAutoconfigureSpi = "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi:$otelVersion"
val otelExtensionAutoconfigure = "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure:$otelVersion"
val otelInstrumentationBom = "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom:$otelInstrumentationVersion"
}
}

object AnnotationProcessors {
Expand Down
15 changes: 15 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ kotlin = "1.9.24"
# see https://www.jetbrains.com/help/kotlin-multiplatform-dev/compose-compatibility-and-versioning.html#kotlin-compatibility
# see https://developer.android.com/jetpack/androidx/releases/compose-kotlin
okhttp = "4.9.2"
otel = "1.44.1"
otelInstrumentation = "2.10.0"
otelInstrumentationAlpha = "2.10.0-alpha"
# check https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/dependencyManagement/build.gradle.kts#L49 for release version above to find a compatible version
otelSemanticConventions = "1.28.0-alpha"
springTwo = "2.7.18"
springThree = "3.5.0"
targetSdk = "34"
Expand Down Expand Up @@ -49,6 +54,16 @@ androidx-navigation-runtime = { module = "androidx.navigation:navigation-runtime
androidx-navigation-compose = { module = "androidx.navigation:navigation-compose", version.ref = "androidxNavigation" }
coil-compose = { module = "io.coil-kt:coil-compose", version = "2.6.0" }
kotlin-test-junit = { module = "org.jetbrains.kotlin:kotlin-test-junit", version.ref = "kotlin" }
otel = { module = "io.opentelemetry:opentelemetry-sdk", version.ref = "otel" }
otel-extension-autoconfigure = { module = "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure", version.ref = "otel" }
otel-extension-autoconfigure-spi = { module = "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi", version.ref = "otel" }
otel-instrumentation-bom = { module = "io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom", version.ref = "otelInstrumentation" }
otel-javaagent = { module = "io.opentelemetry.javaagent:opentelemetry-javaagent", version.ref = "otelInstrumentation" }
otel-javaagent-tooling = { module = "io.opentelemetry.javaagent:opentelemetry-javaagent-tooling", version.ref = "otelInstrumentationAlpha" }
otel-javaagent-extension-api = { module = "io.opentelemetry.javaagent:opentelemetry-javaagent-extension-api", version.ref = "otelInstrumentationAlpha" }
otel-semconv = { module = "io.opentelemetry.semconv:opentelemetry-semconv", version.ref = "otelSemanticConventions" }
otel-semconv-incubating = { module = "io.opentelemetry.semconv:opentelemetry-semconv-incubating", version.ref = "otelSemanticConventions" }
springboot3-otel = { module = "io.opentelemetry.instrumentation:opentelemetry-spring-boot-starter", version.ref = "otelInstrumentation" }

# test libraries
androidx-compose-ui-test-junit4 = { module = "androidx.compose.ui:ui-test-junit4", version = "1.6.8" }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ dependencies {
bootstrapLibs(projects.sentry)
bootstrapLibs(projects.sentryOpentelemetry.sentryOpentelemetryBootstrap)
javaagentLibs(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
upstreamAgent(Config.Libs.OpenTelemetry.otelJavaAgent)
upstreamAgent(libs.otel.javaagent)
}

fun isolateClasses(jars: Iterable<File>): CopySpec {
Expand Down Expand Up @@ -148,12 +148,12 @@ tasks {
attributes.put("Implementation-Vendor", "Sentry")
attributes.put("Implementation-Title", project.name)
attributes.put("Implementation-Version", project.version)
attributes.put("Sentry-Version-Name", "sentry-${project.version}-otel-${Config.Libs.OpenTelemetry.otelInstrumentationVersion}")
attributes.put("Sentry-Version-Name", "sentry-${project.version}-otel-${libs.versions.otelInstrumentation.get()}")
attributes.put("Sentry-SDK-Name", Config.Sentry.SENTRY_OPENTELEMETRY_AGENT_SDK_NAME)
attributes.put("Sentry-SDK-Package-Name", "maven:io.sentry:sentry-opentelemetry-agent")
attributes.put("Sentry-Opentelemetry-SDK-Name", Config.Sentry.SENTRY_OPENTELEMETRY_AGENT_SDK_NAME)
attributes.put("Sentry-Opentelemetry-Version-Name", Config.Libs.OpenTelemetry.otelVersion)
attributes.put("Sentry-Opentelemetry-Javaagent-Version-Name", Config.Libs.OpenTelemetry.otelInstrumentationVersion)
attributes.put("Sentry-Opentelemetry-Version-Name", libs.versions.otel.get())
attributes.put("Sentry-Opentelemetry-Javaagent-Version-Name", libs.versions.otelInstrumentation.get())
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ dependencies {
}
compileOnly(projects.sentryOpentelemetry.sentryOpentelemetryBootstrap)

compileOnly(Config.Libs.OpenTelemetry.otelSdk)
compileOnly(Config.Libs.OpenTelemetry.otelExtensionAutoconfigureSpi)
compileOnly(Config.Libs.OpenTelemetry.otelJavaAgentExtensionApi)
compileOnly(Config.Libs.OpenTelemetry.otelJavaAgentTooling)
compileOnly(libs.otel)
compileOnly(libs.otel.extension.autoconfigure.spi)
compileOnly(libs.otel.javaagent.extension.api)
compileOnly(libs.otel.javaagent.tooling)

compileOnly(Config.CompileOnly.nopen)
errorprone(Config.CompileOnly.nopenChecker)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,12 @@ dependencies {
api(projects.sentry)
implementation(projects.sentryOpentelemetry.sentryOpentelemetryBootstrap)
implementation(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
api(Config.Libs.OpenTelemetry.otelSdk)
api(Config.Libs.OpenTelemetry.otelSemconv)
api(Config.Libs.OpenTelemetry.otelSemconvIncubating)
api(Config.Libs.OpenTelemetry.otelExtensionAutoconfigure)
api(Config.Libs.springBoot3StarterOpenTelemetry)

api(libs.otel)
api(libs.otel.semconv)
api(libs.otel.semconv.incubating)
api(libs.otel.extension.autoconfigure)
api(libs.springboot3.otel)
}

buildConfig {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ dependencies {
api(projects.sentry)
implementation(projects.sentryOpentelemetry.sentryOpentelemetryBootstrap)
implementation(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
api(Config.Libs.OpenTelemetry.otelSdk)
api(Config.Libs.OpenTelemetry.otelSemconv)
api(Config.Libs.OpenTelemetry.otelSemconvIncubating)
api(Config.Libs.OpenTelemetry.otelExtensionAutoconfigure)
api(libs.otel)
api(libs.otel.semconv)
api(libs.otel.semconv.incubating)
api(libs.otel.extension.autoconfigure)
}

buildConfig {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ tasks.withType<KotlinCompile>().configureEach {
dependencies {
compileOnly(projects.sentry)

compileOnly(Config.Libs.OpenTelemetry.otelSdk)
compileOnly(libs.otel)

compileOnly(Config.CompileOnly.nopen)
errorprone(Config.CompileOnly.nopenChecker)
Expand All @@ -31,9 +31,9 @@ dependencies {
testImplementation(libs.kotlin.test.junit)
testImplementation(libs.mockito.kotlin)

testImplementation(Config.Libs.OpenTelemetry.otelSdk)
testImplementation(Config.Libs.OpenTelemetry.otelSemconv)
testImplementation(Config.Libs.OpenTelemetry.otelSemconvIncubating)
testImplementation(libs.otel)
testImplementation(libs.otel.semconv)
testImplementation(libs.otel.semconv.incubating)
}

configure<SourceSetContainer> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ dependencies {
*/
compileOnly(projects.sentryOpentelemetry.sentryOpentelemetryBootstrap)

implementation(Config.Libs.OpenTelemetry.otelSdk)
compileOnly(Config.Libs.OpenTelemetry.otelSemconv)
compileOnly(Config.Libs.OpenTelemetry.otelSemconvIncubating)
implementation(libs.otel)
compileOnly(libs.otel.semconv)
compileOnly(libs.otel.semconv.incubating)

compileOnly(Config.CompileOnly.nopen)
errorprone(Config.CompileOnly.nopenChecker)
Expand All @@ -40,9 +40,9 @@ dependencies {
testImplementation(libs.kotlin.test.junit)
testImplementation(libs.mockito.kotlin)

testImplementation(Config.Libs.OpenTelemetry.otelSdk)
testImplementation(Config.Libs.OpenTelemetry.otelSemconv)
testImplementation(Config.Libs.OpenTelemetry.otelSemconvIncubating)
testImplementation(libs.otel)
testImplementation(libs.otel.semconv)
testImplementation(libs.otel.semconv.incubating)
}

configure<SourceSetContainer> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ dependencies {

dependencyManagement {
imports {
mavenBom(Config.Libs.OpenTelemetry.otelInstrumentationBom)
mavenBom(libs.otel.instrumentation.bom.get().toString())
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ dependencies {
implementation(projects.sentryLogback)
implementation(projects.sentryGraphql22)
implementation(projects.sentryQuartz)
implementation(Config.Libs.OpenTelemetry.otelSdk)
implementation(libs.otel)

// database query tracing
implementation(projects.sentryJdbc)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ dependencies {

dependencyManagement {
imports {
mavenBom(Config.Libs.OpenTelemetry.otelInstrumentationBom)
mavenBom(libs.otel.instrumentation.bom.get().toString())
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ dependencies {
implementation(projects.sentryLogback)
implementation(projects.sentryGraphql)
implementation(projects.sentryQuartz)
implementation(Config.Libs.OpenTelemetry.otelSdk)
implementation(libs.otel)

// database query tracing
implementation(projects.sentryJdbc)
Expand Down
8 changes: 4 additions & 4 deletions sentry-spring-boot-jakarta/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ dependencies {
compileOnly(Config.Libs.springBoot3StarterQuartz)
compileOnly(Config.Libs.reactorCore)
compileOnly(Config.Libs.contextPropagation)
compileOnly(Config.Libs.OpenTelemetry.otelSdk)
compileOnly(libs.otel)
compileOnly(projects.sentryOpentelemetry.sentryOpentelemetryCore)
compileOnly(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
api(projects.sentryReactor)
Expand Down Expand Up @@ -79,9 +79,9 @@ dependencies {
testImplementation(Config.Libs.springBoot3StarterQuartz)
testImplementation(Config.Libs.springBoot3StarterGraphql)
testImplementation(Config.Libs.contextPropagation)
testImplementation(Config.Libs.OpenTelemetry.otelSdk)
testImplementation(Config.Libs.OpenTelemetry.otelExtensionAutoconfigureSpi)
testImplementation(Config.Libs.springBoot3StarterOpenTelemetry)
testImplementation(libs.otel)
testImplementation(libs.otel.extension.autoconfigure.spi)
testImplementation(libs.springboot3.otel)
testImplementation(projects.sentryOpentelemetry.sentryOpentelemetryCore)
testImplementation(projects.sentryOpentelemetry.sentryOpentelemetryAgent)
testImplementation(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
Expand Down
6 changes: 3 additions & 3 deletions sentry-spring-boot/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ dependencies {
testImplementation(Config.Libs.springBootStarterSecurity)
testImplementation(Config.Libs.springBootStarterAop)
testImplementation(Config.Libs.springBootStarterQuartz)
testImplementation(Config.Libs.OpenTelemetry.otelSdk)
testImplementation(Config.Libs.OpenTelemetry.otelExtensionAutoconfigureSpi)
testImplementation(Config.Libs.springBoot3StarterOpenTelemetry)
testImplementation(libs.otel)
testImplementation(libs.otel.extension.autoconfigure.spi)
testImplementation(libs.springboot3.otel)
testImplementation(projects.sentryOpentelemetry.sentryOpentelemetryCore)
testImplementation(projects.sentryOpentelemetry.sentryOpentelemetryAgent)
testImplementation(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
Expand Down
2 changes: 1 addition & 1 deletion sentry-spring-jakarta/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ dependencies {
compileOnly(Config.Libs.servletApiJakarta)
compileOnly(Config.Libs.slf4jApi)
compileOnly(Config.Libs.contextPropagation)
compileOnly(Config.Libs.OpenTelemetry.otelSdk)
compileOnly(libs.otel)

compileOnly(Config.Libs.springWebflux)

Expand Down
2 changes: 1 addition & 1 deletion sentry-spring/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ dependencies {
compileOnly(projects.sentryGraphql)
compileOnly(Config.Libs.springBootStarterQuartz)
compileOnly(projects.sentryQuartz)
compileOnly(Config.Libs.OpenTelemetry.otelSdk)
compileOnly(libs.otel)
compileOnly(projects.sentryOpentelemetry.sentryOpentelemetryAgentcustomization)
compileOnly(projects.sentryOpentelemetry.sentryOpentelemetryBootstrap)

Expand Down
Loading