package octez-l2-libs
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=aa2f5bc99cc4ca2217c52a1af2a2cdfd3b383208cb859ca2e79ca0903396ca1d
sha512=d68bb3eb615e3dcccc845fddfc9901c95b3c6dc8e105e39522ce97637b1308a7fa7aa1d271351d5933febd7476b2819e1694f31198f1f0919681f1f9cc97cb3a
doc/octez-l2-libs.layer2_store/Tezos_layer2_store/Indexed_store/index.html
Module Tezos_layer2_store.Indexed_store
Source
This library provides functors to build various kinds of stores using mirage's index and Octez data-encoding libraries.
It is tailored to build stores for the Layer 2 nodes of Tezos (Tx-rollups and Smart rollups).
The stores built with this library support concurrent accesses thanks to the use of the light scheduler provided by Lwt_idle_waiter
for exclusive write access.
Signatures
A store for single updatable values. Values are stored in a file on disk and are kept in memory in a cache.
An index store mapping keys to values. It uses an index file internally.
An index store mapping keys to values. Keys are associated to optional values in the index which allows them to be removed.
An indexed file (i.e. a file and an index) mapping keys to values. Contrary to INDEXABLE_STORE
, the values can vary in size. Internally, values are stored, concatenated, in a append only file. The index file associates keys to offsets in this file (and a header to retrieve information more efficiently).
Same as INDEXED_FILE
but where headers are extracted from values.
Values that can be encoded.
Values that can be encoded and whose encoding is a fixed size.
Values with a given fixed size header.
Functors
module Make_indexable
(_ : NAME)
(K : Index.Key.S)
(V : Index.Value.S) :
INDEXABLE_STORE with type key := K.t and type value := V.t
module Make_indexable_removable
(_ : NAME)
(K : Index.Key.S)
(V : Index.Value.S) :
INDEXABLE_REMOVABLE_STORE with type key := K.t and type value := V.t
module Make_indexed_file
(_ : NAME)
(K : Index.Key.S)
(V : ENCODABLE_VALUE_HEADER) :
INDEXED_FILE
with type key := K.t
and type value := V.t
and type header := V.Header.t
module Make_simple_indexed_file
(_ : NAME)
(K : Index.Key.S)
(V : sig ... end) :
SIMPLE_INDEXED_FILE
with type key := K.t
and type value := V.t
and type header := V.Header.t