Message_templates_lwt.Lwt_file_sinkLwt file sink with rolling support
Lwt file sink - async file output with rolling support
type t = {base_path : string;mutable current_path : string;mutable fd : Lwt_unix.file_descr;output_template : string;rolling : rolling_interval;mutable last_roll_time : Ptime.t;mutex : Lwt_mutex.t;}Internal state for Lwt file sink
val generate_path : string -> rolling_interval -> stringGenerate file path based on rolling interval
val should_roll : t -> Ptime.t -> boolCheck if we need to roll over
val roll : t -> unit Lwt.tRoll to a new file
val format_output : t -> Message_templates.Log_event.t -> stringFormat output string
val emit : t -> Message_templates.Log_event.t -> unit Lwt.tEmit a log event
val flush : t -> unit Lwt.tFlush output
val close : t -> unit Lwt.tClose the sink
val create :
?output_template:string ->
?rolling:rolling_interval ->
string ->
t Lwt.tCreate a new Lwt file sink