From 3a6613f9a35981f1172c38853f50d6f8ba8c398b Mon Sep 17 00:00:00 2001 From: jack-berg <34418638+jack-berg@users.noreply.github.com> Date: Fri, 8 Dec 2023 13:57:04 -0600 Subject: [PATCH] Prepare for 1.33.0 release (#6065) --- CHANGELOG.md | 48 +++++++++++++++++++ .../OtlpHttpLogRecordExporterBuilder.java | 6 +++ .../OtlpHttpMetricExporterBuilder.java | 6 +++ .../trace/OtlpHttpSpanExporterBuilder.java | 6 +++ .../OtlpGrpcLogRecordExporterBuilder.java | 2 + .../OtlpGrpcMetricExporterBuilder.java | 2 + .../trace/OtlpGrpcSpanExporterBuilder.java | 2 + .../spi/AutoConfigurationCustomizer.java | 4 ++ .../testing/assertj/AbstractPointAssert.java | 6 ++- 9 files changed, 81 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c0039e5f114..ca6347b6b43 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,54 @@ ## Unreleased +### API + +* Fix issue where wrapping "invalid" SpanContexts in Span does not preserve SpanContext + ([#6044](https://github.com/open-telemetry/opentelemetry-java/pull/6044)) + +#### Incubator + +* Refactor and add to ExtendedTracer, add ExtendedContextPropagators + ([#6017](https://github.com/open-telemetry/opentelemetry-java/pull/6017)) +* Base64 encode AnyValue bytes in string representation + ([#6003](https://github.com/open-telemetry/opentelemetry-java/pull/6003)) + +### SDK + +#### Exporters + +* Add connectTimeout configuration option OtlpHttp{Signal}Exporters + ([#5941](https://github.com/open-telemetry/opentelemetry-java/pull/5941)) +* Add ability for Otlp{Protocol}LogRecordExporter to serialize log body any value + ([#5938](https://github.com/open-telemetry/opentelemetry-java/pull/5938)) +* Android environments can now handle base64 encoded PEM keys, remove exception handling in + TlsUtil#decodePem + ([#6034](https://github.com/open-telemetry/opentelemetry-java/pull/6034)) +* Add header supplier configuration option to OTLP exporters + ([#6004](https://github.com/open-telemetry/opentelemetry-java/pull/6004)) + + +#### Extensions + +* Add autoconfigure option for customizing SpanProcessor, LogRecordProcessor + ([#5986](https://github.com/open-telemetry/opentelemetry-java/pull/5986)) +* Incubator allows for simpler creation of start-only and end-only SpanProcessors. + ([#5923](https://github.com/open-telemetry/opentelemetry-java/pull/5923)) + +#### Testing + +* Add hasAttributesSatisfying overload to AbstractPointAssert + ([#6048](https://github.com/open-telemetry/opentelemetry-java/pull/6048)) + +### Project Tooling + +* Building animal sniffer signatures directly from android corelib + ([#5973](https://github.com/open-telemetry/opentelemetry-java/pull/5973)) +* Target kotlin 1.6 in kotlin extension + ([#5910](https://github.com/open-telemetry/opentelemetry-java/pull/5910)) +* Define language version compatibility requirements + ([#5983](https://github.com/open-telemetry/opentelemetry-java/pull/5983)) + ## Version 1.32.0 (2023-11-13) ### API diff --git a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/logs/OtlpHttpLogRecordExporterBuilder.java b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/logs/OtlpHttpLogRecordExporterBuilder.java index 9b8a52df9c3..59a84e76e72 100644 --- a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/logs/OtlpHttpLogRecordExporterBuilder.java +++ b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/logs/OtlpHttpLogRecordExporterBuilder.java @@ -64,6 +64,8 @@ public OtlpHttpLogRecordExporterBuilder setTimeout(Duration timeout) { /** * Sets the maximum time to wait for new connections to be established. If unset, defaults to * {@value HttpExporterBuilder#DEFAULT_CONNECT_TIMEOUT_SECS}s. + * + * @since 1.33.0 */ public OtlpHttpLogRecordExporterBuilder setConnectTimeout(long timeout, TimeUnit unit) { requireNonNull(unit, "unit"); @@ -75,6 +77,8 @@ public OtlpHttpLogRecordExporterBuilder setConnectTimeout(long timeout, TimeUnit /** * Sets the maximum time to wait for new connections to be established. If unset, defaults to * {@value HttpExporterBuilder#DEFAULT_CONNECT_TIMEOUT_SECS}s. + * + * @since 1.33.0 */ public OtlpHttpLogRecordExporterBuilder setConnectTimeout(Duration timeout) { requireNonNull(timeout, "timeout"); @@ -116,6 +120,8 @@ public OtlpHttpLogRecordExporterBuilder addHeader(String key, String value) { /** * Set the supplier of headers to add to requests. If a key from the map collides with a constant * from {@link #addHeader(String, String)}, the values from both are included. + * + * @since 1.33.0 */ public OtlpHttpLogRecordExporterBuilder setHeaders(Supplier> headerSupplier) { delegate.setHeadersSupplier(headerSupplier); diff --git a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/metrics/OtlpHttpMetricExporterBuilder.java b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/metrics/OtlpHttpMetricExporterBuilder.java index d31a510b251..5d573da557e 100644 --- a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/metrics/OtlpHttpMetricExporterBuilder.java +++ b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/metrics/OtlpHttpMetricExporterBuilder.java @@ -76,6 +76,8 @@ public OtlpHttpMetricExporterBuilder setTimeout(Duration timeout) { /** * Sets the maximum time to wait for new connections to be established. If unset, defaults to * {@value HttpExporterBuilder#DEFAULT_CONNECT_TIMEOUT_SECS}s. + * + * @since 1.33.0 */ public OtlpHttpMetricExporterBuilder setConnectTimeout(long timeout, TimeUnit unit) { requireNonNull(unit, "unit"); @@ -87,6 +89,8 @@ public OtlpHttpMetricExporterBuilder setConnectTimeout(long timeout, TimeUnit un /** * Sets the maximum time to wait for new connections to be established. If unset, defaults to * {@value HttpExporterBuilder#DEFAULT_CONNECT_TIMEOUT_SECS}s. + * + * @since 1.33.0 */ public OtlpHttpMetricExporterBuilder setConnectTimeout(Duration timeout) { requireNonNull(timeout, "timeout"); @@ -128,6 +132,8 @@ public OtlpHttpMetricExporterBuilder addHeader(String key, String value) { /** * Set the supplier of headers to add to requests. If a key from the map collides with a constant * from {@link #addHeader(String, String)}, the values from both are included. + * + * @since 1.33.0 */ public OtlpHttpMetricExporterBuilder setHeaders(Supplier> headerSupplier) { delegate.setHeadersSupplier(headerSupplier); diff --git a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/trace/OtlpHttpSpanExporterBuilder.java b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/trace/OtlpHttpSpanExporterBuilder.java index 96cf2c2a2f4..58768c98881 100644 --- a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/trace/OtlpHttpSpanExporterBuilder.java +++ b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/http/trace/OtlpHttpSpanExporterBuilder.java @@ -64,6 +64,8 @@ public OtlpHttpSpanExporterBuilder setTimeout(Duration timeout) { /** * Sets the maximum time to wait for new connections to be established. If unset, defaults to * {@value HttpExporterBuilder#DEFAULT_CONNECT_TIMEOUT_SECS}s. + * + * @since 1.33.0 */ public OtlpHttpSpanExporterBuilder setConnectTimeout(long timeout, TimeUnit unit) { requireNonNull(unit, "unit"); @@ -75,6 +77,8 @@ public OtlpHttpSpanExporterBuilder setConnectTimeout(long timeout, TimeUnit unit /** * Sets the maximum time to wait for new connections to be established. If unset, defaults to * {@value HttpExporterBuilder#DEFAULT_CONNECT_TIMEOUT_SECS}s. + * + * @since 1.33.0 */ public OtlpHttpSpanExporterBuilder setConnectTimeout(Duration timeout) { requireNonNull(timeout, "timeout"); @@ -116,6 +120,8 @@ public OtlpHttpSpanExporterBuilder addHeader(String key, String value) { /** * Set the supplier of headers to add to requests. If a key from the map collides with a constant * from {@link #addHeader(String, String)}, the values from both are included. + * + * @since 1.33.0 */ public OtlpHttpSpanExporterBuilder setHeaders(Supplier> headerSupplier) { delegate.setHeadersSupplier(headerSupplier); diff --git a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/logs/OtlpGrpcLogRecordExporterBuilder.java b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/logs/OtlpGrpcLogRecordExporterBuilder.java index 2fd6cdb5000..b04014fc729 100644 --- a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/logs/OtlpGrpcLogRecordExporterBuilder.java +++ b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/logs/OtlpGrpcLogRecordExporterBuilder.java @@ -170,6 +170,8 @@ public OtlpGrpcLogRecordExporterBuilder addHeader(String key, String value) { * Set the supplier of headers to add to requests. If a key from the map collides with a constant * from {@link #addHeader(String, String)}, the values from both are included. Applicable only if * {@link OtlpGrpcLogRecordExporterBuilder#setChannel(ManagedChannel)} is not used to set channel. + * + * @since 1.33.0 */ public OtlpGrpcLogRecordExporterBuilder setHeaders(Supplier> headerSupplier) { delegate.setHeadersSupplier(headerSupplier); diff --git a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/metrics/OtlpGrpcMetricExporterBuilder.java b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/metrics/OtlpGrpcMetricExporterBuilder.java index 00e4bcabd2e..43a0dbdcc41 100644 --- a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/metrics/OtlpGrpcMetricExporterBuilder.java +++ b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/metrics/OtlpGrpcMetricExporterBuilder.java @@ -183,6 +183,8 @@ public OtlpGrpcMetricExporterBuilder addHeader(String key, String value) { * Set the supplier of headers to add to requests. If a key from the map collides with a constant * from {@link #addHeader(String, String)}, the values from both are included. Applicable only if * {@link OtlpGrpcMetricExporterBuilder#setChannel(ManagedChannel)} is not used to set channel. + * + * @since 1.33.0 */ public OtlpGrpcMetricExporterBuilder setHeaders(Supplier> headerSupplier) { delegate.setHeadersSupplier(headerSupplier); diff --git a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/trace/OtlpGrpcSpanExporterBuilder.java b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/trace/OtlpGrpcSpanExporterBuilder.java index c3e286b5a22..884a8dea172 100644 --- a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/trace/OtlpGrpcSpanExporterBuilder.java +++ b/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/trace/OtlpGrpcSpanExporterBuilder.java @@ -167,6 +167,8 @@ public OtlpGrpcSpanExporterBuilder addHeader(String key, String value) { * Set the supplier of headers to add to requests. If a key from the map collides with a constant * from {@link #addHeader(String, String)}, the values from both are included. Applicable only if * {@link OtlpGrpcSpanExporterBuilder#setChannel(ManagedChannel)} is not used to set channel. + * + * @since 1.33.0 */ public OtlpGrpcSpanExporterBuilder setHeaders(Supplier> headerSupplier) { delegate.setHeadersSupplier(headerSupplier); diff --git a/sdk-extensions/autoconfigure-spi/src/main/java/io/opentelemetry/sdk/autoconfigure/spi/AutoConfigurationCustomizer.java b/sdk-extensions/autoconfigure-spi/src/main/java/io/opentelemetry/sdk/autoconfigure/spi/AutoConfigurationCustomizer.java index e49ab220875..03edca120bc 100644 --- a/sdk-extensions/autoconfigure-spi/src/main/java/io/opentelemetry/sdk/autoconfigure/spi/AutoConfigurationCustomizer.java +++ b/sdk-extensions/autoconfigure-spi/src/main/java/io/opentelemetry/sdk/autoconfigure/spi/AutoConfigurationCustomizer.java @@ -73,6 +73,8 @@ AutoConfigurationCustomizer addSpanExporterCustomizer( * delayed data. * *

Multiple calls will execute the customizers in order. + * + * @since 1.33.0 */ default AutoConfigurationCustomizer addSpanProcessorCustomizer( BiFunction @@ -192,6 +194,8 @@ default AutoConfigurationCustomizer addLogRecordExporterCustomizer( * logs or delay logs for enhancing them with external, delayed data. * *

Multiple calls will execute the customizers in order. + * + * @since 1.33.0 */ default AutoConfigurationCustomizer addLogRecordProcessorCustomizer( BiFunction diff --git a/sdk/testing/src/main/java/io/opentelemetry/sdk/testing/assertj/AbstractPointAssert.java b/sdk/testing/src/main/java/io/opentelemetry/sdk/testing/assertj/AbstractPointAssert.java index 0a3425958e0..41da09a10e5 100644 --- a/sdk/testing/src/main/java/io/opentelemetry/sdk/testing/assertj/AbstractPointAssert.java +++ b/sdk/testing/src/main/java/io/opentelemetry/sdk/testing/assertj/AbstractPointAssert.java @@ -112,7 +112,11 @@ public final PointAssertT hasAttributesSatisfying(Iterable a return myself; } - /** Asserts the point has attributes satisfying the given condition. */ + /** + * Asserts the point has attributes satisfying the given condition. + * + * @since 1.33.0 + */ public final PointAssertT hasAttributesSatisfying(Consumer attributes) { isNotNull(); assertThat(actual.getAttributes()).as("attributes").satisfies(attributes);