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
When upgrading the opentelemetry-spring-boot-starter dependency to version 2.13.0 or later in a Spring Boot 2.7.x project running on Java 11, the build fails with a dependency resolution error. This issue does not occur in versions prior to 2.13.0 (e.g., 2.12.0).
This issue appears to have been introduced due to the addition of opentelemetry-runtime-telemetry-java17 dependency in spring-boot-autoconfigure.
Since there was no mention in the release notes about not supporting Java versions below 17, I’ve filed this issue to highlight the unexpected behavior.
Use java 11, spring boot 2.7.18, opentelemetry-spring-boot-starter 2.13.0
./gradlew clean dependencies --configuration runtimeClasspath or ./gradlew build
Expected behavior
The build should complete successfully, resolving all dependencies compatible with Java 11.
Actual behavior
The build fails with the following error:
Execution failed for task ':bootJarMainClassName'.
> Could not resolve all files for configuration ':runtimeClasspath'.
> Could not resolve io.opentelemetry.instrumentation:opentelemetry-runtime-telemetry-java17:2.13.1-alpha.
Required by:
root project : > io.opentelemetry.instrumentation:opentelemetry-spring-boot-starter:2.13.1 > io.opentelemetry.instrumentation:opentelemetry-spring-boot-autoconfigure:2.13.1
> Dependency resolution is looking for a library compatible with JVM runtime version 11, but 'io.opentelemetry.instrumentation:opentelemetry-runtime-telemetry-java17:2.13.1-alpha' is only compatible with JVM runtime version 17 or newer.
This indicates that the transitive dependency opentelemetry-runtime-telemetry-java17 is specific to Java 17 and incompatible with Java 11.
Javaagent or library instrumentation version
library 2.13.0+
Environment
Spring Boot Version: 2.7.18
Java Version: 11
OpenTelemetry Spring Boot Starter Version: 2.13.0+
Build Tool: Gradle
Additional context
If this is intended behavior, it would be beneficial to add this information to the release notes or documentation to clarify the Java 17 requirement.
The text was updated successfully, but these errors were encountered:
KimDoubleB
changed the title
OpenTelemetry Spring Boot Starter 2.13.0+ Causes Dependency Resolution Failure with Java 11
Spring boot starter 2.13.0+ causes dependency resolution failure with Java 11
Feb 24, 2025
Describe the bug
When upgrading the opentelemetry-spring-boot-starter dependency to version 2.13.0 or later in a Spring Boot 2.7.x project running on Java 11, the build fails with a dependency resolution error. This issue does not occur in versions prior to 2.13.0 (e.g., 2.12.0).
This issue appears to have been introduced due to the addition of
opentelemetry-runtime-telemetry-java17
dependency inspring-boot-autoconfigure
.opentelemetry-java-instrumentation/instrumentation/spring/spring-boot-autoconfigure/build.gradle.kts
Lines 56 to 57 in 9101f03
Since there was no mention in the release notes about not supporting Java versions below 17, I’ve filed this issue to highlight the unexpected behavior.
Steps to reproduce
Ref: https://github.com/KimDoubleB/spring-learning/tree/issue/java11/opentelemetry/issue-demo
./gradlew clean dependencies --configuration runtimeClasspath
or./gradlew build
Expected behavior
The build should complete successfully, resolving all dependencies compatible with Java 11.
Actual behavior
The build fails with the following error:
This indicates that the transitive dependency opentelemetry-runtime-telemetry-java17 is specific to Java 17 and incompatible with Java 11.
Javaagent or library instrumentation version
library 2.13.0+
Environment
Additional context
If this is intended behavior, it would be beneficial to add this information to the release notes or documentation to clarify the Java 17 requirement.
The text was updated successfully, but these errors were encountered: