Skip to content

[Backport v1.28] enable CNM direct send by default#3103

Merged
tbavelier merged 1 commit into
v1.28from
backport-3045-to-v1.28
Jun 8, 2026
Merged

[Backport v1.28] enable CNM direct send by default#3103
tbavelier merged 1 commit into
v1.28from
backport-3045-to-v1.28

Conversation

@dd-octo-sts

@dd-octo-sts dd-octo-sts Bot commented Jun 8, 2026

Copy link
Copy Markdown

Backport 5c6a923 from #3045.


What does this PR do?

Enables CNM/USM direct send if agent version is >= 7.81.0

Motivation

Enabling direct send at the operator level first.

Additional Notes

  • Fixes environment variable not being set on process-agent container when Direct Send is disabled.
  • 7.81.0 is not yet released, but this is the first agent version that can support Direct Send regardless of node kernel version.

Minimum Agent Versions

  • Agent: v7.81.0
  • Cluster Agent: n/a

Describe your test plan

  • Add agent.datadoghq.com/cnm-direct-send-enabled=true annotation

    • With <7.80 ensure CNM direct send is NOT enabled:
      • DD_NETWORK_CONFIG_DIRECT_SEND=false
      • direct sender started log should NOT be present in system-probe logs.
      • process-agent container should be present
    • With 7.81+ ensure CNM direct is enabled:
      • DD_NETWORK_CONFIG_DIRECT_SEND=true
      • direct sender started log should be present in system-probe logs.
      • process-agent container should NOT be present
  • Set agent.datadoghq.com/cnm-direct-send-enabled=false annotation

    • With any agent version:
      • DD_NETWORK_CONFIG_DIRECT_SEND=false
      • direct sender started log should NOT be present in system-probe logs.
      • process-agent container should be present

Checklist

  • PR has at least one valid label: bug, enhancement, refactoring, documentation, tooling, and/or dependencies
  • PR has a milestone or the qa/skip-qa label
  • All commits are signed (see: signing commits)

enable CNM direct send by default

fix default test

proper fix

add test for USM defaults if enabled

use annotation instead of CRD

re-generate

fix default

fix default test

fix process-agent apparmor

default to false for unknown versions

Co-authored-by: bryce.kahle <[email protected]>
(cherry picked from commit 5c6a923)
@dd-octo-sts dd-octo-sts Bot added enhancement New feature or request mergequeue-status: done backport label added by backport action bot label added by backport bot team/cloud-network-monitoring team/container-platform labels Jun 8, 2026
@dd-octo-sts
dd-octo-sts Bot requested a review from a team as a code owner June 8, 2026 06:56
@dd-octo-sts
dd-octo-sts Bot requested review from a team as code owners June 8, 2026 06:56
@dd-octo-sts
dd-octo-sts Bot requested a review from Janaeq June 8, 2026 06:56
@dd-octo-sts dd-octo-sts Bot added this to the v1.28.0 milestone Jun 8, 2026
@datadog-prod-us1-3

datadog-prod-us1-3 Bot commented Jun 8, 2026

Copy link
Copy Markdown

Code Coverage

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 43.96% (+0.02%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 3ed142c | Docs | Datadog PR Page | Give us feedback!

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3ed142c465

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread api/datadoghq/v2alpha1/datadogagent_types.go
@codecov-commenter

codecov-commenter commented Jun 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 43.64%. Comparing base (5ac71e6) to head (3ed142c).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##            v1.28    #3103      +/-   ##
==========================================
+ Coverage   43.62%   43.64%   +0.01%     
==========================================
  Files         350      350              
  Lines       30089    30097       +8     
==========================================
+ Hits        13127    13135       +8     
  Misses      16090    16090              
  Partials      872      872              
Flag Coverage Δ
unittests 43.64% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...nal/controller/datadogagent/feature/npm/feature.go 88.46% <100.00%> (+0.46%) ⬆️
...nal/controller/datadogagent/feature/usm/feature.go 84.31% <100.00%> (+0.64%) ⬆️
...nal/controller/datadogagent/feature/utils/utils.go 0.00% <ø> (ø)

Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5ac71e6...3ed142c. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@tbavelier
tbavelier merged commit f7ac48f into v1.28 Jun 8, 2026
84 of 90 checks passed
@tbavelier
tbavelier deleted the backport-3045-to-v1.28 branch June 8, 2026 14:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants