Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
4f6193a
init process tags for APM
dubloom Jan 9, 2026
1046984
feat(process_tags): add process_tags to tracing payloads
dubloom Jan 9, 2026
6501e1e
small auto review and fix test
dubloom Jan 12, 2026
127c555
bwoebi review
dubloom Jan 13, 2026
0bb55a1
Merge branch 'master' into dubloom/process-tags
dubloom Jan 13, 2026
3a8038c
fix test
dubloom Jan 13, 2026
7c56e32
Merge branch 'master' into dubloom/process-tags
dubloom Jan 15, 2026
ab3fbea
adds process tags to crashtracker tags
dubloom Jan 15, 2026
de48e39
Merge branch 'master' into dubloom/process-tags
dubloom Jan 16, 2026
67e08df
Move process tags assign
bwoebi Jan 16, 2026
89c75b2
Merge branch 'master' into dubloom/process-tags
dubloom Jan 19, 2026
31f4a49
Merge branch 'dubloom/process-tags' into dubloom/process-tags-crashtr…
dubloom Jan 19, 2026
dae6e43
auto review
dubloom Jan 19, 2026
6f0ea77
Merge branch 'master' into dubloom/process-tags-crashtracking
dubloom Jan 19, 2026
96b8463
Merge branch 'master' into dubloom/process-tags-crashtracking
dubloom Feb 11, 2026
b782dd0
Merge branch 'master' into dubloom/process-tags-crashtracking
dubloom Feb 12, 2026
0bf02ca
fix tests
dubloom Feb 12, 2026
3a2b419
fix crashtracker test
dubloom Feb 12, 2026
d1c741b
test only on 7.2+
dubloom Feb 12, 2026
60b1ff1
Merge branch 'master' into dubloom/process-tags-crashtracking
dubloom Feb 17, 2026
8d75740
Merge branch 'master' into dubloom/process-tags-crashtracking
dubloom Feb 17, 2026
bee5232
bump libdatadog and update tests
dubloom Feb 17, 2026
31ca15c
merge process_tags into existing tests
dubloom Feb 17, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions ext/sidecar.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
#include "process_tags.h"
#include "serializer.h"
#include "remote_config.h"
#include "process_tags.h"
#ifndef _WIN32
#include "coms.h"
#endif
Expand Down Expand Up @@ -646,6 +647,11 @@ ddog_crasht_Metadata ddtrace_setup_crashtracking_metadata(ddog_Vec_Tag *tags) {
const char *runtime_version = zend_get_module_version("Reflection");
ddtrace_sidecar_push_tag(tags, DDOG_CHARSLICE_C("runtime_version"), (ddog_CharSlice) {.ptr = (char *) runtime_version, .len = strlen(runtime_version)});

zend_string *process_tags = ddtrace_process_tags_get_serialized();
if (ZSTR_LEN(process_tags)) {
ddtrace_sidecar_push_tag(tags, DDOG_CHARSLICE_C("process_tags"), (ddog_CharSlice) {.ptr = ZSTR_VAL(process_tags), .len = ZSTR_LEN(process_tags)});
}

return (ddog_crasht_Metadata){
.library_name = DDOG_CHARSLICE_C_BARE("dd-trace-php"),
.library_version = DDOG_CHARSLICE_C_BARE(PHP_DDTRACE_VERSION),
Expand Down
4 changes: 4 additions & 0 deletions tests/ext/crashtracker_segfault.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ include __DIR__ . '/includes/skipif_no_dev_env.inc';
DD_TRACE_LOG_LEVEL=0
DD_AGENT_HOST=request-replayer
DD_TRACE_AGENT_PORT=80
DD_EXPERIMENTAL_PROPAGATE_PROCESS_TAGS_ENABLED=1
--INI--
datadog.trace.agent_test_session_token=tests/ext/crashtracker_segfault.phpt
--FILE--
Expand Down Expand Up @@ -43,6 +44,8 @@ $rr->waitForRequest(function ($request) {
continue;
}

echo $json["application"]["process_tags"], PHP_EOL;

foreach ($json["payload"]["logs"] as $payload) {
$payload["message"] = json_decode($payload["message"], true);
if (!isset($payload["message"]["metadata"])) {
Expand All @@ -63,6 +66,7 @@ $rr->waitForRequest(function ($request) {
});
?>
--EXPECTF--
%Aentrypoint.name:standard_input_code,entrypoint.type:script,entrypoint.workdir:%s,runtime.sapi:cli
%A{
"message": {
%A
Expand Down
4 changes: 4 additions & 0 deletions tests/ext/crashtracker_segfault_windows.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ include __DIR__ . '/includes/skipif_no_dev_env.inc';
DD_TRACE_LOG_LEVEL=0
DD_AGENT_HOST=request-replayer
DD_TRACE_AGENT_PORT=3188
DD_EXPERIMENTAL_PROPAGATE_PROCESS_TAGS_ENABLED=1
--INI--
datadog.trace.agent_test_session_token=tests/ext/crashtracker_segfault_windows.phpt
--FILE--
Expand Down Expand Up @@ -56,6 +57,8 @@ $rr->waitForRequest(function ($request) {
continue;
}

echo $json["application"]["process_tags"], PHP_EOL;

foreach ($json["payload"]["logs"] as $payload) {
$payload["message"] = json_decode($payload["message"], true);
if (!isset($payload["message"]["metadata"])) {
Expand All @@ -73,6 +76,7 @@ $rr->waitForRequest(function ($request) {
});
?>
--EXPECTF--
%Aentrypoint.name:standard_input_code,entrypoint.type:script,entrypoint.workdir:%s,runtime.sapi:cli
%A{
"message": {
"data_schema_version": "1.2",
Expand Down
Loading