website: snapshot

This commit is contained in:
nym21
2026-01-23 22:03:01 +01:00
parent f7bfe5ecaa
commit 9b706dfaee
49 changed files with 631818 additions and 1298 deletions

View File

@@ -33,6 +33,18 @@ impl Vecs {
Ok(())
})?;
self.received_sum
.compute_all(indexes, starting_indexes, exit, |v| {
v.compute_sum_from_indexes(
starting_indexes.height,
&indexer.vecs.transactions.first_txindex,
&indexes.height.txindex_count,
&fees_vecs.output_value,
exit,
)?;
Ok(())
})?;
self.annualized_volume.compute_sats(|v| {
v.compute_sum(
starting_indexes.dateindex,

View File

@@ -23,6 +23,13 @@ impl Vecs {
indexes,
price,
)?,
received_sum: ValueFromHeightSum::forced_import(
db,
"received_sum",
version,
indexes,
price,
)?,
annualized_volume: ValueFromDateLast::forced_import(
db,
"annualized_volume",

View File

@@ -7,6 +7,7 @@ use crate::internal::{ComputedFromDateLast, ValueFromHeightSum, ValueFromDateLas
#[derive(Clone, Traversable)]
pub struct Vecs {
pub sent_sum: ValueFromHeightSum,
pub received_sum: ValueFromHeightSum,
pub annualized_volume: ValueFromDateLast,
pub tx_per_sec: ComputedFromDateLast<StoredF32>,
pub outputs_per_sec: ComputedFromDateLast<StoredF32>,