The storage protocol (spec seam 2): content-addressed segments plus an ordered, append-only transaction log keyed by t. Implementations must make a log append durable before acknowledging it; adapters beyond memory (local file in TT8) implement this same contract.
The storage protocol (spec seam 2): content-addressed segments plus an ordered, append-only transaction log keyed by t. Implementations must make a log append durable before acknowledging it; adapters beyond memory (local file in TT8) implement this same contract.
(append-log storage entry)Append one log entry, a map holding :t and :datoms. Returns :ok once the entry is durable. Entries must carry strictly increasing :t.
Append one log entry, a map holding :t and :datoms. Returns :ok once the entry is durable. Entries must carry strictly increasing :t.
(get-segment storage id)The data stored under id, or nil when absent.
The data stored under id, or nil when absent.
(list-segments storage)A seq of all stored segment ids.
A seq of all stored segment ids.
(log-scan storage from-t to-t)All log entries with from-t <= t <= to-t, ordered by t ascending.
All log entries with from-t <= t <= to-t, ordered by t ascending.
(put-segment storage id data)Store data under a unique id. Idempotent for a given id.
Store data under a unique id. Idempotent for a given id.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |