Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add documentation on the OTel Spring Boot starter #3377

Merged
merged 29 commits into from
Nov 14, 2023
Merged
Show file tree
Hide file tree
Changes from 26 commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
10c7b16
Add documentation on the OTel Spring Boot starter
jeanbisutti Oct 13, 2023
faa7316
Add documentation on the OTel Spring Boot starter
jeanbisutti Oct 13, 2023
d41a530
Update springboot.md
jeanbisutti Oct 13, 2023
bce8bf3
Update springboot.md
jeanbisutti Oct 13, 2023
c497301
Update springboot.md
jeanbisutti Oct 16, 2023
1acf4d6
Update content/en/docs/instrumentation/java/springboot.md
jeanbisutti Oct 23, 2023
6ad2292
Update content/en/docs/instrumentation/java/springboot.md
jeanbisutti Oct 23, 2023
5baa390
Properly manage dependency version
jeanbisutti Oct 24, 2023
aac530d
Add clarifications
jeanbisutti Oct 27, 2023
2d7202b
Remove line break
jeanbisutti Oct 27, 2023
9d8d938
Fix typo
jeanbisutti Oct 27, 2023
a8e3f51
Update content/en/docs/instrumentation/java/springboot.md
jeanbisutti Nov 13, 2023
ae8553d
Update content/en/docs/instrumentation/java/springboot.md
jeanbisutti Nov 13, 2023
199823b
Update content/en/docs/instrumentation/java/springboot.md
jeanbisutti Nov 13, 2023
2b6761e
Rename springboot.md to spring-boot.md
jeanbisutti Nov 13, 2023
4a59674
Move the spring-boot.md file to the automatic folder
jeanbisutti Nov 13, 2023
1c63a79
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
a39b3db
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
4d30dde
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
1dc25cb
Align the Gradle example with other examples on https://opentelemetry…
jeanbisutti Nov 14, 2023
456bb91
Use tabs
jeanbisutti Nov 14, 2023
6f8d5de
fix:format & fix:refcache
chalin Nov 14, 2023
743f2ac
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
8c82d25
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
57bf764
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
ae886e7
Update content/en/docs/instrumentation/java/automatic/spring-boot.md
jeanbisutti Nov 14, 2023
30fd730
fixes
svrnm Nov 14, 2023
1e99283
Merge branch 'main' into otel-starter-doc
svrnm Nov 14, 2023
00d988f
Merge branch 'main' into otel-starter-doc
svrnm Nov 14, 2023
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
58 changes: 58 additions & 0 deletions content/en/docs/instrumentation/java/automatic/spring-boot.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
title: Spring Boot
linkTitle: Spring Boot
weight: 30
description: Spring instrumentation for OpenTelemetry Java
cSpell:ignore: springboot autoconfigure
---

You can use the [OpenTelemetry Java agent](..) with byte code instrumentation to
automatically instrument a [Spring Boot](https://spring.io/projects/spring-boot)
application; or you can also use the OpenTelemetry [Spring Boot starter] to
instrument your application.

[Spring Boot starter]:
https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#using.build-systems.starters

The OpenTelemetry starter is compatible with Spring Boot 2.0 and 3.0, and Spring
native.

## Configuration

Add the dependency given below to enable the OpenTelemetry starter.

The OpenTelemetry starter uses OpenTelemetry Spring Boot [auto-configuration].
For details concerning supported libraries and features of the OpenTelemetry
auto-configuration, see the configuration [README].

[auto-configuration]:
https://docs.spring.io/spring-boot/docs/current/reference/html/using.html#using.auto-configuration
[README]:
https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/instrumentation/spring/spring-boot-autoconfigure/README.md#features

{{< tabpane text=true >}} {{% tab header="Maven (`pom.xml`)" lang=Maven %}}

```xml
<dependencies>
<dependency>
<groupId>io.opentelemetry.instrumentation</groupId>
<artifactId>opentelemetry-spring-boot-starter</artifactId>
<version>{{% param vers.instrumentation %}}</version>
</dependency>
</dependencies>
```

{{% /tab %}} {{% tab header="Gradle (`gradle.build`)" lang=Gradle %}}

```groovy
dependencies {
implementation('io.opentelemetry.instrumentation:opentelemetry-spring-boot-starter:{{% param vers.instrumentation %}}')
}
```

{{% /tab %}} {{< /tabpane>}}

## Additional instrumentations

You can configure additional instrumentations with
[OpenTelemetry instrumentations libraries](https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/docs/supported-libraries.md#libraries--frameworks).
12 changes: 12 additions & 0 deletions static/refcache.json
Original file line number Diff line number Diff line change
Expand Up @@ -1491,6 +1491,14 @@
"StatusCode": 200,
"LastSeen": "2023-07-26T16:17:33.996008+02:00"
},
"https://docs.spring.io/spring-boot/docs/current/reference/html/using.html#using.auto-configuration": {
"StatusCode": 206,
"LastSeen": "2023-11-14T09:30:48.194902-05:00"
},
"https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#using.build-systems.starters": {
"StatusCode": 200,
"LastSeen": "2023-11-14T09:30:42.69906-05:00"
},
"https://docs.teletrace.io/": {
"StatusCode": 206,
"LastSeen": "2023-06-30T09:15:08.305928-04:00"
Expand Down Expand Up @@ -5391,6 +5399,10 @@
"StatusCode": 200,
"LastSeen": "2023-06-30T11:44:31.406627-04:00"
},
"https://spring.io/projects/spring-boot": {
"StatusCode": 200,
"LastSeen": "2023-11-14T09:30:36.981189-05:00"
},
"https://square.github.io/okhttp/": {
"StatusCode": 206,
"LastSeen": "2023-09-14T09:36:37.578867-05:00"
Expand Down
Loading