Monitor transactions rejected from the pool as invalid (#5992)

This commit is contained in:
Igor Żuk authored and GitHub committed 2020-05-13 12:02:14 +02:00
1 parent 8110205820
commit eadf28881d
2 files changed
+11 -1

No files matched your search

+3 -1
View File
@@ -296,7 +296,9 @@ impl<PoolApi, Block> TransactionPool for BasicPool<PoolApi, Block>
}
fn remove_invalid(&self, hashes: &[TxHash<Self>]) -> Vec<Arc<Self::InPoolTransaction>> {
self.pool.validated_pool().remove_invalid(hashes)
let removed = self.pool.validated_pool().remove_invalid(hashes);
self.metrics.report(|metrics| metrics.validations_invalid.inc_by(removed.len() as u64));
removed
}
fn status(&self) -> PoolStatus {