Store.Traps
val add :
t ->
slot_id:Tezos_dal_node_services.Types.Slot_id.t ->
shard_index:Tezos_dal_node_services.Types.shard_index ->
delegate:Tezos_crypto.Signature.public_key_hash ->
share:Tezos_crypto_dal.Cryptobox.share ->
shard_proof:Tezos_crypto_dal.Cryptobox.shard_proof ->
unit
add ~slot_id ~shard_index ~delegate ~share ~shard_proof
adds trap data to the cache. The cache maintains a maximum of Constants.traps_cache_size
levels. Data is expected to be added in ascending order within a window of proto_parameters.attestation_lag
. When the cache reaches its capacity, the oldest trap data (relative to the highest stored level) is removed when adding new entries.
val find :
t ->
level:Tezos_dal_node_services.Types.level ->
Tezos_dal_node_services.Types.trap list
find t ~level
retrieves all trap data associated with the given level. Returns an empty list if no traps exist for that level.