Repository navigation
Conversation
the signature read http.status_code only as a string, so an otlp span with a numeric code left the code out and two traces differing only in the code shared one signature. hash a numeric code in the range 100 to 599 as a four-byte integer. string codes still hash as text.
adp now keeps both feat.rare.status traces, so the case expects all 23 traces and spans.
|
AI review by Claude - workflow run Patch is correct, with 0 blocking findings. A numeric
Not blocking:
Not blocking: take it or leave it. The sampler now imports from
Nit: we import items instead of using paths like |
There was a problem hiding this comment.
More details
Numeric HTTP status codes now distinguish sampling signatures while preserving existing text-code hashing. No actionable defect was identified.
🤖 Bits Code Review · Commit eda7c2e
Move the HTTP status code bounds to common::datadog so the sampler no longer imports from the OTLP translator, and import the hash helpers in the signature tests.
|
Addressed in 23891ec: the status code bounds moved to
|
Binary Size Analysis (Agent Data Plane)Baseline: ca99ce7 · Comparison: 23891ec · diff ✅ Binary size difference within thresholdChanges by Module
Detailed Symbol Changes |
Regression Detector (Agent Data Plane)Run ID: Optimization Goals: ✅ No significant changes detectedFine details of change detection per experiment (5)Experiments configured
Bounds Checks: ✅ Passed (5)
ExplanationA change is flagged as a regression when |Δ mean %| > 5.00% in the regressing direction for its optimization goal AND SMP marks the experiment as a regression ( |
Summary
The rare sampler keeps a trace when a span has a signature it has not seen recently. An OTLP span stores its HTTP status code as a number, and the signature only read it as text, so two traces that differ only in status code, for example 200 and 404, shared a signature. The second one was dropped during the cooldown.
The signature now includes a numeric status code. Spans with a text status code, such as those from Datadog tracers, are hashed as before. The number of extra rare traces is bounded by the sampler's existing rate limit.
The same span hash also feeds the score and error samplers, so their signatures now separate these traces too. The Agent hashes the status code into all three, so this matches it.
Change Type
How did you test this PR?
cargo nextest run -p saluki-componentson the trace sampler tests,cargo clippy -p saluki-components --tests,make fmtandmake check-docs.otlp-traces-obfuscation-featurescorrectness case. I did not run the case, because it needs Docker.References