package opentelemetry-client-cohttp-lwt

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
val get_url : unit -> string
val set_url : string -> unit

Url of the endpoint. Default is "http://localhost:4318", or "OTEL_EXPORTER_OTLP_ENDPOINT" if set.

val get_headers : unit -> (string * string) list
val set_headers : (string * string) list -> unit

Set http headers that are sent on every http query to the collector.

module Config : sig ... end
val setup : ?stop:bool Opentelemetry_client_cohttp_lwt__.Common_.Atomic.t -> ?config:Config.t -> ?enable:bool -> unit -> unit

Setup endpoint. This modifies Opentelemetry.Collector.backend.

  • parameter enable

    actually setup the backend (default true). This can be used to enable/disable the setup depending on CLI arguments or environment.

  • parameter config

    configuration to use

  • parameter stop

    an atomic boolean. When it becomes true, background threads will all stop after a little while.

val with_setup : ?stop:bool Opentelemetry_client_cohttp_lwt__.Common_.Atomic.t -> ?config:Config.t -> ?enable:bool -> unit -> (unit -> 'a) -> 'a

with_setup () f is like setup(); f() but takes care of cleaning up after f() returns See setup for more details.

OCaml

Innovation. Community. Security.