You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
1.2 KiB

  1. package txselector
  2. import "github.com/prometheus/client_golang/prometheus"
  3. var (
  4. metricGetL2TxSelection = prometheus.NewCounter(
  5. prometheus.CounterOpts{
  6. Name: "txsel_get_l2_txselecton_total",
  7. Help: "",
  8. },
  9. )
  10. metricGetL1L2TxSelection = prometheus.NewCounter(
  11. prometheus.CounterOpts{
  12. Name: "txsel_get_l1_l2_txselecton_total",
  13. Help: "",
  14. },
  15. )
  16. metricSelectedL1CoordinatorTxs = prometheus.NewGauge(
  17. prometheus.GaugeOpts{
  18. Name: "txsel_selected_l1_coordinator_txs",
  19. Help: "",
  20. },
  21. )
  22. metricSelectedL1UserTxs = prometheus.NewGauge(
  23. prometheus.GaugeOpts{
  24. Name: "txsel_selected_l1_user_txs",
  25. Help: "",
  26. },
  27. )
  28. metricSelectedL2Txs = prometheus.NewGauge(
  29. prometheus.GaugeOpts{
  30. Name: "txsel_selected_l2_txs",
  31. Help: "",
  32. },
  33. )
  34. metricDiscardedL2Txs = prometheus.NewGauge(
  35. prometheus.GaugeOpts{
  36. Name: "txsel_discarded_l2_txs",
  37. Help: "",
  38. },
  39. )
  40. )
  41. func init() {
  42. prometheus.MustRegister(metricGetL2TxSelection)
  43. prometheus.MustRegister(metricGetL1L2TxSelection)
  44. prometheus.MustRegister(metricSelectedL1CoordinatorTxs)
  45. prometheus.MustRegister(metricSelectedL1UserTxs)
  46. prometheus.MustRegister(metricSelectedL2Txs)
  47. prometheus.MustRegister(metricDiscardedL2Txs)
  48. }