global: snapshot

This commit is contained in:
nym21
2026-03-01 22:41:25 +01:00
parent 159c983a3f
commit 7cb1bfa667
119 changed files with 1241 additions and 1182 deletions

View File

@@ -5,7 +5,7 @@ use vecdb::Database;
use super::Vecs;
use crate::{
indexes,
internal::{ComputedFromHeightCumulativeFull, ComputedHeightDerivedCumulativeFull},
internal::{ComputedFromHeightFull, ComputedHeightDerivedFull},
};
impl Vecs {
@@ -15,13 +15,13 @@ impl Vecs {
indexes: &indexes::Vecs,
) -> Result<Self> {
Ok(Self {
vbytes: ComputedFromHeightCumulativeFull::forced_import(
vbytes: ComputedFromHeightFull::forced_import(
db,
"block_vbytes",
version,
indexes,
)?,
size: ComputedHeightDerivedCumulativeFull::forced_import(
size: ComputedHeightDerivedFull::forced_import(
db,
"block_size",
version,

View File

@@ -2,10 +2,10 @@ use brk_traversable::Traversable;
use brk_types::StoredU64;
use vecdb::{Rw, StorageMode};
use crate::internal::{ComputedFromHeightCumulativeFull, ComputedHeightDerivedCumulativeFull};
use crate::internal::{ComputedFromHeightFull, ComputedHeightDerivedFull};
#[derive(Traversable)]
pub struct Vecs<M: StorageMode = Rw> {
pub vbytes: ComputedFromHeightCumulativeFull<StoredU64, M>,
pub size: ComputedHeightDerivedCumulativeFull<StoredU64, M>,
pub vbytes: ComputedFromHeightFull<StoredU64, M>,
pub size: ComputedHeightDerivedFull<StoredU64, M>,
}