Module Opentelemetry_client.Bounded_queue

Interface for a thread-safe, bounded queue.

After the high watermark is reached, pushing items into the queue will instead discard them.

exception Closed

Raised when pushing into a closed queue

type 'a pop_result = [
  1. | `Empty
  2. | `Closed
  3. | `Item of 'a
]
module Common : sig ... end
module Recv : sig ... end

Receiving side

module Send : sig ... end

Sending side

type 'a t = {
  1. send : 'a Send.t;
  2. recv : 'a Recv.t;
}

A bounded queue, with multiple producers and potentially multiple consumers.

All functions must be thread-safe except for try_pop which might not have to be depending on the context (e.g. a Lwt-specific queue implementation will consume only from the Lwt thread).

module Defaults : sig ... end