AuditTrail. Buffer
(audit_trail v0.1.2)
Copy Markdown
Partitioned in-memory buffer that every log payload passes through before
it's sanitized and handed to the configured storage adapter. Not part of
the public API — logging goes through AuditTrail.emit/2, monitor/4,
schema tracking, or the plugs, all of which call log/2 for you.
One partition per partition_count (default 8) config value, keyed by
:erlang.phash2(partition_key, partition_count) — flushed independently
on batch_size or flush_interval, whichever comes first. See the
README's "Buffer tuning" config section for the full set of knobs.
Summary
Functions
Queues one log payload for the partition that partition_key (typically actor_id) hashes to. Called internally by AuditTrail.Logger — not typically called directly.
Functions
Queues one log payload for the partition that partition_key (typically actor_id) hashes to. Called internally by AuditTrail.Logger — not typically called directly.