BuildOnViction / victionchain

The Efficient Blockchain Powered By Proof Of Stake Voting Consensus
https://viction.xyz
GNU Lesser General Public License v3.0
168 stars 85 forks source link

Add metrics in txpool #437

Closed trinhdn2 closed 6 months ago

trinhdn2 commented 10 months ago

Prerequisite

Checklist

Added metrics:

Example of new metrics under prometheus format:

# TYPE txpool_invalid gauge
txpool_invalid 119247

# TYPE txpool_known gauge
txpool_known 3337375

# TYPE txpool_local gauge
txpool_local 0

# TYPE txpool_pending gauge
txpool_pending 265

# TYPE txpool_pending_discard gauge
txpool_pending_discard 171

# TYPE txpool_pending_nofunds gauge
txpool_pending_nofunds 1

# TYPE txpool_pending_ratelimit gauge
txpool_pending_ratelimit 0

# TYPE txpool_pending_replace gauge
txpool_pending_replace 33

# TYPE txpool_queued gauge
txpool_queued 0

# TYPE txpool_queued_discard gauge
txpool_queued_discard 0

# TYPE txpool_queued_eviction gauge
txpool_queued_eviction 0

# TYPE txpool_queued_nofunds gauge
txpool_queued_nofunds 0

# TYPE txpool_queued_ratelimit gauge
txpool_queued_ratelimit 0

# TYPE txpool_queued_replace gauge
txpool_queued_replace 0

# TYPE txpool_reheap_count counter
txpool_reheap_count 18416

# TYPE txpool_reheap summary
txpool_reheap {quantile="0.5"} 70105
txpool_reheap {quantile="0.75"} 84645
txpool_reheap {quantile="0.95"} 109613
txpool_reheap {quantile="0.99"} 145931.7
txpool_reheap {quantile="0.999"} 194394.28000000003
txpool_reheap {quantile="0.9999"} 194559

# TYPE txpool_underpriced gauge
txpool_underpriced 0

# TYPE txpool_valid gauge
txpool_valid 46236

References: