diff --git a/docs/misc/declarative-configuration/config.yaml b/docs/misc/declarative-configuration/config.yaml new file mode 100644 index 000000000000..67fa7c6e971c --- /dev/null +++ b/docs/misc/declarative-configuration/config.yaml @@ -0,0 +1,98 @@ +# This file serves as a specification how to map properties from the existing config properties +# to the declarative configuration format. +# This list does not contain all properties, but those that +# are different from what the config bridge already does. + +# Also see +# - https://github.com/open-telemetry/opentelemetry-configuration/blob/main/examples/sdk-migration-config.yaml +# - https://github.com/open-telemetry/opentelemetry-configuration/blob/main/examples/sdk-config.yaml + +instrumentation/development: + # nothing changes here - just for reference + general: + peer: + service_mapping: # was "otel.instrumentation.common.peer-service-mapping" + - peer: 1.2.3.4 + service: FooService + - peer: 2.3.4.5 + service: BarService + http: + # should be added to https://github.com/open-telemetry/opentelemetry-configuration/blob/c205770a956713e512eddb056570a99737e3383a/examples/kitchen-sink.yaml#L872 + known_methods: # was "otel.instrumentation.http.known-methods" + - GET + - POST + - PUT + - DELETE + - PATCH + - HEAD + - OPTIONS + client: + request_captured_headers: # was otel.instrumentation.http.client.capture-request-headers + - Content-Type + - Accept + response_captured_headers: # was otel.instrumentation.http.client.capture-response-headers + - Content-Type + - Content-Encoding + server: + request_captured_headers: # was otel.instrumentation.http.server.capture-request-headers + - Content-Type + - Accept + response_captured_headers: # was otel.instrumentation.http.server.capture-response-headers + - Content-Type + - Content-Encoding + java: + agent: + # Also map all other properties with the "otel.javaagent." prefix the same way, + # unless specified otherwise. + # See https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/14132 + exclude_class_loaders: # was "otel.javaagent.exclude-class-loaders" + - a + - b + common: + default: + enabled: true # was "otel.instrumentation.common.default-enabled" + db_statement_sanitizer: + enabled: true # already exists - just for reference + thread_details: + # disabled by default + # enabled applies to both spans and logs (but not metrics due to high cardinality) + enabled: true # was "otel.javaagent.add-thread-details" = "true" + +# These cannot be used in the Java Agent, because they are read in early stages, +# but the Spring starter may use them (need to be discussed). +disabled: false # was: "otel.sdk.enabled" +log_level: info # is not used is Spring starter yet + +# Note: The following properties still have to be specified with system properties or +# environment variables, because they are read in early stages of the application startup: +# User facing: +# - otel.javaagent.enabled +# - otel.javaagent.debug +# - otel.javaagent.extensions +# - otel.javaagent.logging +# - otel.javaagent.logging.application.logs-buffer-max-records +# - otel.javaagent.configuration-file (although you shouldn't need this with declarative configuration) +# - otel.javaagent.experimental.field-injection.enabled +# - otel.javaagent.experimental.security-manager-support.enabled +# Internal: +# - otel.javaagent.experimental.thread-propagation-debugger.enabled +# - otel.javaagent.testing.fail-on-context-leak + +# These properties could be read from declarative configuration in the future, but are not yet. +# Issue: https://github.com/open-telemetry/opentelemetry-java-instrumentation/issues/14192 +# - otel.experimental.javascript-snippet +# - otel.instrumentation.aws-sdk.experimental-record-individual-http-error +# - otel.instrumentation.aws-sdk.experimental-span-attributes +# - otel.instrumentation.aws-sdk.experimental-use-propagator-for-messaging +# - otel.instrumentation.common.db-statement-sanitizer.enabled +# - otel.instrumentation.common.logging.span-id +# - otel.instrumentation.common.logging.trace-flags +# - otel.instrumentation.common.logging.trace-id +# - otel.instrumentation.experimental.span-suppression-strategy +# - otel.instrumentation.genai.capture-message-content +# - otel.instrumentation.jdbc.experimental.capture-query-parameters +# - otel.instrumentation.jdbc.experimental.transaction.enabled +# - otel.instrumentation.log4j-context-data.add-baggage +# - otel.instrumentation.messaging.experimental.capture-headers +# - otel.instrumentation.messaging.experimental.receive-telemetry.enabled +# - otel.semconv-stability.opt-in