You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Record client operation durations for Kafka and Service Bus sends #296
During #273 outgoing adapter work, comparison with existing adapters found that native Kafka and Service Bus sends do not record the required Relayer client-operation duration histogram.
Evidence:
src/Relayer/Telemetry/SendTracing.cs creates an EndpointTelemetry and calls RecordSent, but never RecordDuration.
src/Relayer.Kafka/KafkaProducerTransport.cs and src/Relayer.AzureServiceBus/ServiceBusSendTransport.cs wrap sends with SendTracing but have no RecordDuration call or endpoint operation timer.
docs/design.md section 8.4 requires messaging.client.operation.duration for each send, including native operation completion.
Reproduction: attach a MeterListener to meter Relayer and instrument messaging.client.operation.duration; complete a successful or failing send through either adapter. The sent counter is recorded, but no send duration is emitted. Native-client metrics are separate and do not fill the Relayer instrument.
Expected: record one duration per actual native single or batch send operation, including confirmation/acknowledgement time, with the correct system/destination/server dimensions and bounded error.type on failure. Outbox enqueue must not count as a broker send. Avoid recording the same operation twice at the pipeline and adapter boundaries.
Acceptance:
Add listener tests for successful and failed direct sends, homogeneous/mixed batches and outbox dispatch.
Reuse the existing telemetry instruments and native instrumentation; do not add parallel meters or spans.
Validate any material steady-state cost with the native comparison benchmarks and update documentation.
Activity
fix: retain measured Kafka send completions (#296)
fix: record native Kafka and Service Bus send durations (#296)
fix: retain measured Kafka send completions (#296)
fix: share metrics across Service Bus benchmark paths (#296)
fix: record native Kafka and Service Bus send durations (#301)