OTel Spring starter update from 2.6.0 (#4842)

Co-authored-by: opentelemetrybot <107717825+opentelemetrybot@users.noreply.github.com>
Co-authored-by: Severin Neumann <neumanns@cisco.com>
This commit is contained in:
Jean Bisutti 2024-07-17 13:48:57 +02:00 committed by GitHub
parent 533f1f5ef0
commit 471c572b4a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 20 deletions

View File

@ -50,8 +50,8 @@ The following example shows how to import the OpenTelemetry BOMs using Maven:
</dependency>
<dependency>
<groupId>io.opentelemetry.instrumentation</groupId>
<artifactId>opentelemetry-instrumentation-bom-alpha</artifactId>
<version>{{% param vers.instrumentation %}}-alpha</version>
<artifactId>opentelemetry-instrumentation-bom</artifactId>
<version>{{% param vers.instrumentation %}}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
@ -74,7 +74,7 @@ plugins {
dependencies {
implementation(platform(SpringBootPlugin.BOM_COORDINATES))
implementation(platform("io.opentelemetry:opentelemetry-bom:{{% param vers.otel %}}"))
implementation(platform("io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:{{% param vers.instrumentation %}}-alpha"))
implementation(platform("io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom:{{% param vers.instrumentation %}}"))
}
```
@ -91,7 +91,7 @@ plugins {
dependencyManagement {
imports {
mavenBom("io.opentelemetry:opentelemetry-bom:{{% param vers.otel %}}")
mavenBom("io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:{{% param vers.instrumentation %}}-alpha")
mavenBom("io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:{{% param vers.instrumentation %}}")
}
}
```

View File

@ -5,22 +5,7 @@ weight: 70
---
Instead of using the OpenTelemetry Spring starter, you can use the OpenTelemetry
autoconfiguration features with an annotation or the Zipkin starter.
## Spring support
Autoconfiguration is natively supported by Spring Boot applications. To enable
these features in "vanilla" use `@EnableOpenTelemetry` to complete a component
scan of this package.
```java
import io.opentelemetry.instrumentation.spring.autoconfigure.EnableOpenTelemetry;
import org.springframework.context.annotation.Configuration;
@Configuration
@EnableOpenTelemetry
public class OpenTelemetryConfig {}
```
Zipkin starter.
## Zipkin starter