mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-01-09 13:28:01 -05:00
This commit adds a Prometheus histogram metric to measure the processing duration of the PublishBlockV2 beacon API endpoint in milliseconds. The metric covers the complete request processing time including: - Request validation and parsing - Block decoding (SSZ/JSON) - Broadcast validation checks - Block proposal through ProposeBeaconBlock - All synchronous operations and awaited goroutines Background operations that run in goroutines (block broadcasting, blob sidecar processing) are included in the timing since the main function waits for their completion before returning. Files changed: - beacon-chain/rpc/eth/beacon/metrics.go: New metric definition - beacon-chain/rpc/eth/beacon/handlers.go: Timing instrumentation - beacon-chain/rpc/eth/beacon/BUILD.bazel: Added metrics.go and Prometheus deps - changelog/potuz_add_publishv2_metric.md: Changelog entry 🤖 Generated with [Claude Code](https://claude.ai/code) Co-authored-by: Claude <noreply@anthropic.com>
147 B
147 B
Added
- Add timing metric
publish_block_v2_duration_millisecondsto measure processing duration of thePublishBlockV2beacon API endpoint.