View Source ExWal.LogWriter protocol (ex_wal v0.3.0)
Writer writes to a virtual WAL. A Writer in standalone mode maps to a single LogWriter. In failover mode, it can failover across multiple physical log files.
Summary
Functions
stop stops the writer.
write_record writes a complete record. The record is asynchronously persisted to the underlying writer.
Types
@type t() :: term()
All the types that implement this protocol.
Functions
@spec stop(impl :: t()) :: :ok
stop stops the writer.
@spec write_record( impl :: t(), bytes :: binary(), opts :: keyword() ) :: {:ok, written_bytes :: non_neg_integer()} | {:error, reason :: term()}
write_record writes a complete record. The record is asynchronously persisted to the underlying writer.