Commit Graph

24 Commits

Author SHA1 Message Date
Martin ac91dc090a
Type annotation placement (#4406)
* switch annotation `org.checkerframework.checker.nullness.qual.Nullable` to `javax.annotation.Nullable`

* code format
2021-10-17 17:38:43 -07:00
Mateusz Rzeszutek b2bc41453b
Rename some *InstrumenterBuilder classes to *InstrumenterFactory (#4391) 2021-10-15 14:47:32 +03:00
Lauri Tulmin 0cfc71c3c6
Support kafka streams 3 (#4236)
* Support kafka streams 3

* make thread local wider so it would work on all kafka-streams versions

* Move classes used by multiple instrumentations into bootstrap module to ensure that everybody uses the same copy of them

* spotless

* allow project as muzzle extra dependency

* add comment

* fix merge
2021-10-05 09:43:00 -07:00
Mateusz Rzeszutek 300e7dab7e
Move all Kafka library instrumenter parts to internal package (#4284) 2021-10-04 19:03:15 +02:00
Lauri Tulmin ce241d2bb3
Fix flaky kafka test (#4272) 2021-10-03 10:15:24 -07:00
Aleš Justin ff0bf0a8f3
Add support for Kafka consumer and producer interceptors. (#4065)
* Add support for Kafka consumer and producer interceptors, move common Kafka code to library module.

* Apply feedback

* Apply feedback, #3.

* Apply feedback, #4.

* Add producer / consumer wrappers.

* Move to kafka-clients-2.6.

* Apply feedback #5.

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2021-10-02 11:27:57 -07:00
Mateusz Rzeszutek c11b96e4d0
Make it possible to use InstrumentationContext (now VirtualField) fro… (#4218)
* Make it possible to use InstrumentationContext (now VirtualField) from library instrumentation

* fix tests

* fix javadocs

* fix some more tests

* code review comments

* setIfNull, computeIfNull
2021-10-01 11:13:11 +02:00
Trask Stalnaker 3ce940548c
Experimental option to suppress messaging receive spans (#4187)
* Experimental option to suppress messaging receive spans

* Kafka streams too

* Better conditionals

* Remove oops

* Extract base class for kafka streams tests

* Spotless
2021-09-22 21:50:05 -07:00
Mateusz Rzeszutek 085066edb3
Add some testcontainers dependencies to dependencyManagement dep set (#4185) 2021-09-22 14:53:45 -07:00
Mateusz Rzeszutek a66452eb2d
Fix kafka tests failing when consumer is not yet subscribed to topic (#4189) 2021-09-22 11:45:32 -07:00
Mateusz Rzeszutek 12d60b05d7
Rewrite kafka-clients and kafka-streams tests to use testcontainers (#4178)
* Rewrite kafka-clients and kafka-streams tests to use testcontainers

* codenarc
2021-09-21 17:47:16 +02:00
Mateusz Rzeszutek 1a6294e1be
Make CONSUMER receive span a parent of CONSUMER process spans in kafka-streams (#4151) 2021-09-17 19:17:00 -07:00
Mateusz Rzeszutek f14eeb0f15
Convert kafka-streams to Instrumenter API (#4140) 2021-09-17 09:41:13 +02:00
Mateusz Rzeszutek 836491ef5f
Make CONSUMER receive span a parent of CONSUMER process spans in Kafka… (#4122)
* Make CONSUMER receive span a parent of CONSUMER process spans in Kafka instrumentations

* Fix kafka-streams tests

* fixed imports order
2021-09-15 10:39:56 -07:00
Matthew Ho 6967484a97
Update groovy import order to match default IntelliJ (#1708) (#4047)
* Update groovy import order to match default IntelliJ (#1708)

* organized imports for .groovy files to follow default IntelliJ import settings

* updated intellij-setup.md

* Spotless

* drift

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2021-09-11 11:53:08 -07:00
Mateusz Rzeszutek 05d1a4a54f
Separate suppression strategies for CONSUMER receive/process spans (#4076)
* Separate suppression strategies for CONSUMER receive/process spans

* Update instrumentation-api/src/main/java/io/opentelemetry/instrumentation/api/instrumenter/SpanKeyExtractor.java

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>

* spotless

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2021-09-10 10:55:50 -07:00
Lauri Tulmin a279b7d5be
Fix build (#4070) 2021-09-08 16:40:31 -07:00
Mateusz Rzeszutek e30b082259
Start a CONSUMER span for Kafka poll(); and refactor spring-kafka... (#4041)
* Start a separate CONSUMER receive span for each non-empty KafkaConsumer#poll() call

* One batch receive + one batch process span in spring-kafka

* Add CONSUMER receive spans to kafka-streams too

* codenarc

* code review comments
2021-09-08 13:12:58 -07:00
Mateusz Rzeszutek 4820ec4855
Add error parameter to EndTimeExtractor and AttributesExtractor#onEnd() (#3988) 2021-09-08 07:58:13 -07:00
Mateusz Rzeszutek 4567bc0c2f
Instrument spring-kafka batch message listeners (#3922)
* Instrument spring-kafka batch message listeners

* Update instrumentation-api/src/main/java/io/opentelemetry/instrumentation/api/instrumenter/InstrumenterBuilder.java

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>

* fix compilation failure

* Suppress nested CONSUMER spans

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
2021-08-27 08:02:37 -07:00
Trask Stalnaker dc2442ce75
Remove unnecessary parameter (#3955) 2021-08-25 21:51:12 -07:00
Mateusz Rzeszutek 21f178b7bd
Refactor kafka-clients to use Instrumenter API (#3883) 2021-08-25 10:47:39 -07:00
Mateusz Rzeszutek 5c71d28ed7
Remove deprecated Config methods (#3908) 2021-08-23 16:44:54 -07:00
Mateusz Rzeszutek 88be2940eb
Extract common consumer-related kafka-clients parts to a new module (#3817) 2021-08-13 20:28:25 -07:00