package tracing

  1. Overview
  2. Docs

Events are written with a header which specifies how large the record is and how many arguments it has, which means you need to pre-commit to how many arguments of each type you will later write for an event. This is checked and will throw an exception if you write another event or close the writer without having written the correct arguments.

type t
val none : t

Use none if you aren't going to write any arguments for an event

val create : ?int64s:int -> ?int32s:int -> ?floats:int -> ?strings:int -> unit -> t

If you're going to write arguments, provide the count of each type you'll write.