Skip to content

Releases: open-telemetry/opentelemetry-js

v2.12.0

Choose a tag to compare

@pichlermarc pichlermarc released this 06 Oct 13:59
92b844e

2.12.0

πŸš€ Features

  • chore(sdk-trace): add StackContextManager in @opentelemetry/sdk-trace package #7086

🏠 Internal

  • feat(ci): support releasing from maintenance branches #6767 @pichlermarc
    • The API documentation site is only redeployed for releases whose commit is reachable from main, so a maintenance release no longer overwrites it.

experimental/v0.223.0

Choose a tag to compare

@pichlermarc pichlermarc released this 06 Oct 13:59
92b844e

0.223.0

πŸ’₯ Breaking Changes

  • chore(web-common)!: clean up and deprecate network span utils #7114
    • These utilities were long planned for removal. They were moved from the sdk-trace-web package and are currently only used by the (deprecated) instrumentation-fetch and instrumentation-xml-http-request packages.
    • Drop the skipOldSemconvContentLengthAttrs vestigial option from addSpanNetworkEvents().

🏠 Internal

  • refactor(web-common, instrumentation-fetch, instrumentation-xml-http-request): move utils from @opentelemetry/sdk-trace-web
    into @opentelemetry/web-common and use them in @opentelemetry/instrumentation-fetch and @opentelemetry/instrumentation-xml-http-request.
    With this change the instrumentations do not depend on SDK packages and the utils are kept in a shared package so we avoid code duplication.

v2.11.0

Choose a tag to compare

@pichlermarc pichlermarc released this 31 Aug 16:43
0b72a81

2.11.0

πŸš€ Features

  • feat(context-async-hooks): implement attach() on AsyncLocalStorageContextManager #6845 @pichlermarc
    • On Node.js 25.9+, delegates to AsyncLocalStorage.withScope() returning a native RunScope. On older Node.js, falls back to enterWith() with a manual disposable wrapper.
  • feat(sdk-trace): allow configuring the force flush timeout per call #6929 @LarryHu0217

πŸ› Bug Fixes

  • fix(sdk-metrics): ignore Infinity in exponential histograms #7015 @mwear

🏠 Internal

  • perf(sdk-metrics): reuse a single DataView for exponential histogram bit reads #6998 @mwear
  • chore(ci): run documentation tests on a weekly schedule #6920 @LarryHu0217
  • feat(ci): support pre-releases and major version bumps in the release workflow #6768 @pichlermarc
  • chore(resources): Ensure that multiple uses of serviceInstanceIdDetector.detect() return the same value for service.instance.id

experimental/v0.222.0

Choose a tag to compare

@pichlermarc pichlermarc released this 31 Aug 16:42
0b72a81

0.222.0

πŸ’₯ Breaking Changes

  • fix(sdk-node)!: fail-fast on Propagator creation from config file #6930 @trentm
  • fix(sdk-node)!: fail-fast on MeterProvider creation from config file #6954 @trentm
  • fix(sdk-node)!: fail-fast on TracerProvider creation from config file #6962 @trentm
  • fix(sdk-node)!: fail-fast on Resource creation from config file #6989 @trentm
    • This also breaks some usage of startNodeSDK() for environment-based config, i.e. when not using a config file. For example with OTEL_NODE_RESOURCE_DETECTORS=all, it results in an error message and a no-op SDK.
      (This does not impact users of new NodeSDK() -- the currently recommended mechanism to start an SDK using this package.)

      Could not create OpenTelemetry SDK from configuration, SDK will not be setup: unknown ExperimentalResourceDetector name in configuration: "container"

πŸš€ Features

  • feat(sdk-logs): deprecate SdkLogRecord in favor of ReadWriteLogRecord #6939 @pichlermarc

πŸ› Bug Fixes

  • fix(instrumentation-http): redact sensitive query parameters on incoming (server) spans; add redactedQueryParamsServer config option @dyladan
  • fix(sdk-node): support headers_list when creating OTLP exporters from declarative configuration #6953 @JacksonWeber

πŸ“š Documentation

  • docs(sdk-logs): mark logger configuration as experimental #6996 @LarryHu0217
  • docs(configuration): document the ConfigModel suffix naming convention for exported types #6612 @vedantchalke36

🏠 Internal

  • refactor(sampler-jaeger-remote): remove axios dependency and use fetch to get the sampler configuration from Jaeger API #6963 @david-luna

v2.10.0

Choose a tag to compare

@trentm trentm released this 21 Jul 20:13
76fa6b5

2.10.0

πŸš€ Features

  • feat(sdk-logs): implement log processor metrics #6554 @anuraaga
  • feat(otlp-exporter): implement exporter metrics #6480 @anuraaga
  • feat(propagator-jaeger): Notice: The @opentelemetry/propagator-jaeger package will be removed in SDK 3.x, planned for approximately September 2026. @pichlermarc
    • The Jaeger propagator has been deprecated by the OpenTelemetry specification in favor of W3CTraceContextPropagator. This package will be removed in a future release.

πŸ› Bug Fixes

  • fix(sdk-trace): reject SimpleSpanProcessor.forceFlush() when a pending export fails #6771 @LarryHu0217
  • fix(sdk-trace): include trace IDs at the ratio 1 upper bound in TraceIdRatioBasedSampler #6890 @LarryHu0217

🏠 Internal

experimental/v0.221.0

Choose a tag to compare

@trentm trentm released this 21 Jul 20:13
76fa6b5

0.221.0

πŸ’₯ Breaking Changes

  • feat(sdk-logs)!: configure the force flush timeout per call #6931 @LarryHu0217
    • (user-facing): LoggerProviderOptions.forceFlushTimeoutMillis has been removed; pass timeoutMillis to LoggerProvider.forceFlush() instead.
  • feat(instrumentation-http)!: emit only stable HTTP semantic conventions. The OTEL_SEMCONV_STABILITY_OPT_IN environment variable no longer changes HTTP attribute or metric emission β€” old (v1.7.0) and duplicate (http/http/dup) semconv outputs have been removed. #6819 @maryliag
  • feat(instrumentation-fetch)!: emit only stable HTTP semantic conventions. The semconvStabilityOptIn instrumentation config option has been removed; old (v1.7.0) and duplicate semconv outputs are no longer emitted. #6819 @maryliag
  • feat(instrumentation-xml-http-request)!: emit only stable HTTP semantic conventions. The semconvStabilityOptIn instrumentation config option has been removed; old (v1.7.0) and duplicate semconv outputs are no longer emitted. #6819 @maryliag
  • feat(instrumentation-grpc)!: emit only stable network semantic conventions. The OTEL_SEMCONV_STABILITY_OPT_IN environment variable no longer changes attribute emission β€” net.peer.name and net.peer.port (old) are no longer set; only server.address and server.port (stable). #6819 @maryliag

πŸš€ Features

  • feat(sdk-logs): allow modifying ReadWriteLogRecord properties (including hrTime, hrTimeObserved, and spanContext) in accordance with the OpenTelemetry Logs specification #6923 @Babul422
  • feat(sdk-node): emit a deprecation warning when the JaegerPropagator is selected via OTEL_PROPAGATORS or declarative config; use tracecontext instead. @pichlermarc
  • feat(instrumentation-http): set error.type to status code in metrics for error requests. #6919 @raphael-theriault-swi

semconv/v1.43.0

Choose a tag to compare

@trentm trentm released this 09 Jul 20:10
9b05f66

1.43.0

πŸš€ Features

  • feat: update semantic conventions to v1.43.0 #6883
    • Semantic Conventions v1.43.0: changelog | latest docs
    • @opentelemetry/semantic-conventions (stable) changes: 1 added export
    • @opentelemetry/semantic-conventions/incubating (unstable) changes: 1 added export

Stable changes in v1.43.0

1 added export
TELEMETRY_SDK_LANGUAGE_VALUE_KOTLIN // "kotlin"

Unstable changes in v1.43.0

1 added export
ATTR_AZURE_RESOURCE_GROUP_NAME // azure.resource_group.name

semconv/v1.42.0

Choose a tag to compare

@trentm trentm released this 06 Jul 19:27
f7c090c

1.42.0

πŸš€ Features

Stable changes in v1.42.0

46 added exports
ATTR_CONTAINER_ID                 // container.id
ATTR_CONTAINER_IMAGE_NAME         // container.image.name
ATTR_CONTAINER_IMAGE_REPO_DIGESTS // container.image.repo_digests
ATTR_CONTAINER_IMAGE_TAGS         // container.image.tags

ATTR_K8S_CLUSTER_NAME             // k8s.cluster.name
ATTR_K8S_CLUSTER_UID              // k8s.cluster.uid
ATTR_K8S_CONTAINER_NAME           // k8s.container.name
ATTR_K8S_CONTAINER_RESTART_COUNT  // k8s.container.restart_count
ATTR_K8S_CRONJOB_ANNOTATION       // (key) => `k8s.cronjob.annotation.${key}`
ATTR_K8S_CRONJOB_LABEL            // (key) => `k8s.cronjob.label.${key}`
ATTR_K8S_CRONJOB_NAME             // k8s.cronjob.name
ATTR_K8S_CRONJOB_UID              // k8s.cronjob.uid
ATTR_K8S_DAEMONSET_ANNOTATION     // (key) => `k8s.daemonset.annotation.${key}`
ATTR_K8S_DAEMONSET_LABEL          // (key) => `k8s.daemonset.label.${key}`
ATTR_K8S_DAEMONSET_NAME           // k8s.daemonset.name
ATTR_K8S_DAEMONSET_UID            // k8s.daemonset.uid
ATTR_K8S_DEPLOYMENT_ANNOTATION    // (key) => `k8s.deployment.annotation.${key}`
ATTR_K8S_DEPLOYMENT_LABEL         // (key) => `k8s.deployment.label.${key}`
ATTR_K8S_DEPLOYMENT_NAME          // k8s.deployment.name
ATTR_K8S_DEPLOYMENT_UID           // k8s.deployment.uid
ATTR_K8S_JOB_ANNOTATION           // (key) => `k8s.job.annotation.${key}`
ATTR_K8S_JOB_LABEL                // (key) => `k8s.job.label.${key}`
ATTR_K8S_JOB_NAME                 // k8s.job.name
ATTR_K8S_JOB_UID                  // k8s.job.uid
ATTR_K8S_NAMESPACE_ANNOTATION     // (key) => `k8s.namespace.annotation.${key}`
ATTR_K8S_NAMESPACE_LABEL          // (key) => `k8s.namespace.label.${key}`
ATTR_K8S_NAMESPACE_NAME           // k8s.namespace.name
ATTR_K8S_NODE_ANNOTATION          // (key) => `k8s.node.annotation.${key}`
ATTR_K8S_NODE_LABEL               // (key) => `k8s.node.label.${key}`
ATTR_K8S_NODE_NAME                // k8s.node.name
ATTR_K8S_NODE_UID                 // k8s.node.uid
ATTR_K8S_POD_ANNOTATION           // (key) => `k8s.pod.annotation.${key}`
ATTR_K8S_POD_HOSTNAME             // k8s.pod.hostname
ATTR_K8S_POD_IP                   // k8s.pod.ip
ATTR_K8S_POD_LABEL                // (key) => `k8s.pod.label.${key}`
ATTR_K8S_POD_NAME                 // k8s.pod.name
ATTR_K8S_POD_START_TIME           // k8s.pod.start_time
ATTR_K8S_POD_UID                  // k8s.pod.uid
ATTR_K8S_REPLICASET_ANNOTATION    // (key) => `k8s.replicaset.annotation.${key}`
ATTR_K8S_REPLICASET_LABEL         // (key) => `k8s.replicaset.label.${key}`
ATTR_K8S_REPLICASET_NAME          // k8s.replicaset.name
ATTR_K8S_REPLICASET_UID           // k8s.replicaset.uid
ATTR_K8S_STATEFULSET_ANNOTATION   // (key) => `k8s.statefulset.annotation.${key}`
ATTR_K8S_STATEFULSET_LABEL        // (key) => `k8s.statefulset.label.${key}`
ATTR_K8S_STATEFULSET_NAME         // k8s.statefulset.name
ATTR_K8S_STATEFULSET_UID          // k8s.statefulset.uid

Unstable changes in v1.42.0

74 newly deprecated exports
METRIC_GEN_AI_CLIENT_OPERATION_DURATION              // gen_ai.client.operation.duration: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_GEN_AI_CLIENT_OPERATION_TIME_PER_OUTPUT_CHUNK // gen_ai.client.operation.time_per_output_chunk: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_GEN_AI_CLIENT_OPERATION_TIME_TO_FIRST_CHUNK   // gen_ai.client.operation.time_to_first_chunk: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_GEN_AI_CLIENT_TOKEN_USAGE                     // gen_ai.client.token.usage: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_GEN_AI_SERVER_REQUEST_DURATION                // gen_ai.server.request.duration: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_GEN_AI_SERVER_TIME_PER_OUTPUT_TOKEN           // gen_ai.server.time_per_output_token: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_GEN_AI_SERVER_TIME_TO_FIRST_TOKEN             // gen_ai.server.time_to_first_token: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_MCP_CLIENT_OPERATION_DURATION                 // mcp.client.operation.duration: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_MCP_CLIENT_SESSION_DURATION                   // mcp.client.session.duration: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_MCP_SERVER_OPERATION_DURATION                 // mcp.server.operation.duration: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_MCP_SERVER_SESSION_DURATION                   // mcp.server.session.duration: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
METRIC_V8JS_MEMORY_HEAP_LIMIT                        // v8js.memory.heap.limit: Replaced by `v8js.memory.heap.space.size`.
EVENT_GEN_AI_CLIENT_INFERENCE_OPERATION_DETAILS      // gen_ai.client.inference.operation.details: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
EVENT_GEN_AI_CLIENT_OPERATION_EXCEPTION              // gen_ai.client.operation.exception: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
EVENT_GEN_AI_EVALUATION_RESULT                       // gen_ai.evaluation.result: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
CPU_MODE_VALUE_KERNEL                                // kernel: Replaced by `system`.
ATTR_GEN_AI_AGENT_DESCRIPTION                        // gen_ai.agent.description: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_AGENT_ID                                 // gen_ai.agent.id: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_AGENT_NAME                               // gen_ai.agent.name: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_AGENT_VERSION                            // gen_ai.agent.version: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_CONVERSATION_ID                          // gen_ai.conversation.id: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_DATA_SOURCE_ID                           // gen_ai.data_source.id: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_EMBEDDINGS_DIMENSION_COUNT               // gen_ai.embeddings.dimension.count: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_EVALUATION_EXPLANATION                   // gen_ai.evaluation.explanation: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_EVALUATION_NAME                          // gen_ai.evaluation.name: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_EVALUATION_SCORE_LABEL                   // gen_ai.evaluation.score.label: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_EVALUATION_SCORE_VALUE                   // gen_ai.evaluation.score.value: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
ATTR_GEN_AI_INPUT_MESSAGES                           // gen_ai.input.messages: Moved to the [OpenTelemetry GenAI semantic conventions repository](https://github.com/open-telemetry/semantic-conventions-genai).
AT...
Read more

v2.9.0

Choose a tag to compare

@trentm trentm released this 02 Jul 22:26
40d67b7

2.9.0

πŸ’₯ Breaking Changes

  • docs(shim-opentracing): Notice: The @opentelemetry/shim-opentracing package will be removed in SDK 3.x, planned for approximately September 2026.
    • The OpenCensus and OpenTracing compatibility requirements in the OpenTelemetry specification have been deprecated.

πŸš€ Features

  • feat(sdk-metrics): add maxExportBatchSize option to PeriodicExportingMetricReader #6655 @psx95
    • Optimized PeriodicExportingMetricReader.forceFlush to prevent redundant concurrent export cycles. Concurrent calls to forceFlush will now await any ongoing export and reuse a fresh export cycle if one is started concurrently by another caller. This ensures the latest metrics are always exported efficiently without triggering duplicate collection and export cycles.
  • feat(sdk-trace): implement span processor metrics #6504 @anuraaga
  • feat(sdk-trace): add a new "sdk-trace" package to hold the Trace SDK, without environment variable configuration handling that belongs elsewhere #6775 @trentm
    • "sdk-trace" will eventually replace all of "sdk-trace-base", "sdk-trace-node", and "sdk-trace-web".
    • The BatchSpanProcessor constructor call signature has changed in "sdk-trace". For example, before new BatchSpanProcessor(exporter, { maxQueueSize: 1000 }), after new BatchSpanProcessor({ exporter, maxQueueSize: 1000 }). #6817
    • The SimpleSpanProcessor constructor call signature has changed in "sdk-trace". For example, before new SimpleSpanProcessor(exporter), after new SimpleSpanProcessor({ exporter, selfObsMeterProvider: ... }). #6504
  • feat(sdk-trace): add AlwaysRecordSampler #6188 @majanjua-amzn

πŸ› Bug Fixes

  • fix(propagator-jaeger): do not throw on malformed percent-encoded uber-trace-id / uberctx-* headers during extract @pichlermarc

🏠 Internal

  • perf(sdk-metrics): defer allocation of HrTime to accumulation creation #6839 @legendecas
  • chore(*): migrate use of sdk-trace-base and sdk-trace-node to sdk-trace #6851 @trentm
  • perf(sdk-metrics): optionally capture active context for sync instruments #6848 @legendecas

experimental/v0.220.0

Choose a tag to compare

@trentm trentm released this 02 Jul 22:25
40d67b7

0.220.0

πŸ’₯ Breaking Changes

  • refactor(sdk-logs)!: refactor BatchLogRecordProcessor constructor signature #6817 @trentm
    • (user-facing): BatchLogRecordProcessor now takes a single options object with all possible properties, instead of two separate arguments. For example, before new BatchLogRecordProcessor(exporter, { maxQueueSize: 1000 }), after new BatchLogRecordProcessor({ exporter, maxQueueSize: 1000 }).
    • interface BufferConfig -> interface BatchLogRecordProcessorOptions, and now includes the exporter property
    • interface BatchLogRecordProcessorBrowserConfig -> interface BatchLogRecordProcessorBrowserOptions
    • (user-facing): SimpleLogRecordProcessor now takes a single options object with all possible properties. For example, before new SimpleLogRecordProcessor(exporter), after new SimpleLogRecordProcessor({ exporter }). #6836
  • refactor(configuration)!: change config file parsing to not add default values, nor merge *_list fields #6765 @trentm
  • docs(shim-opencensus): Notice: The @opentracing/shim-opencensus package will be removed in SDK 3.x, planned for approximately September 2026.
    • The OpenCensus and OpenTracing compatibility requirements in the OpenTelemetry specification have been deprecated.
  • chore(sdk-node)!: Drop support for deprecated OpenCensusMetricProducer from declarative config

πŸš€ Features

  • feat(configuration): bump config schema to v1.1.0; rename without_scope_info β†’ scope_info_enabled and without_target_info/development β†’ target_info_enabled/development on the Prometheus pull exporter (semantics inverted), rename with_resource_constant_labels β†’ resource_constant_labels. Validate file_format per the configuration versioning spec: accept any minor version of major 1 (e.g. 1.0, 1.1), warn when the minor version is newer than supported, and reject other major versions. #6781 @MikeGoldsmith
  • feat(sdk-node): wire up id_generator from declarative config #6782 @MikeGoldsmith
  • feat(sdk-node): wire up tracer_provider.sampler from declarative config (always_on, always_off, trace_id_ratio_based, parent_based); unrecognized variants warn and fall back to ParentBased(AlwaysOn) #6506 @MikeGoldsmith
  • feat(propagator-env-carrier): empty name normalization #6827 @pellared
  • feat(propagator-env-carrier): make EnvironmentGetter read the current process.env #6853 @pellared

πŸ› Bug Fixes

  • fix(sdk-logs): stop Logger.emit() doing work (record construction, metrics, processor onEmit) after the LoggerProvider has shut down #6826 @anneheartrecord
  • fix(sdk-node): pass all config properties (endpoint, headers, timeout, TLS, compression, temporality preference, default histogram aggregation) to OTLP metric exporters in declarative config #6814 @MikeGoldsmith
  • fix(sdk-logs): default BatchLogRecordProcessor scheduleDelayMillis is 1000 #6796 @trentm
  • fix(configuration): percent-decode keys and values in resource.attributes_list per spec #6787 @MikeGoldsmith
  • fix(configuration): default log_level to info in env-based config initialization for consistency with file-based config #6788 @MikeGoldsmith
  • fix(sdk-node): fail-fast on LoggerProvider creation with startNodeSDK() and declarative config #6785 @trentm

πŸ“š Documentation

  • docs(configuration): link the configuration README to the cross-SDK declarative config language support status doc #6809 @MikeGoldsmith

🏠 Internal

  • chore(sdk-node): migrate to use the new sdk-trace package #6828 @trentm
    • The node re-export of @opentelemetry/sdk-trace-node and tracing re-export of @opentelemetry/sdk-trace-base have been deprecated. (Historically the @opentelemetry/sdk-node package has re-exported from a number of core packages. It is now recommended that users directly import from those other packages.)
  • chore(*): migrate use of sdk-trace-base and sdk-trace-node to sdk-trace #6851 @trentm
  • fix(instrumentation,instrumentation-http): fix codecov coverage under-reporting by merging coverage across CJS/ESM test runs #6867 @mwear