fix(telemetry): use underscore attr names and SpanNames constants in Phase 4

- tempo.yaml: align consensus filter tags with emitted keys
  (consensus_mode, consensus_round, ledger_seq) instead of dotted form
- haveConsensus(): set span attributes before early-return paths so the
  consensus.check span carries diagnostics even when consensus is not reached
- replace hardcoded consensus phase/result/vote literals with
  ConsensusSpanNames.h val constants; add val::phaseOpen/Establish/Accepted
- ConsensusReceiveTracing.h: use canonical consensus::span constants instead
  of duplicate inline detail:: names
- SpanGuardFactory test: use rpc_span / consensus::span constants now that
  levelization permits the dependency

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Pratik Mankawde
2026-06-10 17:07:10 +01:00
parent 4a0994209e
commit ffc197b914
10 changed files with 93 additions and 73 deletions

View File

@@ -126,17 +126,17 @@ datasources:
type: dynamic
# Phase 4: Consensus tracing filters
- id: consensus-mode
tag: xrpl.consensus.mode
tag: consensus_mode
operator: "="
scope: span
type: static
- id: consensus-round
tag: xrpl.consensus.round
tag: consensus_round
operator: "="
scope: span
type: dynamic
- id: consensus-ledger-seq
tag: xrpl.ledger.seq
tag: ledger_seq
operator: "="
scope: span
type: static