Skip to content

Commit 23f1c6f

Browse files
committed
Instrument gap count
1 parent ac50f90 commit 23f1c6f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

app/services/eth_block_importer.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,9 @@ def validation_stalled?
448448
check_range_end = current_position
449449

450450
# Count ALL missing validations in critical range (includes both gaps and lag)
451+
ImportProfiler.start("validation_gap_count")
451452
gap_count = ValidationResult.validation_gap_count(check_range_start, check_range_end)
453+
ImportProfiler.stop("validation_gap_count")
452454

453455
if gap_count >= hard_limit
454456
Rails.logger.error "Too many validation gaps: #{gap_count} unvalidated blocks in range #{check_range_start}-#{check_range_end} (limit: #{hard_limit})"

0 commit comments

Comments
 (0)