fix(compression): align zstd behavior across targets - #2400
fix(compression): align zstd behavior across targets#2400gh-worker-dd-mergequeue-cf854d[bot] merged 4 commits into
Conversation
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: e5dc6ef | Docs | View more details | Give us feedback! |
BenchmarksComparisonBenchmark execution time: 2026-08-24 18:46:29 Comparing candidate commit e5dc6ef in PR branch Found 1 performance improvements and 1 performance regressions! Performance is the same for 104 metrics, 10 unstable metrics.
|
Artifact Size Benchmark Reportaarch64-alpine-linux-musl
aarch64-unknown-linux-gnu
libdatadog-x64-windows
libdatadog-x86-windows
x86_64-alpine-linux-musl
x86_64-unknown-linux-gnu
|
|
/merge |
|
View all feedbacks in Devflow UI.
The expected merge time in
|
a25619e
into
main
What does this PR do?
Addresses follow-up review feedback from #2386:
0to level3on every target;-7..=4while preserving native zstd's broader range;Motivation
The zrip WASM backend supports a narrower compression-level range than native zstd and previously assigned a different meaning to level
0. Out-of-range levels also disabled trace compression or failed profile compression under WASM. The target branches duplicated the common encoder flow.This follows up on these review threads:
Additional Notes
Native targets continue to accept the broader range reported by
zstd::compression_level_range(). WASM clamps requested levels to zrip's supported range, so level22becomes4; level0becomes3on every target.The full trace-utils integration binary was not validated locally because Docker could not pull the private GHCR test-agent image. All 348 trace-utils library tests passed. Strict trace-utils clippy also reports an existing
collapsible_matchwarning in unchangedtracer_payload.rs; clippy passes with that lint allowed.This PR was generated by Codex.
How to test the change?
cargo test -p libdd-profilingcargo test -p libdd-trace-utils --features compression --libenv CARGO_TARGET_WASM32_UNKNOWN_UNKNOWN_RUNNER=wasm-bindgen-test-runner cargo test -p libdd-wasm-tests --target wasm32-unknown-unknowncargo +stable clippy -p libdd-profiling --all-targets -- -D warningscargo +stable clippy -p libdd-wasm-tests --target wasm32-unknown-unknown --all-targets -- -D warningscargo +stable clippy -p libdd-trace-utils --all-targets --features compression -- -D warnings -A clippy::collapsible_matchcargo +nightly-2026-07-26 fmt --all -- --checkcargo test -p libdd-profiling --doccargo test -p libdd-trace-utils --features compression --doc