From 93c12fb196dc3051f52a9d399358727631ef8e0f Mon Sep 17 00:00:00 2001 From: Jack Berg Date: Mon, 7 Aug 2023 17:00:54 -0500 Subject: [PATCH] Add reminder to shutdown exporter instances if replacing --- .../autoconfigure/spi/AutoConfigurationCustomizer.java | 9 +++++++++ 1 file changed, 9 insertions(+) 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 e016e6a7424..d126ceb07ed 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 @@ -56,6 +56,9 @@ AutoConfigurationCustomizer addSamplerCustomizer( * allow customization. The return value of the {@link BiFunction} will replace the passed-in * argument. * + *

NOTE: If returning a different exporter instance, be sure to call {@link + * SpanExporter#shutdown()} on the instance passed as an argument to release resources. + * *

Multiple calls will execute the customizers in order. */ AutoConfigurationCustomizer addSpanExporterCustomizer( @@ -128,6 +131,9 @@ default AutoConfigurationCustomizer addMeterProviderCustomizer( * allow customization. The return value of the {@link BiFunction} will replace the passed-in * argument. * + *

NOTE: If returning a different exporter instance, be sure to call {@link + * SpanExporter#shutdown()} on the instance passed as an argument to release resources. + * *

Multiple calls will execute the customizers in order. */ default AutoConfigurationCustomizer addMetricExporterCustomizer( @@ -155,6 +161,9 @@ default AutoConfigurationCustomizer addLoggerProviderCustomizer( * to allow customization. The return value of the {@link BiFunction} will replace the passed-in * argument. * + *

NOTE: If returning a different exporter instance, be sure to call {@link + * SpanExporter#shutdown()} on the instance passed as an argument to release resources. + * *

Multiple calls will execute the customizers in order. * * @since 1.19.0