Skip to content

chore(agent-data-plane): update to tokio 1.52 and enable eager driver handoff#1387

Merged
tobz merged 1 commit intomainfrom
tobz/tokio-eager-driver-handoff-1-52-0
Apr 15, 2026
Merged

chore(agent-data-plane): update to tokio 1.52 and enable eager driver handoff#1387
tobz merged 1 commit intomainfrom
tobz/tokio-eager-driver-handoff-1-52-0

Conversation

@tobz
Copy link
Copy Markdown
Member

@tobz tobz commented Apr 15, 2026

Summary

This PR updates tokio to 1.52 which adds support for enabling an experimental feature for eager driver handoff. This relates to how runtime executor threads coordinate to poll tasks that have pending I/O or timer-related notifications. Without this feature, executor threads polling compute-heavy/blocking tasks can cause delays in waking up tasks with pending notifications, leading to high tail latencies, or in some cases, deadlocks.

We've set this (and the alternative timer implementation) at all points where we create a multi-threaded runtime: main in agent-data-plane, creation of the global thread pool for topologies, and the dedicated runtime feature for supervisors.

Change Type

  • Bug fix
  • New feature
  • Non-functional (chore, refactoring, docs)
  • Performance

How did you test this PR?

Ran the integration tests locally just to ensure basic functionality. ADP benchmarks will give the more complete picture in terms of performance.

References

AGTMETRICS-400

@dd-octo-sts dd-octo-sts bot added the area/core Core functionality, event model, etc. label Apr 15, 2026
Copy link
Copy Markdown
Member Author

tobz commented Apr 15, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@tobz tobz added the type/chore Updates to dependencies or general "administrative" tasks necessary to maintain the codebase/repo. label Apr 15, 2026
@tobz tobz marked this pull request as ready for review April 15, 2026 13:37
@tobz tobz requested a review from a team as a code owner April 15, 2026 13:37
@pr-commenter
Copy link
Copy Markdown

pr-commenter bot commented Apr 15, 2026

Binary Size Analysis (Agent Data Plane)

Target: ae930e7 (baseline) vs 6d6e789 (comparison) diff
Analysis Type: Stripped binaries (debug symbols excluded)
Baseline Size: 36.10 MiB
Comparison Size: 36.10 MiB
Size Change: +2.13 KiB (+0.01%)
Pass/Fail Threshold: +5%
Result: PASSED ✅

Changes by Module

Module File Size Symbols
core -24.85 KiB 16605
h2 +22.45 KiB 2285
hyper -19.66 KiB 761
&mut serde_json +15.57 KiB 74
figment +14.17 KiB 673
piecemeal +13.86 KiB 39
anon.e52079ca9e001846ba9068d9fff3caa8.2.llvm.4700167258666280782 +12.09 KiB 1
anon.68778dd675552fb3da84adf9c85ce669.2.llvm.8702964241814038154 -12.09 KiB 1
serde_json -10.99 KiB 234
agent_data_plane::_main::_{{closure}} +10.92 KiB 1
agent_data_plane::main::_{{closure}} -10.47 KiB 1
tokio_util -10.36 KiB 101
saluki_env::workload::providers -9.66 KiB 16
agent_data_plane::cli::run +9.43 KiB 86
datadog_protos::trace_piecemeal_include::datadog -8.77 KiB 20
hashbrown -8.39 KiB 1135
tonic +6.66 KiB 742
agent_data_plane::internal::remote_agent -6.51 KiB 72
chrono -5.67 KiB 28
quick_cache -5.63 KiB 163

Detailed Symbol Changes

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  [NEW]  +158Ki  [NEW]  +158Ki    agent_data_plane::cli::run::handle_run_command::_{{closure}}::hfae9c16d598f78d6
  [NEW] +65.2Ki  [NEW] +65.0Ki    saluki_core::topology::built::BuiltTopology::spawn::_{{closure}}::h96be9784867891d4
  [NEW] +63.8Ki  [NEW] +63.6Ki    agent_data_plane::run_inner::_{{closure}}::h52fe067d92febb3e
  [NEW] +57.6Ki  [NEW] +57.4Ki    saluki_core::topology::blueprint::TopologyBlueprint::build::_{{closure}}::h7a21bc57efaf41fb
  [NEW] +57.4Ki  [NEW] +57.2Ki    agent_data_plane::cli::debug::handle_debug_command::_{{closure}}::h4d9486c52d0c868a
  [NEW] +44.9Ki  [NEW] +44.8Ki    _<figment::value::de::ConfiguredValueDe<I> as serde_core::de::Deserializer>::deserialize_struct::ha36838e4e01f8939
  [NEW] +42.4Ki  [NEW] +42.2Ki    saluki_config::ConfigurationLoader::with_default_secrets_resolution::_{{closure}}::hc912365fb166a9d1
  [NEW] +41.0Ki  [NEW] +40.8Ki    saluki_components::transforms::apm_stats::ApmStats::process_trace::h1c5d574ecdeae1f5
  [NEW] +38.7Ki  [NEW] +38.5Ki    saluki_env::workload::providers::remote_agent::build_collector::_{{closure}}::h4f144f13802f8b02
  [NEW] +38.1Ki  [NEW] +37.9Ki    _<saluki_components::forwarders::otlp::OtlpForwarder as saluki_core::components::forwarders::Forwarder>::run::_{{closure}}::hd6a607b0590753fb
  +0.0% +11.4Ki  +0.1% +23.3Ki    [54911 Others]
  [DEL] -38.4Ki  [DEL] -38.2Ki    _<saluki_components::forwarders::otlp::OtlpForwarder as saluki_core::components::forwarders::Forwarder>::run::_{{closure}}::h079d527704243fab
  [DEL] -40.9Ki  [DEL] -40.8Ki    saluki_components::transforms::apm_stats::ApmStats::process_trace::h90f4eec3a560481a
  [DEL] -42.1Ki  [DEL] -41.9Ki    saluki_config::ConfigurationLoader::with_default_secrets_resolution::_{{closure}}::hb4aabf78a98cbe9f
  [DEL] -45.3Ki  [DEL] -45.2Ki    _<figment::value::de::ConfiguredValueDe<I> as serde_core::de::Deserializer>::deserialize_struct::h4e679317fe729f3a
  [DEL] -57.4Ki  [DEL] -57.2Ki    saluki_env::workload::providers::remote_agent::RemoteAgentWorkloadProvider::from_configuration::_{{closure}}::hb7df100b3cc960a6
  [DEL] -57.5Ki  [DEL] -57.4Ki    agent_data_plane::cli::debug::handle_debug_command::_{{closure}}::hd14ca2879355df26
  [DEL] -57.6Ki  [DEL] -57.4Ki    saluki_core::topology::blueprint::TopologyBlueprint::build::_{{closure}}::hf1b6c8b0b25d4b47
  [DEL] -63.5Ki  [DEL] -63.3Ki    agent_data_plane::run_inner::_{{closure}}::hdc4f73c19a777f82
  [DEL] -65.1Ki  [DEL] -64.9Ki    saluki_core::topology::built::BuiltTopology::spawn::_{{closure}}::h8892e5698e33785c
  [DEL]  -148Ki  [DEL]  -148Ki    agent_data_plane::cli::run::handle_run_command::_{{closure}}::he300a7bd8144e276
  +0.0% +2.13Ki  +0.0% +14.1Ki    TOTAL

@pr-commenter
Copy link
Copy Markdown

pr-commenter bot commented Apr 15, 2026

Regression Detector (Agent Data Plane)

This comment was omitted because it was over 65,536 characters.Please check the Gitlab Job logs to see its output.

@tobz tobz force-pushed the tobz/tokio-eager-driver-handoff-1-52-0 branch from 8e8438d to 6d6e789 Compare April 15, 2026 15:00
@tobz tobz merged commit 921d53e into main Apr 15, 2026
63 of 64 checks passed
@tobz tobz deleted the tobz/tokio-eager-driver-handoff-1-52-0 branch April 15, 2026 15:42
Copilot AI pushed a commit that referenced this pull request Apr 15, 2026
… handoff (#1387)

Co-authored-by: webern <6260372+webern@users.noreply.github.com>
thieman added a commit that referenced this pull request Apr 15, 2026
thieman added a commit that referenced this pull request Apr 16, 2026
thieman added a commit that referenced this pull request Apr 16, 2026
…r handoff (#1405)

Reverts #1387. We were seeing flaky correctness tests
since this and it's been confirmed as an upstream issue
tokio-rs/tokio#8056
dd-octo-sts bot pushed a commit that referenced this pull request Apr 16, 2026
…r handoff (#1405)

Reverts #1387. We were seeing flaky correctness tests
since this and it's been confirmed as an upstream issue
tokio-rs/tokio#8056 fb1219f
thieman added a commit that referenced this pull request Apr 17, 2026
…river handoff

Re-applies the changes from #1387 (reverted in #1405 due to upstream bug
tokio-rs/tokio#8056) with tokio bumped to 1.52.1
which includes the fix.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/core Core functionality, event model, etc. mergequeue-status: done type/chore Updates to dependencies or general "administrative" tasks necessary to maintain the codebase/repo.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants