Update block metrics after async transaction verification
This commit is contained in:
parent
fb079c2ca1
commit
f5a53d9dae
|
@ -162,10 +162,6 @@ where
|
|||
|
||||
// TODO: context-free header verification: merkle root
|
||||
|
||||
tracing::trace!("verified block");
|
||||
metrics::gauge!("block.verified.block.height", height.0 as _);
|
||||
metrics::counter!("block.verified.block.count", 1);
|
||||
|
||||
let mut async_checks = FuturesUnordered::new();
|
||||
|
||||
for transaction in &block.transactions {
|
||||
|
@ -182,6 +178,10 @@ where
|
|||
while let Some(result) = async_checks.next().await {
|
||||
result.map_err(VerifyBlockError::Transaction)?;
|
||||
}
|
||||
|
||||
tracing::trace!("verified block");
|
||||
metrics::gauge!("block.verified.block.height", height.0 as _);
|
||||
metrics::counter!("block.verified.block.count", 1);
|
||||
|
||||
// Finally, submit the block for contextual verification.
|
||||
match state_service
|
||||
|
|
Loading…
Reference in New Issue