Module Trace_core.Level

Tracing levels.

This is similar to log levels in, say, Logs. In a thoroughly instrumented program, there will be a lot of spans, and enabling them all in production might slow down the application or overwhelm the tracing system; yet they might be useful in debug situations.

type t =
  1. | Error
    (*

    Only errors

    *)
  2. | Warning
    (*

    Warnings

    *)
  3. | Info
  4. | Debug1
    (*

    Least verbose debugging level

    *)
  5. | Debug2
    (*

    Intermediate verbosity debugging level

    *)
  6. | Debug3
    (*

    Maximum verbosity debugging level

    *)
  7. | Trace
    (*

    Enable everything (default level)

    *)

Level of tracing. These levels are in increasing order, i.e if level Debug1 is enabled, everything below it (Error, Warning, Info, etc.) are also enabled.

  • since 0.7
val to_string : t -> string
  • since 0.7
val leq : t -> t -> bool