package qcow

  1. Overview
  2. Docs
type t = {
  1. id : string;
    (*

    unique name for prometheus metrics

    *)
  2. discard : bool;
    (*

    true if `discard` will be enabled at runtime

    *)
  3. keep_erased : int64 option;
    (*

    size of erased free pool in sectors

    *)
  4. compact_after_unmaps : int64 option;
    (*

    automatically compact after n sectors are unmapped

    *)
  5. check_on_connect : bool;
    (*

    perform an integrity check on connect

    *)
  6. runtime_asserts : bool;
    (*

    check cluster invariants at runtime

    *)
  7. read_only : bool;
    (*

    guarantee to not modify the file

    *)
}

Runtime configuration of a device

val create : ?id:string -> ?discard:bool -> ?keep_erased:int64 -> ?compact_after_unmaps:int64 -> ?check_on_connect:bool -> ?runtime_asserts:bool -> ?read_only:bool -> unit -> t

Customise the runtime behaviour, see connect or create

val to_string : t -> string

Marshal a config into a string suitable for a command-line argument

val of_string : string -> (t, [ `Msg of string ]) Pervasives.result

Parse the result of a previous to_string invocation