You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fatxpool: add labels for mempool_revalidation_invalid_txs metric (#9003)
# Description
This PR considers errors propagated from mempool revalidation in the
context of fork-aware transaction pool and groups them under unique
labels to count them under `mempool_revalidation_invalid_txs` prometheus
metric.
Closes#7973
## Integration
Node developers/operators can use labels like `category` & `reason` to
differentiate between invalid transactions, as reported by mempool
revalidation.
## Review Notes
Labeling mempool revalidation invalid txs is done based on `category` &
`reason`:
- the transaction validity invalid and unknown are mapped to category =
"invalid" or "unknown", while the underlying variant name is the reason,
converted to snake case.
- `sc_transaction_pool::common::error::Error` returned from
`sc_transaction_pool_api::api::validate_transaction_blocking` function
is mapped to category = "validation_failed" and reason is variant name
in snake_case.
- txs part of subtrees of invalid txs are considered invalid, and they
are mapped to category = "subtree" and reason =
"invalid"|"unknown"|"validation_failed", based on the category of the
invalid root tx that started the invalidation of the subtree the tx is
part of.
---------
Signed-off-by: Iulian Barbu <[email protected]>
Co-authored-by: cmd[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Bastian Köcher <[email protected]>
title: '`fatxpool`: add labels for mempool revalidation invalid txs counting'
2
+
doc:
3
+
- audience: [ Node Dev, Node Operator ]
4
+
description: |-
5
+
This PR considers errors propagated from mempool revalidation in the context of fork-aware transaction pool and groups them under unique labels to count them under `mempool_revalidation_invalid_txs` prometheus metric. This results in a breakdown of the type of root causes for why a transaction is considered invalid, helping with debugging.
0 commit comments