global: snapshot

This commit is contained in:
nym21
2026-03-03 22:10:05 +01:00
parent 28f6b0f18b
commit 269c1d5fdf
99 changed files with 1565 additions and 1146 deletions
@@ -162,8 +162,8 @@ impl Vecs {
// Compute rolling window block counts (both block_count's own rolling + separate block_count_sum)
let ws = WindowStarts {
_24h: &self.height_24h_ago,
_7d: &self.height_1w_ago,
_30d: &self.height_1m_ago,
_1w: &self.height_1w_ago,
_1m: &self.height_1m_ago,
_1y: &self.height_1y_ago,
};
self.block_count.sum.compute_rolling_sum(
+3 -3
View File
@@ -59,12 +59,12 @@ pub struct Vecs<M: StorageMode = Rw> {
}
impl Vecs {
/// Get the standard 4 rolling window start heights (24h, 7d, 30d, 1y).
/// Get the standard 4 rolling window start heights (24h, 1w, 1m, 1y).
pub fn window_starts(&self) -> WindowStarts<'_> {
WindowStarts {
_24h: &self.height_24h_ago,
_7d: &self.height_1w_ago,
_30d: &self.height_1m_ago,
_1w: &self.height_1w_ago,
_1m: &self.height_1m_ago,
_1y: &self.height_1y_ago,
}
}