Skip to content

Adopt the instrumentation framework for dsx-exchange-consumer counters #3427

Description

@chet

The DSX exchange consumer's message counters are hand-rolled instruments, several sitting right beside a matching log line. Folding them into the instrumentation framework brings the consumer inline with the rest of the fleet, with no change to any exposed metric.

What this involves

  • crates/dsx-exchange-consumer/src/metrics.rs plus the call sites in mqtt_consumer.rs / health_updater.rs: convert the four label-free counters (messages_received_total, messages_processed_total, messages_dropped_total, dedup_skipped_total) to #[derive(Event)] events. The binary already installs the global meter, so framework emits export as-is.
  • Where a counter sits beside a log line -- the queue-full warn! and the dedup trace! -- the event owns that line at its historical level.
  • Leave alerts_detected_total out of this PR: its point_type label is a caller-supplied string that needs a hand-written bounded mapping, which deserves its own change.
  • Preserve every exposed metric exactly -- names (already _total-suffixed), types, and the binary's own /metrics output byte-identical before and after; confirm no golden fixture moves.

Part of #3169.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Fields

No fields configured for Task.

Projects

Status
Closed

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions