package opentelemetry

  1. Overview
  2. Docs

Process-wide metadata, environment variables, etc.

val service_name : string Stdlib.ref

Main service name metadata

val service_namespace : string option Stdlib.ref

Namespace for the service

val service_instance_id : string option Stdlib.ref

Unique identifier for the service

val instrumentation_library : Proto.Common.instrumentation_scope
val global_attributes : Proto.Common.key_value list Stdlib.ref

Global attributes, initially set via OTEL_RESOURCE_ATTRIBUTES and modifiable by the user code. They will be attached to each outgoing metrics/traces.

val add_global_attribute : string -> value -> unit

Add a global attribute

val merge_global_attributes_ : Proto.Common.key_value list -> Proto.Common.key_value list
val default_span_kind : Proto.Trace.span_span_kind Stdlib.ref

Default span kind in Span.create. This will be used in all spans that do not specify ~kind explicitly; it is set to "internal", following directions from the .proto file. It can be convenient to set "client" or "server" uniformly in here.

  • since 0.4
val mk_attributes : ?service_name:string -> ?attrs: (string * [< `Bool of bool | `Float of float | `Int of int | `None | `String of string ]) list -> unit -> Proto.Common.key_value list
OCaml

Innovation. Community. Security.