Wire extended heartbeat interval through sidecar#3800
Draft
khanayan123 wants to merge 2 commits intomasterfrom
Draft
Wire extended heartbeat interval through sidecar#3800khanayan123 wants to merge 2 commits intomasterfrom
khanayan123 wants to merge 2 commits intomasterfrom
Conversation
The libdatadog telemetry worker already supports telemetry_extended_heartbeat_interval in its Config, but the sidecar's SessionConfig and FFI layer did not expose it. This meant PHP (and any other sidecar consumer) could not configure the extended heartbeat interval, preventing app-extended-heartbeat events from being emitted at the desired cadence. Changes: - libdatadog sidecar: add telemetry_extended_heartbeat_interval to SessionConfig and propagate it into the telemetry Config inside modify_telemetry_config - libdatadog sidecar-ffi: add telemetry_extended_heartbeat_interval_millis parameter to ddog_sidecar_session_set_config - PHP ext: add DD_TELEMETRY_EXTENDED_HEARTBEAT_INTERVAL config (default 86400 s = 24 h) and pass it through the FFI call - C header: update ddog_sidecar_session_set_config signature Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add DD_TELEMETRY_EXTENDED_HEARTBEAT_INTERVAL entry to keep metadata in sync with ext/configuration.h. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
✅ Tests 🎉 All green!❄️ No new flaky tests detected 🎯 Code Coverage (details) 🔗 Commit SHA: c038e78 | Docs | Datadog PR Page | Was this helpful? React with 👍/👎 or give us feedback! |
Benchmarks [ tracer ]Benchmark execution time: 2026-04-15 19:33:06 Comparing candidate commit c038e78 in PR branch Found 1 performance improvements and 3 performance regressions! Performance is the same for 190 metrics, 0 unstable metrics. scenario:MessagePackSerializationBench/benchMessagePackSerialization-opcache
scenario:PDOBench/benchPDOOverhead-opcache
scenario:PDOBench/benchPDOOverheadWithDBM-opcache
scenario:PHPRedisBench/benchRedisOverhead
|
gh-worker-dd-mergequeue-cf854d bot
pushed a commit
to DataDog/libdatadog
that referenced
this pull request
Apr 17, 2026
…sionConfig (#1882) ## Summary Add `telemetry_extended_heartbeat_interval` to the sidecar's `SessionConfig` and FFI layer so that callers (e.g. PHP tracer) can configure the extended heartbeat interval. The telemetry worker already supports this field in its `Config` struct, but the sidecar was not passing it through from `SessionConfig` -> `modify_telemetry_config`. This meant sidecar consumers could not control the cadence of `app-extended-heartbeat` events. **Changes:** - `datadog-sidecar/src/service/mod.rs`: add `telemetry_extended_heartbeat_interval: Duration` to `SessionConfig` - `datadog-sidecar/src/service/sidecar_server.rs`: set `cfg.telemetry_extended_heartbeat_interval` in `modify_telemetry_config` - `datadog-sidecar-ffi/src/lib.rs`: add `telemetry_extended_heartbeat_interval_millis: u64` param to `ddog_sidecar_session_set_config` Companion dd-trace-php PR: DataDog/dd-trace-php#3800 Co-authored-by: bwoebi <bob.weinand@datadoghq.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The libdatadog telemetry worker already supports
telemetry_extended_heartbeat_intervalin its
Config(added in libdatadog PR #1824), but the sidecar'sSessionConfigandFFI layer did not expose it. This meant PHP (and any other sidecar consumer) could not
configure the extended heartbeat interval, preventing
app-extended-heartbeateventsfrom being emitted at the desired cadence.
Changes:
libdatadog sidecar
SessionConfig(datadog-sidecar/src/service/mod.rs):add
telemetry_extended_heartbeat_interval: Durationfieldlibdatadog sidecar server (
datadog-sidecar/src/service/sidecar_server.rs):propagate the new field into the telemetry
Configinsidemodify_telemetry_configlibdatadog sidecar FFI (
datadog-sidecar-ffi/src/lib.rs):add
telemetry_extended_heartbeat_interval_millis: u64parameter toddog_sidecar_session_set_configand wire it intoSessionConfigPHP C header (
components-rs/sidecar.h):update
ddog_sidecar_session_set_configsignature with the new parameterPHP configuration (
ext/configuration.h):add
DD_TELEMETRY_EXTENDED_HEARTBEAT_INTERVALconfig (default86400s = 24 hours),matching the default in
libdd-telemetryPHP sidecar call (
ext/sidecar.c):pass
DD_TELEMETRY_EXTENDED_HEARTBEAT_INTERVALthrough the FFI callNote: The libdatadog submodule is pointed at branch
ayan.khan/wire-extended-heartbeat-sidecarwhich contains the Rust-side changes.A companion libdatadog PR will be needed to merge those changes to
mainfirst,then the submodule pointer can be updated to the merged commit.
Reviewer checklist