@@ -43,6 +43,16 @@ declareCounter beacon_sync_messages_dropped_queue_full,
43
43
declareCounter beacon_contributions_dropped_queue_full,
44
44
" Number of sync committee contributions dropped because queue is full"
45
45
46
+ declareCounter beacon_data_column_sidecar_processing_requests_total,
47
+ " Number of data column sidecars submitted for processing"
48
+
49
+ declareCounter beacon_data_column_sidecar_processing_successes_total,
50
+ " Number of data column sidecars verified for gossip"
51
+
52
+ declareHistogram beacon_data_column_sidecar_gossip_verification_seconds,
53
+ " Full runtime of data column sidecars gossip verification" ,
54
+ buckets = [0.005 , 0.01 , 0.025 , 0.05 , 0.075 , 0.1 , 0.25 , 0.5 , 0.75 , 1.0 , 2.5 , 5.0 , 7.5 , 10.0 , Inf ]
55
+
46
56
# This result is a little messy in that it returns Result.ok for
47
57
# ValidationResult.Accept and an err for the others - this helps transport
48
58
# an error message to callers but could arguably be done in an cleaner way.
@@ -543,6 +553,11 @@ proc validateDataColumnSidecar*(
543
553
544
554
template block_header : untyped = data_column_sidecar.signed_block_header.message
545
555
556
+ beacon_data_column_sidecar_processing_requests_total.inc ()
557
+
558
+ let
559
+ startTick = Moment .now ()
560
+
546
561
# [REJECT] The sidecar's index is consistent with `NUMBER_OF_COLUMNS`
547
562
# -- i.e. `data_column_sidecar.index < NUMBER_OF_COLUMNS`
548
563
if not (data_column_sidecar.index < NUMBER_OF_COLUMNS ):
@@ -657,6 +672,14 @@ proc validateDataColumnSidecar*(
657
672
if not (isNil (dataColumnQuarantine.onDataColumnSidecarCallback)):
658
673
dataColumnQuarantine.onDataColumnSidecarCallback (data_column_sidecar)
659
674
675
+ let
676
+ validationTick = Moment .now ()
677
+ validationDur = validationTick - startTick
678
+
679
+ beacon_data_column_sidecar_gossip_verification_seconds.observe (validationDur.toFloatSeconds ())
680
+
681
+ beacon_data_column_sidecar_processing_successes_total.inc ()
682
+
660
683
ok ()
661
684
662
685
# https://github.com/ethereum/consensus-specs/blob/v1.3.0/specs/phase0/p2p-interface.md#beacon_block
0 commit comments