fix(crashtracking)!: flatten all threads object into a list of ThreadData#2054
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
ThreadData
|
📚 Documentation Check Results📦
|
Clippy Allow Annotation ReportComparing clippy allow annotations between branches:
Summary by Rule
Annotation Counts by File
Annotation Stats by Crate
About This ReportThis report tracks Clippy allow annotations for specific rules, showing how they've changed in this PR. Decreasing the number of these annotations generally improves code quality. |
🔒 Cargo Deny Results📦
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #2054 +/- ##
=======================================
Coverage 72.90% 72.91%
=======================================
Files 460 460
Lines 76396 76430 +34
=======================================
+ Hits 55696 55728 +32
- Misses 20700 20702 +2
🚀 New features to boost your workflow:
|
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
|
gleocadie
left a comment
There was a problem hiding this comment.
overall LGTM, maybe a Rust aficionado would help reviewing specifics
| - Version 1.6+: Root level may include a `ucontext` field for UNIX signal crashes | ||
| - Version 1.7+: `error.threads` is a `Threads` object (with `threads`, `count`, and `incomplete` fields) rather than a bare array | ||
| - Version 1.7: `error.threads` is a `Threads` wrapper object (with nested `threads`, `count`, and `incomplete` fields) rather than a bare array | ||
| - Version 1.8+: `error.threads` is a bare array of thread objects again; the wrapper is removed. Partial collection is indicated by `counters.threads_incomplete` |
#What does this PR do? Bumps the libdatadog workspace version from 34.0.0 → 35.0.0 (Cargo.toml + regenerated Cargo.lock) to cut the 35.0.0 release. Breaking changes affecting the FFI layer (34.0.0 → 35.0.0) 1. Tracer FFI: response body now returned as ByteSlice (#2029) — feat! - ddog_trace_exporter_response_get_body no longer takes an out_len: *mut usize out-parameter and returns *const u8. It now returns a single ByteSlice value, matching the slice conventions in libdd-common-ffi. - Tracer constructor functions now validate nullable pointers and return ErrorCode::InvalidArgument instead of risking UB; panics across the boundary are caught and surfaced as ErrorCode::Panic. - C consumers (e.g. dd-trace-rb) can now reuse the standard read_ddogerr_string_and_drop / get_error_details_and_drop helpers from datadog_ruby_common.h. - Action for callers: drop the out_len argument and read length/pointer from the returned ByteSlice. 2. Crashtracker: error.threads flattened to []ThreadData (#2054) — fix(crashtracking)! - The crash-report payload now emits error.threads as an optional flat array of thread objects (unified runtime stack schema 1.8) instead of the previous nested threads object. - This is a wire/payload-format change consumed by downstream pipelines and the product UI. - Action for callers: consumers parsing crash reports must update to the 1.8 thread layout. Other breaking changes since 34.0.0 (Rust API, not C ABI) These are !-marked breaking changes in libdd-trace-utils that affect Rust consumers of the library but do not change the C FFI surface or generated headers: - feat(trace-utils)!: introduce VecMap datastructure (#2022) — adds a HashMap replacement optimized for span construction (not yet wired into span fields). - feat(trace-utils)!: add from_string to span text (#2011) — requires From<String> on SpanText and switches SpanSlice to Cow<str> to allow span-field mutation/normalization. Notable new FFI surface (additive) - feat: Add FFI for trace exporter (#1952) — new tracer FFI surface in libdd-data-pipeline-ffi (the change above, #2029, refines it). Co-authored-by: julio.gonzalez <julio.gonzalez@datadoghq.com>

What does this PR do?
PROF-14817
Flattens
error.threadsto an optional array of thread objects (schema 1.8) so crash reports match what downstream pipelines expect.Motivation
Product UI expects
[]ThreadDatafor renderingAdditional Notes
Anything else we should know when reviewing?
How to test the change?
Unit tests updated. Manual payload testing.