Skip to content

Commit

Permalink
DEBUG-2334 correctly serialize debugger input payloads (#4125)
Browse files Browse the repository at this point in the history
  • Loading branch information
p-datadog authored Nov 18, 2024
1 parent ba9f79f commit d75902e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/datadog/di/probe_notification_builder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ def build_snapshot(probe, rv: nil, snapshot: nil, path: nil,
version: 2,
},
# TODO add tests that the trace/span id is correctly propagated
"dd.trace_id": Datadog::Tracing.active_trace&.id,
"dd.span_id": Datadog::Tracing.active_span&.id,
"dd.trace_id": Datadog::Tracing.active_trace&.id&.to_s,
"dd.span_id": Datadog::Tracing.active_span&.id&.to_s,
ddsource: 'dd_debugger',
message: probe.template && evaluate_template(probe.template,
duration: duration ? duration * 1000 : nil),
Expand Down
2 changes: 1 addition & 1 deletion lib/datadog/di/transport.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def send_diagnostics(payload)

def send_input(payload)
send_request('Probe snapshot submission',
path: INPUT_PATH, body: payload.to_s,
path: INPUT_PATH, body: payload.to_json,
headers: {'content-type' => 'application/json'},)
end

Expand Down

0 comments on commit d75902e

Please sign in to comment.