mirror of
https://github.com/0glabs/0g-storage-node.git
synced 2025-04-04 15:35:18 +00:00
add data to leaves size
This commit is contained in:
parent
09bf7471b9
commit
55a4270623
@ -1263,6 +1263,7 @@ pub fn data_to_merkle_leaves(leaf_data: &[u8]) -> Result<Vec<H256>> {
|
|||||||
.collect()
|
.collect()
|
||||||
};
|
};
|
||||||
|
|
||||||
|
metrics::DATA_TO_MERKLE_LEAVES_SIZE.update(leaf_data.len() as usize);
|
||||||
metrics::DATA_TO_MERKLE_LEAVES.update_since(start_time);
|
metrics::DATA_TO_MERKLE_LEAVES.update_since(start_time);
|
||||||
Ok(r)
|
Ok(r)
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
use std::sync::Arc;
|
use std::sync::Arc;
|
||||||
|
|
||||||
use metrics::{register_timer, Timer};
|
use metrics::{register_timer, Gauge, GaugeUsize, Timer};
|
||||||
|
|
||||||
lazy_static::lazy_static! {
|
lazy_static::lazy_static! {
|
||||||
pub static ref PUT_TX: Arc<dyn Timer> = register_timer("log_store_put_tx");
|
pub static ref PUT_TX: Arc<dyn Timer> = register_timer("log_store_put_tx");
|
||||||
@ -36,4 +36,6 @@ lazy_static::lazy_static! {
|
|||||||
pub static ref APPEND_ENTRIES: Arc<dyn Timer> = register_timer("log_store_flow_store_append_entries");
|
pub static ref APPEND_ENTRIES: Arc<dyn Timer> = register_timer("log_store_flow_store_append_entries");
|
||||||
|
|
||||||
pub static ref FINALIZE_TX_WITH_HASH: Arc<dyn Timer> = register_timer("log_store_log_manager_finalize_tx_with_hash");
|
pub static ref FINALIZE_TX_WITH_HASH: Arc<dyn Timer> = register_timer("log_store_log_manager_finalize_tx_with_hash");
|
||||||
|
|
||||||
|
pub static ref DATA_TO_MERKLE_LEAVES_SIZE: Arc<dyn Gauge<usize>> = GaugeUsize::register("log_store_data_to_merkle_leaves_size");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user