Configure the Java agent for Splunk Observability Cloud

Configure the agent of the Splunk Distribution of OpenTelemetry Java to suit most of your instrumentation needs, like correlating traces with logs, activating custom sampling, and more.

You can configure the Java agent from the Splunk Distribution of OpenTelemetry Java to suit most of your instrumentation needs. In most cases, modifying the basic configuration is enough to get started. More advanced settings are also available.

The following sections describe all available settings for configuring the Java Virtual Machine (JVM) agent, including options for activating new features that are unique to the Splunk Distribution of OpenTelemetry Java.

Configuration methods

You can change the agent settings in two ways:

  • Set an environment variable. For example:

    Linux
    export OTEL_SERVICE_NAME=my-java-app
    Windows PowerShell
    $env:OTEL_SERVICE_NAME=my-java-app
  • Add a system property as runtime parameter. For example:

    java -javaagent:./splunk-otel-javaagent.jar \
    -Dotel.service.name=<my-java-app> \
    -jar <myapp>.jar

Environment variables are the preferred way of configuring OpenTelemetry agents. System properties, if specified, override existing environment variables.

General settings

The following settings are specific to the Splunk Distribution of OpenTelemetry Java:

DescriptionEnvironment variableDefaultTypeSystem property
If true, disable the OpenTelemetry SDK. Defaults to false.OTEL_SDK_DISABLED'false'booleanotel.sdk.disabled
The propagators to be used. Use a comma-separated list for multiple propagators. Default is tracecontext,baggage (W3C).OTEL_PROPAGATORStracecontext,baggagestringotel.propagators
The interval, in milliseconds, between two consecutive exports. Default is 5000.OTEL_BSP_SCHEDULE_DELAY'5000'intotel.bsp.schedule.delay
The maximum queue size. Default is 2048.OTEL_BSP_MAX_QUEUE_SIZE'2048'intotel.bsp.max.queue.size
The maximum batch size. Default is 512.OTEL_BSP_MAX_EXPORT_BATCH_SIZE'512'intotel.bsp.max.export.batch.size
The maximum allowed time, in milliseconds, to export data. Default is 30000.OTEL_BSP_EXPORT_TIMEOUT'30000'intotel.bsp.export.timeout
The sampler to use for tracing. Defaults to parentbased_always_onOTEL_TRACES_SAMPLERalways_onstringotel.traces.sampler
An argument to the configured tracer if supported, for example a ratio.OTEL_TRACES_SAMPLER_ARG''stringotel.traces.sampler.arg
The filter for exemplar sampling. Can be ALWAYS_OFF, ALWAYS_ON or TRACE_BASED. Default is TRACE_BASED.OTEL_METRICS_EXEMPLAR_FILTERTRACE_BASEDstringotel.metrics.exemplar.filter
The interval, in milliseconds, between two consecutive exports. Default is 1000.OTEL_BLRP_SCHEDULE_DELAY'1000'intotel.blrp.schedule.delay
The maximum queue size. Default is 2048.OTEL_BLRP_MAX_QUEUE_SIZE'2048'intotel.blrp.max.queue.size
The maximum batch size. Default is 512.OTEL_BLRP_MAX_EXPORT_BATCH_SIZE'512'intotel.blrp.max.export.batch.size
The maximum allowed time, in milliseconds, to export data. Default is 30000.OTEL_BLRP_EXPORT_TIMEOUT'30000'intotel.blrp.export.timeout
The path to the SDK configuration file. Defaults to unset.OTEL_EXPERIMENTAL_CONFIG_FILE''stringotel.experimental.config.file
Path to valid Java properties file which contains the agent configuration.OTEL_JAVAAGENT_CONFIGURATION_FILE''stringotel.javaagent.configuration-file
Path to an extension jar file or folder, containing jar files. If pointing to a folder, every jar file in that folder will be treated as separate, independent extension.OTEL_JAVAAGENT_EXTENSIONS''stringotel.javaagent.extensions
The Java agent logging mode. The following 3 modes are supported: simple: The agent will print out its logs using the standard error stream. Only INFO or higher logs will be printed. This is the default Java agent logging mode. none: The agent will not log anything - not even its own version. application: The agent will attempt to redirect its own logs to the instrumented application's slf4j logger. This works the best for simple one-jar applications that do not use multiple classloaders; Spring Boot apps are supported as well. The Java agent output logs can be further configured using the instrumented application's logging configuration (e.g. logback.xml or log4j2.xml). Make sure to test that this mode works for your application before running it in a production environment.OTEL_JAVAAGENT_LOGGINGsimplestringotel.javaagent.logging
Suppresses all instrumentation for specific classes, format is "my.package.MyClass,my.package2.*".OTEL_JAVAAGENT_EXCLUDE_CLASSES''stringotel.javaagent.exclude-classes
Ignore the specified class loaders, format is "my.package.MyClass,my.package2.".OTEL_JAVAAGENT_EXCLUDE_CLASS_LOADERS''stringotel.javaagent.exclude-class-loaders
'Grant all privileges to agent code. Disclaimer: agent can provide application means for escaping security manager sandbox. Do not usethis option if your application relies on security manager to run untrusted code.'OTEL_JAVAAGENT_EXPERIMENTAL_SECURITY_MANAGER_SUPPORT_ENABLED'false'booleanotel.javaagent.experimental.security-manager-support.enabled
(Optional) Auth token allowing exporters to communicate directly with the Splunk cloud, passed as X-SF-TOKEN header.SPLUNK_ACCESS_TOKEN''stringsplunk.access.token
The Splunk Observability Cloud realm where the telemetry should be sent to. For example, us0 or us1. Defaults to none, which means that data goes to a Splunk OpenTelemetry Collector deployed on localhost.SPLUNK_REALMnonestringsplunk.realm
Adds the full command line as a resource attribute for all metrics. If false, commands longer than 255 characters are truncated.SPLUNK_METRICS_FORCE_FULL_COMMANDLINE'false'booleansplunk.metrics.force_full_commandline
Enables adding server trace information to HTTP response headers. [See this document](https://docs.splunk.com/observability/en/gdi/get-data-in/application/java/configuration/advanced-java-otel-configuration.html#server-trace-information) for more information.SPLUNK_TRACE_RESPONSE_HEADER_ENABLED'true'booleansplunk.trace-response-header.enabled

Example of trace sampling

The following example shows how to use the rules traces sampler to exclude the /healthcheck endpoint from monitoring:

export OTEL_TRACES_SAMPLER=rules
export OTEL_TRACES_SAMPLER_ARG=drop=/healthcheck;fallback=parentbased_always_on

All requests to downstream services that happen as a consequence of calling an excluded endpoint are also excluded.

Considerations on trace propagation

For backward compatibility with older versions of the Splunk Distribution of OpenTelemetry Java or the SignalFx Java Agent, use the b3multi trace propagator:

Linux
export OTEL_PROPAGATORS=b3multi
Windows PowerShell
$env:OTEL_PROPAGATORS=b3multi

Instrumentation configuration

The following settings control the instrumentation, including tracing and :

DescriptionEnvironment variableDefaultTypeSystem property
'Specify resource attributes in the following format: key1=val1,key2=val2,key3=val3'OTEL_RESOURCE_ATTRIBUTES''stringotel.resource.attributes
Specify logical service name. Takes precedence over service.name defined with otel.resource.attributesOTEL_SERVICE_NAME''stringotel.service.name
Specify resource attribute keys that are filtered.OTEL_EXPERIMENTAL_RESOURCE_DISABLED_KEYS''stringotel.experimental.resource.disabled-keys
The maximum length of attribute values. Applies to spans and logs. By default there is no limit.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT''intotel.attribute.value.length.limit
The maximum number of attributes. Applies to spans, span events, span links, and logs. Default is 128.OTEL_ATTRIBUTE_COUNT_LIMIT'128'intotel.attribute.count.limit
The maximum length of span attribute values. Takes precedence over otel.attribute.value.length.limit. By default there is no limit.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT''intotel.span.attribute.value.length.limit
The maximum number of attributes per span. Takes precedence over otel.attribute.count.limit. Default is 128.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT'128'intotel.span.attribute.count.limit
The maximum number of events per span. Default is 128.OTEL_SPAN_EVENT_COUNT_LIMIT'128'intotel.span.event.count.limit
TThe maximum number of links per span. Default is 128.OTEL_SPAN_LINK_COUNT_LIMIT'128'intotel.span.link.count.limit
If set, configure cardinality limit. The value dictates the maximum number of distinct points per metric. Default is 2000.OTEL_JAVA_METRICS_CARDINALITY_LIMIT'2000'intotel.java.metrics.cardinality.limit
Used to specify a mapping from host names or IP addresses to peer services, as a comma-separated list of <host_or_ip>=<user_assigned_name> pairs. The peer service is added as an attribute to a span whose host or IP address match the mapping.OTEL_INSTRUMENTATION_COMMON_PEER_SERVICE_MAPPING''stringotel.instrumentation.common.peer-service-mapping
Enables the DB statement sanitization.OTEL_INSTRUMENTATION_COMMON_DB_STATEMENT_SANITIZER_ENABLED'true'booleanotel.instrumentation.common.db-statement-sanitizer.enabled
A comma-separated list of HTTP header names. HTTP client instrumentations will capture HTTP request header values for all configured header names.OTEL_INSTRUMENTATION_HTTP_CLIENT_CAPTURE_REQUEST_HEADERS''stringotel.instrumentation.http.client.capture-request-headers
A comma-separated list of HTTP header names. HTTP client instrumentations will capture HTTP response header values for all configured header names.OTEL_INSTRUMENTATION_HTTP_CLIENT_CAPTURE_RESPONSE_HEADERS''stringotel.instrumentation.http.client.capture-response-headers
A comma-separated list of HTTP header names. HTTP server instrumentations will capture HTTP request header values for all configured header names.OTEL_INSTRUMENTATION_HTTP_SERVER_CAPTURE_REQUEST_HEADERS''stringotel.instrumentation.http.server.capture-request-headers
A comma-separated list of HTTP header names. HTTP server instrumentations will capture HTTP response header values for all configured header names.OTEL_INSTRUMENTATION_HTTP_SERVER_CAPTURE_RESPONSE_HEADERS''stringotel.instrumentation.http.server.capture-response-headers
A comma-separated list of request parameter names.OTEL_INSTRUMENTATION_SERVLET_EXPERIMENTAL_CAPTURE_REQUEST_PARAMETERS''stringotel.instrumentation.servlet.experimental.capture-request-parameters
Enables the consumer message receive telemetry. Note that this will cause the consumer side to start a new trace, with only a span link connecting it to the producer trace.OTEL_INSTRUMENTATION_MESSAGING_EXPERIMENTAL_RECEIVE_TELEMETRY_ENABLED'false'booleanotel.instrumentation.messaging.experimental.receive-telemetry.enabled
Common flag for enabling/disabling enduser attributes.OTEL_INSTRUMENTATION_COMMON_ENDUSER_ENABLED'false'booleanotel.instrumentation.common.enduser.enabled
Determines whether to capture `enduser.id` semantic attribute.OTEL_INSTRUMENTATION_COMMON_ENDUSER_ID_ENABLED'false'booleanotel.instrumentation.common.enduser.id.enabled
Determines whether to capture `enduser.role` semantic attribute.OTEL_INSTRUMENTATION_COMMON_ENDUSER_ROLE_ENABLED'false'booleanotel.instrumentation.common.enduser.role.enabled
Determines whether to capture `enduser.scope` semantic attribute.OTEL_INSTRUMENTATION_COMMON_ENDUSER_SCOPE_ENABLED'false'booleanotel.instrumentation.common.enduser.scope.enabled
Enables experimental http client telemetry.OTEL_INSTRUMENTATION_HTTP_CLIENT_EMIT_EXPERIMENTAL_TELEMETRY'false'booleanotel.instrumentation.http.client.emit-experimental-telemetry
Enables experimental http server telemetry.OTEL_INSTRUMENTATION_HTTP_SERVER_EMIT_EXPERIMENTAL_TELEMETRY'false'booleanotel.instrumentation.http.server.emit-experimental-telemetry
Redact sensitive parameter values from URL query string, see https://opentelemetry.io/docs/specs/semconv/http/http-spans.OTEL_INSTRUMENTATION_HTTP_CLIENT_EXPERIMENTAL_REDACT_QUERY_PARAMETERS'true'booleanotel.instrumentation.http.client.experimental.redact-query-parameters
Disable all instrumentations in the agent.OTEL_INSTRUMENTATION_COMMON_DEFAULT_ENABLED'true'booleanotel.instrumentation.common.default-enabled
Suppresses agent instrumentation of specific library where `{name}` is the corresponding instrumentation name.OTEL_INSTRUMENTATION_{NAME}_ENABLED''booleanotel.instrumentation.{name}.enabled
Enables the controller telemetry.OTEL_INSTRUMENTATION_COMMON_EXPERIMENTAL_CONTROLLER_TELEMETRY_ENABLED'false'booleanotel.instrumentation.common.experimental.controller-telemetry.enabled
Enables the view telemetry.OTEL_INSTRUMENTATION_COMMON_EXPERIMENTAL_VIEW_TELEMETRY_ENABLED'false'booleanotel.instrumentation.common.experimental.view-telemetry.enabled
The Java agent span suppression strategy. The following 3 strategies are supported: semconv: The agent will suppress duplicate semantic conventions. This is the default behavior of the Java agent. span-kind: The agent will suppress spans with the same kind (except INTERNAL). none: The agent will not suppress anything at all. We do not recommend using this option for anything other than debug purposes, as it generates lots of duplicate telemetry data.OTEL_INSTRUMENTATION_EXPERIMENTAL_SPAN_SUPPRESSION_STRATEGYsemconvstringotel.instrumentation.experimental.span-suppression-strategy
Experimental setting to inject a JavaScript snippet into servlet HTML responses after the opening head tag.OTEL_EXPERIMENTAL_JAVASCRIPT_SNIPPET''stringotel.experimental.javascript-snippet
Same as adding @WithSpan annotation functionality for the target method string, e.g. my.package.MyClass1[method1,method2];my.package.MyClass2[method3]OTEL_INSTRUMENTATION_METHODS_INCLUDE''stringotel.instrumentation.methods.include
Suppress @WithSpan instrumentation for specific methods, e.g. my.package.MyClass1[method1,method2];my.package.MyClass2[method3]OTEL_INSTRUMENTATION_OPENTELEMETRY_ANNOTATIONS_EXCLUDE_METHODS''stringotel.instrumentation.opentelemetry-annotations.exclude-methods
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_AWS_SDK_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.aws-sdk.experimental-span-attributes
v2 only, inject into SNS/SQS attributes with configured propagator.OTEL_INSTRUMENTATION_AWS_SDK_EXPERIMENTAL_USE_PROPAGATOR_FOR_MESSAGING'false'booleanotel.instrumentation.aws-sdk.experimental-use-propagator-for-messaging
v2 only, record errors returned by each individual HTTP request as events for the SDK span.OTEL_INSTRUMENTATION_AWS_SDK_EXPERIMENTAL_USE_PROPAGATOR_FOR_MESSAGING'false'booleanotel.instrumentation.aws-sdk.experimental-use-propagator-for-messaging
v2 only, record content of user and LLM messages when using Bedrock.OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT'false'booleanotel.instrumentation.genai.capture-message-content
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_CAMEL_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.camel.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_APACHE_SHENYU_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.apache-shenyu.experimental-span-attributes
Enables the capture of experimental span attributes (for version 2.6 and higher of this instrumentation).OTEL_INSTRUMENTATION_COUCHBASE_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.couchbase.experimental-span-attributes
'Enable the capture of search query bodies. Attention: Elasticsearch queries may contain personal or sensitive information.'OTEL_INSTRUMENTATION_ELASTICSEARCH_CAPTURE_SEARCH_QUERY'false'booleanotel.instrumentation.elasticsearch.capture-search-query
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_ELASTICSEARCH_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.elasticsearch.experimental-span-attributes
Whether to remove sensitive information from query source that is added as span attribute.OTEL_INSTRUMENTATION_GRAPHQL_QUERY_SANITIZER_ENABLED'true'booleanotel.instrumentation.graphql.query-sanitizer.enabled
'Whether GraphQL operation name is added to the span name. **WARNING**: GraphQL operation name is provided by the client and can have high cardinality. Use only when the server is not exposed to malicious clients.'OTEL_INSTRUMENTATION_GRAPHQL_ADD_OPERATION_NAME_TO_SPAN_NAME_ENABLED'false'booleanotel.instrumentation.graphql.add-operation-name-to-span-name.enabled
Whether to create spans for data fetchers (GraphQL 20 and later).OTEL_INSTRUMENTATION_GRAPHQL_DATA_FETCHER_ENABLED'false'booleanotel.instrumentation.graphql.data-fetcher.enabled
Whether to create spans for trivial data fetchers. A trivial data fetcher is one that simply maps data from an object to a field (GraphQL 20 and later).OTEL_INSTRUMENTATION_GRAPHQL_TRIVIAL_DATA_FETCHER_ENABLED'false'booleanotel.instrumentation.graphql.trivial-data-fetcher.enabled
Determines whether to emit span event for each individual message received and sent.OTEL_INSTRUMENTATION_GRPC_EMIT_MESSAGE_EVENTS'true'booleanotel.instrumentation.grpc.emit-message-events
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_GRPC_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.grpc.experimental-span-attributes
A comma-separated list of request metadata keys. gRPC client instrumentation will capture metadata values corresponding to configured keys as span attributes.OTEL_INSTRUMENTATION_GRPC_CAPTURE_METADATA_CLIENT_REQUEST''stringotel.instrumentation.grpc.capture-metadata.client.request
A comma-separated list of request metadata keys. gRPC server instrumentation will capture metadata values corresponding to configured keys as span attributes.OTEL_INSTRUMENTATION_GRPC_CAPTURE_METADATA_SERVER_REQUEST''stringotel.instrumentation.grpc.capture-metadata.server.request
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_GUAVA_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.guava.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_HIBERNATE_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.hibernate.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_HYSTRIX_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.hystrix.experimental-span-attributes
Enable the capture of experimental log attributes `thread.name` and `thread.id`.OTEL_INSTRUMENTATION_JAVA_UTIL_LOGGING_EXPERIMENTAL_LOG_ATTRIBUTES'false'booleanotel.instrumentation.java-util-logging.experimental-log-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_JAXRS_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.jaxrs.experimental-span-attributes
Enable the capture of experimental log attributes.OTEL_INSTRUMENTATION_JBOSS_LOGMANAGER_EXPERIMENTAL_LOG_ATTRIBUTES'false'booleanotel.instrumentation.jboss-logmanager.experimental-log-attributes
Comma separated list of MDC attributes to capture. Use the wildcard character `*` to capture all attributes.OTEL_INSTRUMENTATION_JBOSS_LOGMANAGER_EXPERIMENTAL_CAPTURE_MDC_ATTRIBUTES''stringotel.instrumentation.jboss-logmanager.experimental.capture-mdc-attributes
Enables the DB statement sanitization.OTEL_INSTRUMENTATION_JDBC_STATEMENT_SANITIZER_ENABLED'true'booleanotel.instrumentation.jdbc.statement-sanitizer.enabled
'Enable the capture of query parameters as span attributes. Enabling this option disables the statement sanitization. WARNING: captured query parameters may contain sensitive information such as passwords, personally identifiable information or protected health info.'OTEL_INSTRUMENTATION_JDBC_EXPERIMENTAL_CAPTURE_QUERY_PARAMETERS'false'booleanotel.instrumentation.jdbc.experimental.capture-query-parameters
Enables experimental instrumentation to create spans for COMMIT and ROLLBACK operations.OTEL_INSTRUMENTATION_JDBC_EXPERIMENTAL_TRANSACTION_ENABLED'false'booleanotel.instrumentation.jdbc.experimental.transaction.enabled
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_JSP_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.jsp.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_KAFKA_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.kafka.experimental-span-attributes
Enable context propagation for kafka message producer.OTEL_INSTRUMENTATION_KAFKA_PRODUCER_PROPAGATION_ENABLED'true'booleanotel.instrumentation.kafka.producer-propagation.enabled
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_KUBERNETES_CLIENT_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.kubernetes-client.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_LETTUCE_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.lettuce.experimental-span-attributes
Enable the capture of experimental log attributes `thread.name` and `thread.id`.OTEL_INSTRUMENTATION_LOG4J_APPENDER_EXPERIMENTAL_LOG_ATTRIBUTES'false'booleanotel.instrumentation.log4j-appender.experimental-log-attributes
Enable the capture of [source code attributes](https://github.com/open-telemetry/semantic-conventions/blob/main/docs/general/attributes.md#source-code-attributes). Note that capturing source code attributes at logging sites might add a performance overhead.OTEL_INSTRUMENTATION_LOG4J_APPENDER_EXPERIMENTAL_CAPTURE_CODE_ATTRIBUTES'false'booleanotel.instrumentation.log4j-appender.experimental.capture-code-attributes
Enable the capture of `MapMessage` attributes.OTEL_INSTRUMENTATION_LOG4J_APPENDER_EXPERIMENTAL_CAPTURE_MAP_MESSAGE_ATTRIBUTES'false'booleanotel.instrumentation.log4j-appender.experimental.capture-map-message-attributes
Enable the capture of Log4j markers as attributes.OTEL_INSTRUMENTATION_LOG4J_APPENDER_EXPERIMENTAL_CAPTURE_MARKER_ATTRIBUTE'false'booleanotel.instrumentation.log4j-appender.experimental.capture-marker-attribute
Comma separated list of context data attributes to capture. Use the wildcard character `*` to capture all attributes.OTEL_INSTRUMENTATION_LOG4J_APPENDER_EXPERIMENTAL_CAPTURE_MDC_ATTRIBUTES''stringotel.instrumentation.log4j-appender.experimental.capture-mdc-attributes
Enable exposing baggage attributes through MDC.OTEL_INSTRUMENTATION_LOG4J_CONTEXT_DATA_ADD_BAGGAGE'false'booleanotel.instrumentation.log4j-context-data.add-baggage
Comma separated list of resource attributes to expose through MDC.OTEL_INSTRUMENTATION_COMMON_MDC_RESOURCE_ATTRIBUTES''stringotel.instrumentation.common.mdc.resource-attributes
Customize MDC key name for the trace id.OTEL_INSTRUMENTATION_COMMON_LOGGING_TRACE_IDtrace_idstringotel.instrumentation.common.logging.trace-id
Customize MDC key name for the span id.OTEL_INSTRUMENTATION_COMMON_LOGGING_SPAN_IDspan_idstringotel.instrumentation.common.logging.span-id
Customize MDC key name for the trace flags.OTEL_INSTRUMENTATION_COMMON_LOGGING_TRACE_FLAGStrace_flagsstringotel.instrumentation.common.logging.trace-flags
Enable the capture of experimental log attributes `thread.name` and `thread.id`.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_LOG_ATTRIBUTES'false'booleanotel.instrumentation.logback-appender.experimental-log-attributes
Enable the capture of [source code attributes](https://github.com/open-telemetry/semantic-conventions/blob/main/docs/general/attributes.md#source-code-attributes). Note that capturing source code attributes at logging sites might add a performance overhead.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_CAPTURE_CODE_ATTRIBUTES'false'booleanotel.instrumentation.logback-appender.experimental.capture-code-attributes
Enable the capture of Logback markers as attributes.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_CAPTURE_MARKER_ATTRIBUTE'false'booleanotel.instrumentation.logback-appender.experimental.capture-marker-attribute
Enable the capture of Logback key value pairs as attributes.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_CAPTURE_KEY_VALUE_PAIR_ATTRIBUTES'false'booleanotel.instrumentation.logback-appender.experimental.capture-key-value-pair-attributes
Enable the capture of Logback logger context properties as attributes.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_CAPTURE_LOGGER_CONTEXT_ATTRIBUTES'false'booleanotel.instrumentation.logback-appender.experimental.capture-logger-context-attributes
Enable the capture of Logback logger arguments.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_CAPTURE_ARGUMENTS'false'booleanotel.instrumentation.logback-appender.experimental.capture-arguments
Comma separated list of MDC attributes to capture. Use the wildcard character `*` to capture all attributes.OTEL_INSTRUMENTATION_LOGBACK_APPENDER_EXPERIMENTAL_CAPTURE_MDC_ATTRIBUTES''stringotel.instrumentation.logback-appender.experimental.capture-mdc-attributes
Enable exposing baggage attributes through MDC.OTEL_INSTRUMENTATION_LOGBACK_MDC_ADD_BAGGAGE'false'booleanotel.instrumentation.logback-mdc.add-baggage
Comma separated list of resource attributes to expose through MDC.OTEL_INSTRUMENTATION_COMMON_MDC_RESOURCE_ATTRIBUTES''stringotel.instrumentation.common.mdc.resource-attributes
Set the base time unit for the OpenTelemetry `MeterRegistry` implementation. Valid values: `ns`, `nanoseconds`, `us`, `microseconds`, `ms`, `milliseconds`, `s`, `seconds`, `min`, `minutes`, `h`, `hours`, `d`, `days`OTEL_INSTRUMENTATION_MICROMETER_BASE_TIME_UNITsstringotel.instrumentation.micrometer.base-time-unit
Enable the "Prometheus mode" this will simulate the behavior of Micrometer's PrometheusMeterRegistry. The instruments will be renamed to match Micrometer instrument naming, and the base time unit will be set to seconds.OTEL_INSTRUMENTATION_MICROMETER_PROMETHEUS_MODE_ENABLED'false'booleanotel.instrumentation.micrometer.prometheus-mode.enabled
Enables the generation of gauge-based Micrometer histograms for `DistributionSummary` and `Timer` instruments.OTEL_INSTRUMENTATION_MICROMETER_HISTOGRAM_GAUGES_ENABLED'false'booleanotel.instrumentation.micrometer.histogram-gauges.enabled
Enables the DB statement sanitization.OTEL_INSTRUMENTATION_MONGO_STATEMENT_SANITIZER_ENABLED'true'booleanotel.instrumentation.mongo.statement-sanitizer.enabled
Enable the creation of Connect and DNS spans by default for Netty 4.0 and higher instrumentation.OTEL_INSTRUMENTATION_NETTY_CONNECTION_TELEMETRY_ENABLED'false'booleanotel.instrumentation.netty.connection-telemetry.enabled
Enable SSL telemetry for Netty 4.0 and higher instrumentation.OTEL_INSTRUMENTATION_NETTY_SSL_TELEMETRY_ENABLED'false'booleanotel.instrumentation.netty.ssl-telemetry.enabled
Record content of user and LLM messages.OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT'false'booleanotel.instrumentation.genai.capture-message-content
All methods to be excluded from auto-instrumentation by annotation-based advices.OTEL_INSTRUMENTATION_OPENTELEMETRY_ANNOTATIONS_EXCLUDE_METHODS''stringotel.instrumentation.opentelemetry-annotations.exclude-methods
All methods to be excluded from auto-instrumentation by annotation-based advices.OTEL_INSTRUMENTATION_OPENTELEMETRY_INSTRUMENTATION_ANNOTATIONS_EXCLUDE_METHODS''stringotel.instrumentation.opentelemetry-instrumentation-annotations.exclude-methods
Enable the OSHI metrics.OTEL_INSTRUMENTATION_OSHI_EXPERIMENTAL_METRICS_ENABLED'false'booleanotel.instrumentation.oshi.experimental-metrics.enabled
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_POWERJOB_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.powerjob.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_PULSAR_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.pulsar.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_QUARTZ_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.quartz.experimental-span-attributes
Enables the DB statement sanitization.OTEL_INSTRUMENTATION_R2DBC_STATEMENT_SANITIZER_ENABLED'true'booleanotel.instrumentation.r2dbc.statement-sanitizer.enabled
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_RABBITMQ_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.rabbitmq.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_REACTOR_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.reactor.experimental-span-attributes
Enable the creation of Connect and DNS spans by default.OTEL_INSTRUMENTATION_REACTOR_NETTY_CONNECTION_TELEMETRY_ENABLED'false'booleanotel.instrumentation.reactor-netty.connection-telemetry.enabled
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_ROCKETMQ_CLIENT_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.rocketmq-client.experimental-span-attributes
Enable the capture of experimental metrics.OTEL_INSTRUMENTATION_RUNTIME_TELEMETRY_EMIT_EXPERIMENTAL_TELEMETRY'false'booleanotel.instrumentation.runtime-telemetry.emit-experimental-telemetry
Enable the capture of all JFR based metrics.OTEL_INSTRUMENTATION_RUNTIME_TELEMETRY_JAVA17_ENABLE_ALL'false'booleanotel.instrumentation.runtime-telemetry-java17.enable-all
Enable the capture of JFR based metrics.OTEL_INSTRUMENTATION_RUNTIME_TELEMETRY_JAVA17_ENABLED'false'booleanotel.instrumentation.runtime-telemetry-java17.enabled
Enable creating events for JAR libraries used by the application.OTEL_INSTRUMENTATION_RUNTIME_TELEMETRY_PACKAGE_EMITTER_ENABLED'false'booleanotel.instrumentation.runtime-telemetry.package-emitter.enabled
The number of JAR files processed per second.OTEL_INSTRUMENTATION_RUNTIME_TELEMETRY_PACKAGE_EMITTER_JARS_PER_SECOND'10'intotel.instrumentation.runtime-telemetry.package-emitter.jars-per-second
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_RXJAVA_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.rxjava.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_SERVLET_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.servlet.experimental-span-attributes
Enable creating span for each item.OTEL_INSTRUMENTATION_SPRING_BATCH_ITEM_ENABLED'false'booleanotel.instrumentation.spring-batch.item.enabled
Enable staring a new trace for each chunk.OTEL_INSTRUMENTATION_SPRING_BATCH_EXPERIMENTAL_CHUNK_NEW_TRACE'false'booleanotel.instrumentation.spring-batch.experimental.chunk.new-trace
Enable the capture of experimental span attributes for Spring Batch version 3.0.OTEL_INSTRUMENTATION_SPRING_SCHEDULING_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.spring-scheduling.experimental-span-attributes
An array of Spring channel name patterns that will be intercepted. See [Spring Integration docs](https://docs.spring.io/spring-integration/reference/channel/configuration.html#global-channel-configuration-interceptors) for more details.OTEL_INSTRUMENTATION_SPRING_INTEGRATION_GLOBAL_CHANNEL_INTERCEPTOR_PATTERNS'*'stringotel.instrumentation.spring-integration.global-channel-interceptor-patterns
Create producer spans when messages are sent to an output channel. Enable when you're using a messaging library that doesn't have its own instrumentation for generating producer spans. Note that the detection of output channels only works for [Spring Cloud Stream](https://spring.io/projects/spring-cloud-stream) `DirectWithAttributesChannel`.OTEL_INSTRUMENTATION_SPRING_INTEGRATION_PRODUCER_ENABLED'false'booleanotel.instrumentation.spring-integration.producer.enabled
Enable the capture of experimental span attributes for Spring Scheduling version 3.1.OTEL_INSTRUMENTATION_SPRING_SCHEDULING_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.spring-scheduling.experimental-span-attributes
Enable the capture of experimental span attributes for Spring WebFlux version 5.0.OTEL_INSTRUMENTATION_SPRING_WEBFLUX_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.spring-webflux.experimental-span-attributes
Enable the capture of experimental span attributes for Spring Web MVC version 3.1.OTEL_INSTRUMENTATION_SPRING_WEBMVC_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.spring-webmvc.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_SPRING_CLOUD_GATEWAY_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.spring-cloud-gateway.experimental-span-attributes
Prefix of granted authorities identifying roles to capture in the `enduser.role` semantic attribute.OTEL_INSTRUMENTATION_SPRING_SECURITY_ENDUSER_ROLE_GRANTED_AUTHORITY_PREFIXROLE_stringotel.instrumentation.spring-security.enduser.role.granted-authority-prefix
Prefix of granted authorities identifying scopes to capture in the `enduser.scopes` semantic attribute.OTEL_INSTRUMENTATION_SPRING_SECURITY_ENDUSER_SCOPE_GRANTED_AUTHORITY_PREFIXSCOPE_stringotel.instrumentation.spring-security.enduser.scope.granted-authority-prefix
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_SPYMEMCACHED_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.spymemcached.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_TWILIO_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.twilio.experimental-span-attributes
Enable the capture of experimental span attributes.OTEL_INSTRUMENTATION_XXL_JOB_EXPERIMENTAL_SPAN_ATTRIBUTES'false'booleanotel.instrumentation.xxl-job.experimental-span-attributes

Exporters configuration

The following settings control trace exporters and their endpoints:

DescriptionEnvironment variableDefaultTypeSystem property
List of exporters to be used for tracing, separated by commas. Default is otlp. none means no autoconfigured exporter.OTEL_TRACES_EXPORTERotlpstringotel.traces.exporter
List of exporters to be used for metrics, separated by commas. Default is otlp. none means no autoconfigured exporter.OTEL_METRICS_EXPORTERotlpstringotel.metrics.exporter
List of exporters to be used for logging, separated by commas. Default is otlp. none means no autoconfigured exporter.OTEL_LOGS_EXPORTERotlpstringotel.logs.exporter
If `reusable_data`, enable reusable memory mode (on exporters which support it) to reduce allocations. Default is `immutable_data`. This option is experimental and subject to change or removal.OTEL_JAVA_EXPERIMENTAL_EXPORTER_MEMORY_MODEimmutable_datastringotel.java.experimental.exporter.memory_mode
The OTLP traces, metrics, and logs endpoint to connect to. Must be a URL with a scheme of either http or https based on the use of TLS. If protocol is http/protobuf the version and signal will be appended to the path (e.g. v1/traces, v1/metrics, or v1/logs). Default is http://localhost:4317 when protocol is grpc, and http://localhost:4318/v1/{signal} when protocol is http/protobuf.OTEL_EXPORTER_OTLP_ENDPOINThttp://localhost:4318stringotel.exporter.otlp.endpoint
The OTLP traces endpoint to connect to. Must be a URL with a scheme of either http or https based on the use of TLS. Default is http://localhost:4317 when protocol is grpc, and http://localhost:4318/v1/traces when protocol is http/protobuf.OTEL_EXPORTER_OTLP_TRACES_ENDPOINThttp://localhost:4318/v1/tracesstringotel.exporter.otlp.traces.endpoint
The OTLP metrics endpoint to connect to. Must be a URL with a scheme of either http or https based on the use of TLS. Default is http://localhost:4317 when protocol is grpc, and http://localhost:4318/v1/metrics when protocol is http/protobuf.OTEL_EXPORTER_OTLP_METRICS_ENDPOINThttp://localhost:4318/v1/metricsstringotel.exporter.otlp.metrics.endpoint
The OTLP logs endpoint to connect to. Must be a URL with a scheme of either http or https based on the use of TLS. Default is http://localhost:4317 when protocol is grpc, and http://localhost:4318/v1/logs when protocol is http/protobuf.OTEL_EXPORTER_OTLP_LOGS_ENDPOINThttp://localhost:4318/v1/logsstringotel.exporter.otlp.logs.endpoint
The path to the file containing trusted certificates to use when verifying an OTLP trace, metric, or log server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default the host platform's trusted root certificates are used.OTEL_EXPORTER_OTLP_CERTIFICATE''stringotel.exporter.otlp.certificate
The path to the file containing trusted certificates to use when verifying an OTLP trace server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default the host platform's trusted root certificates are used.OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE''stringotel.exporter.otlp.traces.certificate
The path to the file containing trusted certificates to use when verifying an OTLP metric server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default the host platform's trusted root certificates are used.OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE''stringotel.exporter.otlp.metrics.certificate
The path to the file containing trusted certificates to use when verifying an OTLP log server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default the host platform's trusted root certificates are used.OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE''stringotel.exporter.otlp.logs.certificate
The path to the file containing private client key to use when verifying an OTLP trace, metric, or log client's TLS credentials. The file should contain one private key PKCS8 PEM format. By default no client key is used.OTEL_EXPORTER_OTLP_CLIENT_KEY''stringotel.exporter.otlp.client.key
The path to the file containing private client key to use when verifying an OTLP trace client's TLS credentials. The file should contain one private key PKCS8 PEM format. By default no client key file is used.OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY''stringotel.exporter.otlp.traces.client.key
The path to the file containing private client key to use when verifying an OTLP metric client's TLS credentials. The file should contain one private key PKCS8 PEM format. By default no client key file is used.OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY''stringotel.exporter.otlp.metrics.client.key
The path to the file containing private client key to use when verifying an OTLP log client's TLS credentials. The file should contain one private key PKCS8 PEM format. By default no client key file is used.OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY''stringotel.exporter.otlp.logs.client.key
The path to the file containing trusted certificates to use when verifying an OTLP trace, metric, or log client's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default no chain file is used.OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE''stringotel.exporter.otlp.client.certificate
The path to the file containing trusted certificates to use when verifying an OTLP trace server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default no chain file is used.OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE''stringotel.exporter.otlp.traces.client.certificate
The path to the file containing trusted certificates to use when verifying an OTLP metric server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default no chain file is used.OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE''stringotel.exporter.otlp.metrics.client.certificate
The path to the file containing trusted certificates to use when verifying an OTLP log server's TLS credentials. The file should contain one or more X.509 certificates in PEM format. By default no chain file is used.OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE''stringotel.exporter.otlp.logs.client.certificate
Key-value pairs separated by commas to pass as request headers on OTLP trace, metric, and log requests.OTEL_EXPORTER_OTLP_HEADERS''stringotel.exporter.otlp.headers
Key-value pairs separated by commas to pass as request headers on OTLP trace requests.OTEL_EXPORTER_OTLP_TRACES_HEADERS''stringotel.exporter.otlp.traces.headers
Key-value pairs separated by commas to pass as request headers on OTLP metrics requests.OTEL_EXPORTER_OTLP_METRICS_HEADERS''stringotel.exporter.otlp.metrics.headers
Key-value pairs separated by commas to pass as request headers on OTLP logs requests.OTEL_EXPORTER_OTLP_LOGS_HEADERS''stringotel.exporter.otlp.logs.headers
The compression type to use on OTLP trace, metric, and log requests. Options include gzip. By default no compression will be used.OTEL_EXPORTER_OTLP_COMPRESSION''stringotel.exporter.otlp.compression
The compression type to use on OTLP trace requests. Options include gzip. By default no compression will be used.OTEL_EXPORTER_OTLP_TRACES_COMPRESSION''stringotel.exporter.otlp.traces.compression
The compression type to use on OTLP metric requests. Options include gzip. By default no compression will be used.OTEL_EXPORTER_OTLP_METRICS_COMPRESSION''stringotel.exporter.otlp.metrics.compression
The compression type to use on OTLP log requests. Options include gzip. By default no compression will be used.OTEL_EXPORTER_OTLP_LOGS_COMPRESSION''stringotel.exporter.otlp.logs.compression
The maximum waiting time, in milliseconds, allowed to send each OTLP trace, metric, and log batch. Default is 10000.OTEL_EXPORTER_OTLP_TIMEOUT'10000'intotel.exporter.otlp.timeout
The maximum waiting time, in milliseconds, allowed to send each OTLP trace batch. Default is 10000.OTEL_EXPORTER_OTLP_TRACES_TIMEOUT'10000'intotel.exporter.otlp.traces.timeout
The maximum waiting time, in milliseconds, allowed to send each OTLP metric batch. Default is 10000.OTEL_EXPORTER_OTLP_METRICS_TIMEOUT'10000'intotel.exporter.otlp.metrics.timeout
The maximum waiting time, in milliseconds, allowed to send each OTLP log batch. Default is 10000.OTEL_EXPORTER_OTLP_LOGS_TIMEOUT'10000'intotel.exporter.otlp.logs.timeout
The transport protocol to use on OTLP trace, metric, and log requests. Options include grpc and http/protobuf.OTEL_EXPORTER_OTLP_PROTOCOLhttp/protobufstringotel.exporter.otlp.protocol
The transport protocol to use on OTLP trace requests. Options include grpc and http/protobuf.OTEL_EXPORTER_OTLP_TRACES_PROTOCOLhttp/protobufstringotel.exporter.otlp.traces.protocol
The transport protocol to use on OTLP metric requests. Options include grpc and http/protobuf.OTEL_EXPORTER_OTLP_METRICS_PROTOCOLhttp/protobufstringotel.exporter.otlp.metrics.protocol
The transport protocol to use on OTLP log requests. Options include grpc and http/protobuf.OTEL_EXPORTER_OTLP_LOGS_PROTOCOLhttp/protobufstringotel.exporter.otlp.logs.protocol
The preferred output aggregation temporality. Options include DELTA, LOWMEMORY, and CUMULATIVE. If CUMULATIVE, all instruments will have cumulative temporality. If DELTA, counter (sync and async) and histograms will be delta, up down counters (sync and async) will be cumulative. If LOWMEMORY, sync counter and histograms will be delta, async counter and up down counters (sync and async) will be cumulative. Default is CUMULATIVE.OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCECUMULATIVEstringotel.exporter.otlp.metrics.temporality.preference
The preferred default histogram aggregation. Options include BASE2_EXPONENTIAL_BUCKET_HISTOGRAM and EXPLICIT_BUCKET_HISTOGRAM. Default is EXPLICIT_BUCKET_HISTOGRAM.OTEL_EXPORTER_OTLP_METRICS_DEFAULT_HISTOGRAM_AGGREGATIONEXPLICIT_BUCKET_HISTOGRAMstringotel.exporter.otlp.metrics.default.histogram.aggregation
If true, enable experimental retry support. Default is false.OTEL_EXPERIMENTAL_EXPORTER_OTLP_RETRY_ENABLED'false'booleanotel.experimental.exporter.otlp.retry.enabled
The Zipkin endpoint to connect to. Default is http://localhost:9411/api/v2/spans. Currently only HTTP is supported.OTEL_EXPORTER_ZIPKIN_ENDPOINThttp://localhost:9411/api/v2/spansstringotel.exporter.zipkin.endpoint
The interval, in milliseconds, between the start of two export attempts. Default is 60000.OTEL_METRIC_EXPORT_INTERVAL'60000'intotel.metric.export.interval
The local port used to bind the prometheus metric server. Default is 9464.OTEL_EXPORTER_PROMETHEUS_PORT'9464'intotel.exporter.prometheus.port
The local address used to bind the prometheus metric server. Default is 0.0.0.0.OTEL_EXPORTER_PROMETHEUS_HOST0.0.0.0intotel.exporter.prometheus.host

The Splunk Distribution of OpenTelemetry Java uses the OTLP http/protobuf span exporter by default. To send data directly to Splunk Observability Cloud, see Send data directly to Splunk Observability Cloud.

Java settings for AlwaysOn Profiling

The following settings control the AlwaysOn Profiling feature for the Java agent:

DescriptionEnvironment variableDefaultTypeSystem property
Enables cpu profiler.SPLUNK_PROFILER_ENABLED'false'booleansplunk.profiler.enabled
Location of JFR files, defaults to System.getProperty("java.io.tmpdir").SPLUNK_PROFILER_DIRECTORYvalue of System.getProperty("java.io.tmpdir")stringsplunk.profiler.directory
Recording unit duration.SPLUNK_PROFILER_RECORDING_DURATION20sstringsplunk.profiler.recording.duration
Leave JFR files on disk if true.SPLUNK_PROFILER_KEEP_FILES'false'booleansplunk.profiler.keep-files
Where to send OTLP logs, defaults to `otel.exporter.otlp.endpoint.SPLUNK_PROFILER_LOGS_ENDPOINThttp://localhost:4318/v1/logsstringsplunk.profiler.logs-endpoint
How often to sample call stacks.SPLUNK_PROFILER_CALL_STACK_INTERVAL10000msstringsplunk.profiler.call.stack.interval
Enables allocation profiler.SPLUNK_PROFILER_MEMORY_ENABLED'false'booleansplunk.profiler.memory.enabled
Allocation event rate.SPLUNK_PROFILER_MEMORY_EVENT_RATE150/sstringsplunk.profiler.memory.event.rate
Set to `true` to include stack traces of agent internal threads and stack traces with only JDK internal frames.SPLUNK_PROFILER_INCLUDE_INTERNAL_STACKS'false'booleansplunk.profiler.include.internal.stacks
Set to `true` to include only stack traces that are linked to a span context.SPLUNK_PROFILER_TRACING_STACKS_ONLY'false'booleansplunk.profiler.tracing.stacks.only
The transport protocol to use on profiling OTLP log requests. Options include grpc and http/protobuf.SPLUNK_PROFILER_OTLP_PROTOCOLhttp/protobufstringsplunk.profiler.otlp.protocol

For more information on AlwaysOn Profiling, see Introduction to AlwaysOn Profiling for Splunk APM.

Server trace information

To connect Real User Monitoring (RUM) requests from mobile and web applications with server trace data, trace response headers are activated by default. The instrumentation adds the following response headers to HTTP responses:

Access-Control-Expose-Headers: Server-Timing
Server-Timing: traceparent;desc="00-<serverTraceId>-<serverSpanId>-01"

The Server-Timing header contains the traceId and spanId parameters in traceparent format. For more information, see the Server-Timing and traceparent documentation on the W3C website.

The following server frameworks and libraries add Server-Timing information:

  • Servlet API versions 2.2 to 4.X.

  • Netty versions 3.8 to 4.0.

Note: If you need to deactivate trace response headers, set SPLUNK_TRACE_RESPONSE_HEADER_ENABLED to false.

Other settings

Environment variable

Description

OTEL_JAVAAGENT_ENABLED

Globally activates the Java agent automatic instrumentation. The default value is true. Useful for deactivating automatic discovery in testing scenarios or pipelines. System property: otel.javaagent.enabled.