Commit Graph

235 Commits

Author SHA1 Message Date
Gregor Zeitlinger 272258290f
improve tests for RestTemplate (#11053)
Co-authored-by: Lauri Tulmin <tulmin@gmail.com>
2024-04-11 07:30:15 -07:00
Gregor Zeitlinger e175df814c
logging exporter was renamed to console in 1.37 (#11100) 2024-04-11 07:26:19 -07:00
Lauri Tulmin 9efbec6fd5
Replace messaging.kafka.destination.partition with messaging.destination.partition.id (#11086) 2024-04-11 09:16:50 +03:00
SylvainJuge 955470a63a
Semconv 1.25.0 migration (#10983)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-09 11:25:52 -07:00
Gregor Zeitlinger 19b65c062e
make spring boot honor the standard environment variables for maps (#11000) 2024-04-08 11:33:05 -07:00
Gregor Zeitlinger 3839342e3b
move spring resources to javaagent directory (#10813) 2024-03-14 08:27:19 -07:00
Gregor Zeitlinger b7e847c4f1
Spring use sdk autoconfig (#10453) 2024-03-13 07:41:47 -07:00
Lauri Tulmin fa5548b9a5
Fix spring boot starter failing without logback (#10802) 2024-03-12 10:01:45 +02:00
Gregor Zeitlinger c73bf8eadf
Fix native tests (#10685)
Co-authored-by: Jean Bisutti <jean.bisutti@gmail.com>
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
Co-authored-by: Lauri Tulmin <tulmin@gmail.com>
2024-02-28 19:08:07 -08:00
Jean Bisutti edf64c5b31
Ability to disable the automatic Logback appender addition (#10629) 2024-02-26 15:22:08 +02:00
Gregor Zeitlinger 4ed5adeb17
don't fail spring application startup if sdk is disabled (#10602) 2024-02-22 14:16:09 +02:00
Gregor Zeitlinger 1cd768e294
spring boot starter: add service.version detection, improve service.name detection (#10457) 2024-02-21 12:46:58 -08:00
Gregor Zeitlinger ee9cdc3800
add in starter: annotations (#10613) 2024-02-21 16:08:21 +02:00
Gregor Zeitlinger d8aa0f5b48
Remove deprecated spring properties (#10454) 2024-02-16 08:27:26 -08:00
Gregor Zeitlinger 66dd60015c
fix otel.properties in spring boot starter (#10559) 2024-02-15 12:11:11 -08:00
Lauri Tulmin 37b145b81c
Remove disabling spring-boot-autoconfigure tests on openj9 18 (#10551) 2024-02-14 08:40:24 -08:00
Gregor Zeitlinger 76ab93780e
Spring starter should support otel.propagators (#10408) 2024-02-13 10:02:07 -08:00
Jay DeLuca b43fbea416
Update Spring autoconfigure and zipkin starter readmes to link to doc site (#10531) 2024-02-13 08:32:16 -08:00
Gregor Zeitlinger 485b8f4218
use duration parser of config properties for consistency (#10512) 2024-02-13 08:30:27 -08:00
Gregor Zeitlinger d73304b078
remove support for deprecated @WithSpan annotation from spring starter (#10530) 2024-02-13 08:27:08 -08:00
Steve Rao 0a5c31193c
Deleted redundant checks (#10434) 2024-02-07 07:30:52 -08:00
Gregor Zeitlinger 29354a7ba6
add SystemOutLogRecordExporter for spring starter (#10420) 2024-02-06 07:50:27 -08:00
Gregor Zeitlinger f715a189bf
re-use sdk logic for configuring otlp exporters (#10292)
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2024-02-05 20:44:37 -08:00
Jean Bisutti 80e5bac4a4
Allow the Spring starter to configure the OTel Logback appender from system properties (#10355) 2024-02-02 17:27:58 +00:00
Gregor Zeitlinger bb8e301111
fix MapConverter bean condition (#10346) 2024-01-31 19:33:47 -08:00
Lauri Tulmin b57c1a023b
Update semconv (#10272) 2024-01-30 17:10:35 +00:00
Gregor Zeitlinger 2e5ac56213
add LoggingMetricExporterAutoConfiguration to spring factories (#10282) 2024-01-30 13:45:39 +02:00
Jean Bisutti 8825359748
Automatic addition of the OTel Logback appender by the OTel starter (#10306) 2024-01-24 08:45:13 -08:00
Gregor Zeitlinger 9c8644c874
add Spring boot distro version (#10276) 2024-01-23 10:37:04 +02:00
Gregor Zeitlinger 3b65ee1a32
add @ConditionalOnMissingBean to LoggingMetricExporter (#10283) 2024-01-19 11:33:37 +02:00
Lauri Tulmin 61e29873ee
Fix Calling shutdown() multiple times warning in spring starter (#10222) 2024-01-18 10:20:35 -08:00
Lauri Tulmin d36d7df184
Remove jaeger exporter and add api diff for 2.0.0 release (#10241) 2024-01-16 20:54:09 +02:00
Lauri Tulmin c418b14914
Don't append signal path to signal specific endpoint (#10214) 2024-01-12 09:14:37 -08:00
Jean Bisutti 32ea07c1bc
Change Spring starter default otlp protocol from gRPC to http/protobuf (#10212) 2024-01-11 13:09:17 -08:00
moznion c66c59a5b8
Resolve `ParameterNameDiscoverer` Bean Conflict in `spring-boot-autoconfigure` (#10105)
Signed-off-by: moznion <moznion@mail.moznion.net>
2024-01-02 14:51:07 -08:00
Lauri Tulmin 4ac62380d5
Replace OpenTelemetrySupplier with ObjectProvider<OpenTelemetry> (#10145) 2024-01-01 17:38:49 -08:00
Lauri Tulmin 04da58e5e4
Fix warnings from the spring boot starter (#10086) 2023-12-22 11:00:01 +02:00
Gregor Zeitlinger 87615cc9d9
add support for OTEL_RESOURCE_ATTRIBUTES, OTEL_SERVICE_NAME, OTEL_EXPORTER_OTLP_HEADERS and OTEL_EXPORTER_OTLP_PROTOCOL for spring boot starter (#9950) 2023-12-21 08:23:48 -08:00
Gregor Zeitlinger 3213c86784
Breaking change: disable micrometer bridge by default (#10038) 2023-12-12 11:47:55 -08:00
Jean Bisutti df8b334ccf
Fix NoSuchBeanDefinitionException with the JDBC driver configuration (#9978) 2023-12-04 11:19:02 -08:00
Mateusz Rzeszutek 65ee9510f5
Rename the `instrumentation-api-semconv` module into `instrumentation-api-incubator` (#9985) 2023-12-04 08:28:10 +01:00
Lauri Tulmin d4e6078cfe
Fix aws propagator presence check (#9924) 2023-11-22 10:03:00 +02:00
Lauri Tulmin 23b2521c43
Remove reference to tracer bean from spring boot docs (#9864) 2023-11-14 07:15:45 -08:00
Trask Stalnaker 5ba402fd2f
opentelemetry -> openTelemetry (#9858) 2023-11-14 12:31:42 +02:00
Lauri Tulmin 70e3962a87
Always set messaging operation (#9791) 2023-11-06 12:30:27 +02:00
Jean Bisutti e6ec4f52ef
Make the JDBC driver config work with the OTel starter (#9625)
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2023-10-23 09:59:36 -07:00
Trask Stalnaker 3b77cc4b2d
Semconv 1.21 (#9408)
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2023-09-13 19:20:23 +00:00
Trask Stalnaker d9f7cde77d
Remove outdated spring starter doc (#9205) 2023-08-15 16:23:16 +00:00
Mateusz Rzeszutek fd8e361e6c
Refactor Spring starter's instrumentation auto configuration classes (#8950)
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2023-07-21 11:35:41 +00:00
Trask Stalnaker 2bdddafdc4
Apply Prettier to markdown files (#8968) 2023-07-19 12:22:35 -07:00
Mateusz Rzeszutek 6f745e8f53
Include OTel appenders in the Spring Starter (#8945) 2023-07-13 12:56:56 +00:00
jason plumb 55368a52d7
Rename messaging operation "send" to "publish" per spec (#8929)
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2023-07-12 08:59:38 -07:00
Mateusz Rzeszutek 8815952300
Initialize appenders in the spring boot starter (#8888)
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2023-07-11 08:47:01 -07:00
OpenTelemetry Bot acbab58a46
Update the OpenTelemetry SDK version to 1.28.0 (#8897)
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2023-07-10 12:45:01 -07:00
OpenTelemetry Bot bbb05276be
Update the OpenTelemetry SDK version to 1.27.0 (#8688)
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2023-06-13 12:02:11 +03:00
Jean Bisutti 84a818794b
OTLP log export for the OpenTelemetry Spring Starter (#8493)
Co-authored-by: Mateusz Rzeszutek <mrzeszutek@splunk.com>
2023-06-07 17:06:34 -07:00
Mateusz Rzeszutek 2c06c00c58
Support otel.sdk.disabled in the spring boot starter (#8602) 2023-06-01 10:48:06 +02:00
Kevin Loveland 233ca9111d
feat: Added Spring's configuration annotation processor to produce th… (#8516) 2023-05-18 14:06:50 +03:00
sfriberg d1b7356ffe
AddingSpanAttributes annotation (#7787)
Co-authored-by: Mateusz Rzeszutek <mrzeszutek@splunk.com>
2023-04-24 08:58:28 -07:00
Lauri Tulmin a9fa5aacea
Add testcontainersBuildService to spring kafka tests that don't have it (#8186) 2023-03-31 10:26:06 +02:00
Lauri Tulmin d8b0771929
Use the same kafka docker image in all kafka tests (#8187)
currently we use `confluentinc/cp-kafka:5.4.3` and
`confluentinc/cp-kafka:6.1.9`
2023-03-31 10:25:38 +02:00
Lauri Tulmin 4a87d6b0fd
Remove reference to Tracer bean from javadoc (#8104) 2023-03-22 12:59:51 +01:00
Lauri Tulmin 2cbfec8ac2
Fix spring boot 3 webmvc autoconfiguration (#8051)
Related to
https://github.com/open-telemetry/opentelemetry-java-instrumentation/pull/8028#issuecomment-1466496896
spring boot 3 uses `jakarta.servlet` so we need to use
`WebMvcFilterAutoConfigurationSpring6 ` instead of
`WebMvcFilterAutoConfiguration`
2023-03-14 12:39:58 +01:00
Jean Bisutti 2bd2bbcdee
Make the Spring autoconfiguration work with Spring Boot 3 (#8028)
This PR makes the Spring autoconfiguration work from Spring Boot 2.7.

[The way to declare autoconfiguration has indeed changed from Spring
Boot
2.7](https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-2.7-Release-Notes#building-jars-with-maven-shade-plugin-and-gradle-shadow-plugin).

A workaround is to use @EnableOpenTelemetry.
2023-03-13 17:15:19 +01:00
Lauri Tulmin a793c247e6
Remove duplicate -Xmx from kafka memory options (#8022) 2023-03-09 22:02:33 +02:00
Lauri Tulmin 67b6b6cc7c
Limit kafka memory usage (#8018) 2023-03-09 16:37:09 +02:00
James Moessis 3f45f755a9
Spring Webflux Library Instrumentation (#7899)
Resolves
https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/7436

* Created new Module `spring-webflux-5.3` which contains only
server-side library instrumentation
* Minimum supported version is 5.3 because there are various problems in
older versions of reactor and webflux that prevent a few of the tests
from passing.
* Moved existing `spring-webflux-5.0` (webclient instrumentation) into a
common `spring-webflux` folder next to the 5.3 (server) instrumentation.
Moved the README to the parent folder so the docs are cohesive between
client/server instrumentation.
* Implemented `WebFilter` which instruments the server-side 
* Depends on the `reactor-3.1` instrumentation to pass the context
around. Registers the react hook when it creates the `WebFilter`
* Tests using the standard HTTP server test suite

---------

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
Co-authored-by: Mateusz Rzeszutek <mrzeszutek@splunk.com>
2023-03-08 08:43:46 +01:00
Lauri Tulmin 85c541ef92
Implement kafka client id and consumer id attributes (#7860)
Resolves
https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/7771
Adds `messaging.consumer_id` and `messaging.kafka.client_id` attributes
to kafka spans.
2023-02-21 07:31:28 -08:00
Mateusz Rzeszutek 12ea869855
Implement `messaging.kafka.*` attributes spec (part 1) (#7824)
Part 1 of #7771

It's a lot more than I initially expected it to be; I'll introduce the
clientId attribute in part 2
2023-02-16 13:22:17 -08:00
Mateusz Rzeszutek 4fd52c5a7c
Encode version in library instrumentations' package names (#7764)
Another part of #932

In this PR I changed all the library instrumentation packages -- these
are breaking changes, so I figured the earlier we do this the less
painful it'll be to the users. I know that at least some of them are
actively used, so we'll need to spell this out in the release notes.

---------

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2023-02-14 23:25:59 +00:00
OpenTelemetry Bot f074b93110
Update the OpenTelemetry SDK version to 1.23.0 (#7800)
Update the OpenTelemetry SDK version to `1.23.0`.

---------

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2023-02-13 20:22:09 +00:00
Lauri Tulmin 54d7241c05
Fix autoconfigure for spring boot 3 (#7784)
See
https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/7312
2023-02-13 10:45:23 +01:00
Mateusz Rzeszutek e1895e548c
Rename all methods in all Getters to use the `get*()` naming scheme (#7619)
Resolves #6562

This PR only contains renames; the actual content is in the `*Getter`
interfaces, the rest of changes is just IntelliJ doing its job.
2023-01-23 09:28:11 +00:00
Mateusz Rzeszutek b2f42ec3fa
Encode version in spring instrumentations' package names (#7608)
Part of #932

I wanted to get this done before starting the spring boot starter v3
work.
2023-01-19 10:03:17 +00:00
Lauri Tulmin 17e1e22072
Correct annotation name in spring-boot-autoconfigure readme (#7394) 2022-12-13 08:40:23 +01:00
Mateusz Rzeszutek ebb0141032
Populate `messaging.kafka.message.offset` in all kafka instrumentations (#7374) 2022-12-09 17:13:31 -08:00
Mateusz Rzeszutek 17b3fdb04a
Make preparations for Spring Web & WebMVC 6 instrumentations (#7343)
Just moving things around, extracting parent dir for `spring-web` and
`spring-webmvc`
2022-12-01 13:08:32 +01:00
jack-berg 94ba33e395
Use contrib AwsXrayPropagator (#7234)
Reflects move of `AwsXrayPropagator` to
[opentelemetry-java-contrib/aws-xray-propagator](https://github.com/open-telemetry/opentelemetry-java-contrib/tree/main/aws-xray-propagator).
2022-11-21 11:31:17 -08:00
Trask Stalnaker 61ed2d14db
Update SDK version (#7223)
Resolves #7221 
Resolves #7222
2022-11-18 18:13:39 +00:00
Aaron Ai 2d7395c44b
Introduce markdown lint check (#7175)
Fixes #7129
2022-11-16 20:48:42 -08:00
Trask Stalnaker 71b3e3e027
Library doc cleanup (#6948)
Related to #6947, but just cleans up the library module doc that already
existed (mostly for uniformity). Does not introduce any new doc.
2022-10-24 10:26:21 -07:00
jack-berg aeac361816
Upgrade to otel java 1.19.0 (#6757)
Working PR to capture all the changes required to update to otel java
1.19.0. The new log API force allows
`:instrumentation-appender-api-internal` and
`:instrumentation-appender-sdk-internal`, but necessitates a decent
amount of refactoring as a result.

The PR points at the `1.19.0-SNAPSHOT`, which I'll update upon
publication.

Co-authored-by: Mateusz Rzeszutek <mrzeszutek@splunk.com>
Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2022-10-12 09:19:37 -07:00
Trask Stalnaker 0d32150059
Assert on instrumentation version (#6773)
To catch issues like #6770
2022-09-29 10:53:10 +03:00
Trask Stalnaker 5224194740
Move versions to dependencyManagement (#6648)
Part of #6645
2022-09-19 12:05:06 +03:00
Lauri Tulmin 5afd6b346b
Fix spring boot @WithSpan handling (#6619) 2022-09-14 09:29:13 -07:00
Mateusz Rzeszutek f50f1fed3b
Fix instrumentation-api-semconv packages (#6590)
* Fix instrumentation-api-semconv packages

* Move test

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2022-09-12 14:51:27 -07:00
Trask Stalnaker af61a8b578
Update to otel 1.18.0 (#6575) 2022-09-11 10:35:05 -07:00
Trask Stalnaker f1774cabe2
Update net semantic convention changes (#6268)
* New net conventions: option a

* Feedback + sock.family + sock.peer.name

* peer.service + tests

* server net attributes attempt 1

* server net attributes attempt 2

* Javadoc

* Revisions

* Apply to instrumentations

* Feedback

* One more default method

* Spotless

* Fix javadoc
2022-08-18 09:02:23 -07:00
Lauri Tulmin 4605be3241
Disable crashing tests on openj9 18 (#6481) 2022-08-17 09:21:18 -07:00
Mateusz Rzeszutek 5862ace233
Tweak naming of spring autoconfigure and starter modules (#6453) 2022-08-15 22:07:08 -07:00
Trask Stalnaker faa99b2eeb
Update SDK to 1.17.0 (#6467)
* Update SDK to 1.17.0

* Fix

* Update licenses

* Spotless

* license
2022-08-12 17:10:46 -07:00
Mateusz Rzeszutek 08f013f9d6
Update gradle to 7.5.1 (#6359)
* Update gradle to 7.5

* Bump to 7.5.1

* gradle 7.5.1 with jdk17

* spotless

* one more --add-opens

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
Co-authored-by: Lauri Tulmin <ltulmin@splunk.com>
2022-08-12 12:03:43 +02:00
Trask Stalnaker 68a9f20eb3
Enable PrivateConstructorForUtilityClass errorprone check (#6427)
* PrivateConstructorForUtilityClass

* Advice

* More advice

* More

* More advice

* More

* Spotless

* Fix

* Fix

* Fix

* A better solution

* Revert

* More

* Fix

* Spotless

* Fix
2022-08-10 11:30:22 +03:00
Mateusz Rzeszutek 0d1cc8ea0a
Set http.route in spring-autoconfigure webmvc instrumentation (#6414)
* Set http.route in spring-autoconfigure webmvc instrumentation

* Bump spring-webmvc library instrumentation version to 5.3

* nit: protected -> private

* Remove duplicated test (already covered by HttpSpanStatusExtractorTest)

* Move the README to the correct module

* fix link

* fix more links

* liiiiiiinks

* fix tests

* remove not needed weakref
2022-08-09 09:36:28 -07:00
Mateusz Rzeszutek faa367395f
Fix @WithSpan in spring autoconfigure (#6398) 2022-08-02 09:37:40 +02:00
Mateusz Rzeszutek 61aef2e413
Clean up spring-boot-autoconfigure exporter logic (#6374) 2022-08-02 09:35:19 +02:00
Trask Stalnaker c3c4fb7101
Finish annotation move (#6386)
* Update tests with new annotation

* more

* Fix build

* More
2022-08-01 09:19:58 -07:00
Trask Stalnaker 9e460e28ef
Fix build (#6389) 2022-07-31 10:50:42 +03:00
Mateusz Rzeszutek 54b8b6af89
Add Kafka instrumentation to the Spring Boot starter (#6371) 2022-07-28 12:44:53 +02:00
Mateusz Rzeszutek 561ce5e3cc
Support new @WithSpan annotation in spring-boot-autoconfigure (#6378) 2022-07-28 11:48:59 +02:00