Commit Graph

141 Commits

Author SHA1 Message Date
Anuraag Agrawal 55ff1dc533
Promote metrics API to stable (#3919)
* Add MeterProvider to OpenTelemetry API

* Spot

* Set

* Move NoopMeter to package private

* Merge metrics API code into API package

* Finish

* Fix / clean

* Drift

* Update extensions/noop-api/src/main/java/io/opentelemetry/extension/noopapi/NoopOpenTelemetry.java

Co-authored-by: John Watson <jkwatson@gmail.com>

* Spot

Co-authored-by: John Watson <jkwatson@gmail.com>
2021-11-24 08:39:55 +09:00
Eugene R f24ee19d0b
decommission the deprecated Gradle archivesBaseName property (#3878) 2021-11-15 10:55:08 -08:00
John Watson 37b6807368
Add a kotlin annotation to assert that we know what we're doing (#3709)
Resolves #3654
2021-10-08 08:44:42 +09:00
Anuraag Agrawal 5320f208cb
Fix nullness in trace-propagators (#3656) 2021-09-24 09:15:04 -07:00
John Watson 5b0622a698
Update some dependencies (#3628) 2021-09-17 11:08:13 +09:00
Anuraag Agrawal 98fdf9b4bc
Move ConfigProperties / ConfigurationException to SPI package and consistently pass ConfigProperties (#3558) 2021-08-31 12:55:36 +09:00
Anuraag Agrawal 6ef3091cfb
Copy in spotless-conventions from instrumentation repo (#3554)
* Copy in spotless-conventions from instrumentation repo.

* Reformat

* A few more dotfiles
2021-08-27 08:28:31 -07:00
jack-berg 58c16a9133
Add missing readmes and missing javadoc links (#3500) 2021-08-16 12:36:54 -07:00
jack-berg dd84ccaec7
Fix javadoc (#3499)
* Add javadoc links for otlp-http modules

* Fix otlp module javadoc links

* Fix logging exporter javadoc link

* Fix jaeger exporters javadoc links

* Fix prometheus exporter javadoc link

* Fix zipkin exporter javadoc link

* Fix extension annotations javadoc link

* Fix extension trace propagators javadoc links

* Fix sdk-extensions aws javadoc link

* Fix sdk-extensions async-processor javadoc links
2021-08-16 10:35:42 -07:00
Trask Stalnaker 60c3c5ca0c
Format build.gradle.kts files (#3427) 2021-07-29 13:21:38 +09:00
Anuraag Agrawal ce9c8854c7
Extract publishing and animalsniffer plugins. (#3334) 2021-06-22 08:23:16 +09:00
Anuraag Agrawal 864508983e
Extract JMH conventions plugin. (#3324) 2021-06-17 08:37:49 -07:00
Anuraag Agrawal 7f544416e4
Define an extension for otel-specific configuration of Java. (#3317) 2021-06-17 15:54:25 +09:00
Anuraag Agrawal b9ca09b6c1
Extract java conventions plugin. (#3316) 2021-06-15 12:29:47 -07:00
HaloFour 870f721bbf
Add @SpanAttribute annotation for adding attributes to spans created through instrumentation (#3168)
* Add WithSpanAttribute annotation for adding attributes to spans created through instrumentation

* Fix warning on invalid parameter due to suspected name mismatch

* Add javadoc comment about formal parameter names

* Address PR comments, change name to SpanAttribute

* Reference Span.currentSpan().setAttribute() in the javadocs

* Fix Javadoc copypasta based on PR feedback

* Add @since to javadoc on SpanAttribute

* Bump javadoc since to version 1.4
2021-06-11 11:16:16 +09:00
Anuraag Agrawal 39ec5bae65
Use autoconfigure SPI for trace-propagators extension. (#3294)
* Use autoconfigure SPI for trace-propagators extension.

* final
2021-06-08 09:01:00 +09:00
Anuraag Agrawal 31d87b1cc8
Add a prototype PassThroughPropagator (#3256)
* Add a prototype PassThroughPropagator

* Add benchmark

* final

* Optimize empty

* Reorder
2021-05-28 10:54:45 +09:00
Anuraag Agrawal b120b643af
Fix javadoc for AwsXrayPropagator (#3251) 2021-05-25 07:47:34 -07:00
Anuraag Agrawal cb77a8d364
Move TemporaryBuffers to internal and use it everywhere. (#3226)
* Move TemporaryBuffers to internal and use it everywhere.

* blurb
2021-05-13 11:18:50 +09:00
Anuraag Agrawal 9a602e7df8
Add a truly no-op OpenTelemetry API as an extension. (#3204)
* Add a truly no-op OpenTelemetry API as an extension.

* checkstyle

* Name
2021-05-13 11:10:04 +09:00
Anuraag Agrawal 672330bf51
Upgrade to Gradle 7.0 (#3228) 2021-05-13 08:21:22 +09:00
Anuraag Agrawal 77f0b0adc4
Allow enabling nullaway and fix some nullness issues (#3218)
* Add support for enabling nullaway and fix a couple of projects.

* Finish

* Finish

* Cleanup
2021-05-12 08:43:32 +09:00
John Watson a8a85c6129
Add tests and update behavior to verify propagators do not alter the … (#3194)
* Add tests and update behavior to verify propagators do not alter the context when failing to parse inputs.

* Ad a couple tests around null contexts

* formatting
2021-05-07 08:58:42 +09:00
John Watson fb9cb2239e
Have the B3Propagator only include the relevant fields for injection format. (#3154)
See this spec change from v1.2.0: https://github.com/open-telemetry/opentelemetry-specification/pull/1570
2021-04-15 08:53:02 +09:00
Anuraag Agrawal 768bde8f0a
Map x-ray key/value pairs to baggage. (#3106)
* Map x-ray key/value pairs to baggage.

* Ignore known keys in baggage

* 256 char limit
2021-04-07 13:17:50 +09:00
Jakub Wach 71ad8ff646
X-Ray traceid extraction - 64bit support (#3087)
* X-Ray traceid extraction - 64bit support

* perf improvement - separate methods depending on traceid length

* code review

* code review - scare-comment for internal util

* added new unit tests

* Update api/all/src/main/java/io/opentelemetry/api/internal/StringUtils.java

Co-authored-by: Anuraag Agrawal <anuraaga@gmail.com>
2021-04-02 17:52:07 +09:00
John Watson aac9284f83
Add a new module for extensions to the tracing APIs. (#2962)
* Add a new module for extensions to the tracing APIs.
Includes one simple possible example.

* formatting

* rename and add javadoc

* Clean up & simplify based on feedback

* rename the module to just incubator

* Move to a package named more like the core api trace package.

* repackage to match the module
2021-03-17 18:53:38 -07:00
Anuraag Agrawal f05a8c4792
Fix unit test for kotlin context propagation. (#3012)
* Fix unit test for kotlin context propagation.

* Add coroutineScope invocation too

* More examples
2021-03-11 10:41:48 -08:00
Anuraag Agrawal 18df74eb19
Don't throw on null in propagator implementations. (#2904)
* Don't throw on null in propagator implementations.

* Baggage too
2021-02-24 09:28:16 -08:00
Bogdan Drutu 013643c707
Add package-info for all packages (#2902)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-21 10:44:00 -08:00
Bogdan Drutu e60b8101d1
[Breaking Change] Remove B3Propagator.Builder, add static methods to access possible instances (#2863)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-18 12:40:48 +09:00
Bogdan Drutu 41090fdd60
Mark public classes as final in extensions/aws (#2854)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-17 12:43:34 -08:00
Anuraag Agrawal 4623334c7c
Move Getter/Setter to top level (#2840) 2021-02-17 09:46:56 -08:00
John Watson f83c21638a
[Breaking Change] Rename TraceStateBuilder.set() to put() (#2830)
Provisionally resolves #2746
2021-02-17 08:16:24 -08:00
Anuraag Agrawal 900c35ed8c
Migrate remaining gradle scripts to kotlin (#2820)
* Migrate remaining gradle scripts to kotlin

* Finish more
2021-02-16 14:11:07 -08:00
Anuraag Agrawal 74fed3ec13
Make kotlin stdlib dependencies compileOnly since a user will bring them in. (#2793) 2021-02-10 10:38:56 -08:00
Anuraag Agrawal 0385f6d79b
Make StrictContextStorage package-private (#2772) 2021-02-08 19:03:35 -08:00
Anuraag Agrawal 4670252e20
Move AwsXrayPropagator to extension artifact. (#2771) 2021-02-09 11:36:58 +09:00
John Watson d34b66b5cb
Validate the span id and trace id when creating the SpanContext (#2728)
And, remove that extra validation from propagators.
2021-02-08 08:03:33 -08:00
Carlos Alberto Cortez 73d17911e4
Rename OtTracerPropagator to OtTracePropagator. (#2718)
* Rename OtTracerPropagator to OtTracePropagator.

* fix

Co-authored-by: Anuraag Agrawal <aanuraag@amazon.co.jp>
2021-02-08 18:23:01 +09:00
John Watson eb529cb26d
Revert the SpanContext trace/span id accessor methods. (#2749) 2021-02-08 09:51:49 +09:00
Bogdan Drutu e187c18112
Consistent name for Trace/Span ids getters with the specification (#2721)
See https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/api.md#retrieving-the-traceid-and-spanid

Not breaking change since methods were just renamed anyway.

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-05 20:33:32 -08:00
Bogdan Drutu d932baa919
Remove trivial usage of fromLong[s] methods (#2730)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-05 20:28:00 -08:00
Bogdan Drutu 5f155f1495
Small cleanups in the propagators extension (#2717)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-05 12:13:09 -08:00
Bogdan Drutu 6c30f411f3
Change TraceFlags to be a class, expose all helpers of the class itself. (#2709)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-05 09:06:19 -08:00
Bogdan Drutu 77d993d653
[BREAKING CHANGE] Cleanup TraceId/SpanId classes. Ensure consistency. (#2696)
Summary of changes:
* getHexLength renamed to getLength
* bytesFromHex/bytesToHex renamed to asBytes/fromBytes.
* bytesFromHex/bytesToHex renamed to asLongHigh/asLongLow
* Update javadoc.

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-04 07:38:25 -08:00
Bogdan Drutu 0b250c1c91
Cleanup usages of TraceState and TraceFalgs (#2697)
* Avoid calling TraceState.builder().build() and replace it with TraceState.getDefault();
* Avoid storing TraceFalgs.getDefault() and TraceFalgs.getSampler() and use them directly;

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-03 18:39:52 -08:00
Bogdan Drutu 88e760d01c
[BREAKING CHANGE] Remove AsHexString suffix from ids getters. (#2684)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-03 10:40:43 -08:00
Bogdan Drutu 5cb09fbb73
Change Baggage.forEach to map other forEach methods, same generics asMap (#2674)
* Removes one custom interface and uses BiConsumer as all the other places.
* Builder no longer needs to create new objects from parent and can reshare them.

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-03 08:51:52 -08:00
Bogdan Drutu d83c29f871
[BREAKING CHANGE] Remove bytes size from TraceId/SpanId (#2685)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-02-03 07:41:55 -08:00