Update block metrics after async transaction verification
@@ -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 {
@@ -183,6 +179,10 @@ where
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
.ready_and()
