Skip to content

Commit 6856b31

Browse files
committed
Merge branch 'main' into niharikag09/otel-url-template-resource-name
2 parents 11aa9c6 + 9c12327 commit 6856b31

792 files changed

Lines changed: 13249 additions & 9463 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.bazelrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ common:ci --noexperimental_convenience_symlinks # not CI-suitable: "These symlin
110110
common:ci --remote_download_regex=.*/test\.xml$ # force-download test.xml even under --remote_download_outputs=toplevel, so junit collection can read it locally
111111

112112
# Project/Language configs --------------------------------------------------------------------------------------
113-
import %workspace%/bazel/configs/flavors.bazelrc
113+
import %workspace%/bazel/configs/go_tests.bazelrc
114114
import %workspace%/bazel/configs/rust.bazelrc
115115

116116
# Global release config ------------------------------------------------------------------------------------------------

.github/CODEOWNERS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,7 @@
409409
/comp/core/configstream @DataDog/fleet-automation
410410
/comp/core/configstreamconsumer @DataDog/fleet-automation
411411
/comp/core/configsync @DataDog/fleet-automation
412+
/comp/core/delegatedauth @DataDog/credential-management
412413
/comp/core/diagnose @DataDog/fleet-remediation
413414
/comp/core/flare @DataDog/fleet-remediation
414415
/comp/core/gui @DataDog/fleet-remediation
@@ -687,6 +688,7 @@
687688
/pkg/tagset/ @DataDog/agent-runtimes
688689
/pkg/util/ @DataDog/agent-runtimes
689690
/pkg/util/aggregatingqueue @DataDog/container-integrations @DataDog/container-platform
691+
/pkg/util/aws/creds/ @DataDog/credential-management
690692
/pkg/util/cloudproviders/cloudfoundry/ @DataDog/agent-integrations
691693
/pkg/util/clusteragent/ @DataDog/container-platform
692694
/pkg/util/confmaputils @DataDog/opentelemetry-agent @DataDog/profiling-full-host

.gitlab-ci.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -474,12 +474,15 @@ variables:
474474

475475
# fakeintake changes that rebuild the published image (server binary only).
476476
# Client/CLI/docs changes don't. Keep in sync with _is_server_file() in tasks/fakeintake.py.
477+
# Only `.go` files under the server paths matter: the image is built from the Go sources
478+
# via test/fakeintake/Dockerfile, so BUILD.bazel and test fixtures don't affect it
479+
# (rules:changes has no exclusion syntax, hence the extension in the glob).
477480
.fakeintake_server_paths: &fakeintake_server_paths
478481
paths:
479-
- test/fakeintake/cmd/server/**/*
480-
- test/fakeintake/server/**/*
481-
- test/fakeintake/aggregator/**/*
482-
- test/fakeintake/api/**/*
482+
- test/fakeintake/cmd/server/**/*.go
483+
- test/fakeintake/server/**/*.go
484+
- test/fakeintake/aggregator/**/*.go
485+
- test/fakeintake/api/**/*.go
483486
- test/fakeintake/go.mod
484487
- test/fakeintake/go.sum
485488
- test/fakeintake/Dockerfile

.gitlab/build/bazel/test.yml

Lines changed: 19 additions & 109 deletions
Original file line numberDiff line numberDiff line change
@@ -33,33 +33,33 @@
3333
- dda inv -- -e gitlab.generate-ci-visibility-links --output=$EXTERNAL_LINKS_PATH
3434

3535
bazel:test:linux-amd64:
36-
extends: [ .bazel:test:reporting, .bazel:runner:linux-amd64, .bazel:test ]
36+
extends: [.bazel:test:reporting, .bazel:runner:linux-amd64, .bazel:test]
3737
script:
3838
- !reference [.bazel:test:reporting:ci_links]
39-
- bazel test --jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --config=no-dd-agent-go-tests //...
39+
- bazel test --config=gorace --jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE //...
4040

4141
bazel:test:linux-arm64:
42-
extends: [ .bazel:test:reporting, .bazel:runner:linux-arm64, .bazel:test ]
42+
extends: [.bazel:test:reporting, .bazel:runner:linux-arm64, .bazel:test]
4343
script:
4444
- !reference [.bazel:test:reporting:ci_links]
45-
- bazel test --jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --config=no-dd-agent-go-tests //...
45+
- bazel test --config=gorace --jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE //...
4646

4747
bazel:test:macos-amd64:
48-
extends: [ .bazel:test:reporting, .bazel:runner:macos-amd64, .bazel:test ]
48+
extends: [.bazel:test:reporting, .bazel:runner:macos-amd64, .bazel:test]
4949
script:
5050
- !reference [.install_python_dependencies]
5151
- !reference [.bazel:test:reporting:ci_links]
52-
- bazel test --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --config=no-dd-agent-go-tests //...
52+
- bazel test --config=gorace --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE //...
5353
after_script:
5454
- !reference [.install_python_dependencies]
5555
- !reference [.bazel:test:reporting, after_script]
5656

5757
bazel:test:macos-arm64:
58-
extends: [ .bazel:test:reporting, .bazel:runner:macos-arm64, .bazel:test ]
58+
extends: [.bazel:test:reporting, .bazel:runner:macos-arm64, .bazel:test]
5959
script:
6060
- !reference [.install_python_dependencies]
6161
- !reference [.bazel:test:reporting:ci_links]
62-
- bazel test --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --execution_log_compact_file=$CI_PROJECT_DIR/bazel-exec.log --config=no-dd-agent-go-tests //...
62+
- bazel test --config=gorace --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --execution_log_compact_file=$CI_PROJECT_DIR/bazel-exec.log //...
6363
after_script:
6464
- !reference [.install_python_dependencies]
6565
- !reference [.bazel:test:reporting, after_script]
@@ -69,112 +69,22 @@ bazel:test:macos-arm64:
6969
- bazel-bep-*.json
7070
- bazel-exec.log
7171

72+
# Windows splits the build from the Go tests, unlike the other platforms: the
73+
# runner has 16 CPUs, and compiling the rest of the repo alongside ~1k
74+
# race-instrumented tests starves them enough that tests waiting on wall-clock
75+
# time fail. This job covers everything but the Go tests.
7276
bazel:test:windows-amd64:
73-
extends: [ .bazel:runner:windows-amd64, .bazel:test ]
77+
extends: [.bazel:runner:windows-amd64, .bazel:test]
7478
variables:
7579
POWERSHELL_SCRIPT: >-
76-
bazel test --keep_going --config=no-dd-agent-go-tests
77-
//... --
80+
bazel test --config=gorace --config=no-dd-agent-go-tests --keep_going //... --
7881
-//bazel/rules/dd_packaging/...
7982
-//packages/agent/linux/...
8083
81-
# Per-flavor test jobs. Each runs the tests for one agent flavor, mirroring the
82-
# dda inv test --flavor=<f> topology. --config=<flavor> sets
83-
# --test_tag_filters=flavor_<flavor>, selecting only the matching go_test variants.
84-
.bazel:test:flavor:
85-
extends: [ .bazel:test, .bazel:test:reporting ]
86-
script:
87-
- DD_API_KEY=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $AGENT_API_KEY_ORG2 token) || echo 'Failed to fetch an API key, no metrics will be emitted'; export DD_API_KEY
88-
- !reference [.bazel:test:reporting:ci_links]
89-
- bazel test --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --build_tests_only --config=$FLAVOR //pkg/... //comp/... //cmd/...
90-
- dda inv -- -e bazel.ensure-test-parity --bep $BEP_FILE --flavor-name $FLAVOR --emit-metrics
91-
92-
# macOS flavor variant: re-installs dda in both script and after_script since
93-
# macOS shell executors run each phase in a fresh shell.
94-
.bazel:test:flavor:macos:
95-
extends: .bazel:test:flavor
96-
script:
97-
- !reference [.install_python_dependencies]
98-
- !reference [.bazel:test:flavor, script]
99-
after_script:
100-
- !reference [.install_python_dependencies]
101-
- !reference [.bazel:test:reporting, after_script]
102-
103-
bazel:test:linux-amd64:base:
104-
extends: [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
105-
variables:
106-
FLAVOR: base
107-
108-
bazel:test:linux-amd64:dogstatsd:
109-
extends: [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
110-
variables:
111-
FLAVOR: dogstatsd
112-
113-
bazel:test:linux-amd64:heroku:
114-
extends: [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
115-
variables:
116-
FLAVOR: heroku
117-
118-
bazel:test:linux-amd64:iot:
119-
extends: [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
120-
variables:
121-
FLAVOR: iot
122-
123-
bazel:test:linux-arm64:base:
124-
extends: [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
125-
variables:
126-
FLAVOR: base
127-
128-
bazel:test:linux-arm64:dogstatsd:
129-
extends: [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
130-
variables:
131-
FLAVOR: dogstatsd
132-
133-
bazel:test:linux-arm64:heroku:
134-
extends: [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
135-
variables:
136-
FLAVOR: heroku
137-
138-
bazel:test:linux-arm64:iot:
139-
extends: [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
140-
variables:
141-
FLAVOR: iot
142-
143-
bazel:test:macos-amd64:base:
144-
extends: [ .bazel:runner:macos-amd64, .bazel:test:flavor:macos ]
145-
variables:
146-
FLAVOR: base
147-
148-
bazel:test:macos-amd64:dogstatsd:
149-
extends: [ .bazel:runner:macos-amd64, .bazel:test:flavor:macos ]
150-
variables:
151-
FLAVOR: dogstatsd
152-
153-
bazel:test:macos-arm64:base:
154-
extends: [ .bazel:runner:macos-arm64, .bazel:test:flavor:macos ]
155-
variables:
156-
FLAVOR: base
157-
158-
bazel:test:macos-arm64:dogstatsd:
159-
extends: [ .bazel:runner:macos-arm64, .bazel:test:flavor:macos ]
160-
variables:
161-
FLAVOR: dogstatsd
162-
163-
# Windows can't extend .bazel:test:flavor: the Windows runner template consumes
164-
# POWERSHELL_SCRIPT instead of `script:`, and the test pattern needs to exclude
165-
# Linux-only packaging targets.
166-
bazel:test:windows-amd64:base:
167-
extends: [ .bazel:runner:windows-amd64, .bazel:test ]
84+
bazel:test:windows-amd64:go:
85+
extends: [.bazel:runner:windows-amd64, .bazel:test]
16886
variables:
16987
POWERSHELL_SCRIPT: >-
170-
bazel test --keep_going --build_tests_only --config=base
171-
--build_event_json_file=$CI_PROJECT_DIR/bazel-bep-base.json
172-
//pkg/... //comp/... //cmd/...;
173-
dda inv -- -e bazel.ensure-test-parity
174-
--bep $CI_PROJECT_DIR/bazel-bep-base.json
175-
--flavor-name base
176-
artifacts:
177-
when: always
178-
paths:
179-
- bazel-bep-*.json
180-
expire_in: 1 week
88+
bazel test --config=gorace --config=dd-agent-go-tests-only --build_tests_only --keep_going //... --
89+
-//bazel/rules/dd_packaging/...
90+
-//packages/agent/linux/...

.gitlab/windows/test/e2e_install_packages/windows.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@
6565
- E2E_MSI_TEST: TestInstallExistingAltDir
6666
- E2E_MSI_TEST: TestInstallAltDirAndCorruptForUninstall
6767
- E2E_MSI_TEST: TestInstallFail
68-
- E2E_MSI_TEST: TestInstallWithUntrustedConfigRoot
6968
- E2E_MSI_TEST: TestInstallWithLanmanServerDisabled
7069
- E2E_MSI_TEST: TestInstallWithInstallOnlyFlag
7170
- E2E_MSI_TEST: TestInstallWithAutologger

BUILD.bazel

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
# Global build settings
2+
# gazelle:dd_agent_go_test on
3+
# gazelle:go_canonical_test_tag_set docker kubelet
4+
# gazelle:go_canonical_test_tag_set cel clusterchecks kubeapiserver kubelet orchestrator
5+
# gazelle:go_canonical_test_tag_set linux_bpf
26

37
load("@bazel_lib//lib:write_source_files.bzl", "write_source_file", "write_source_files")
48
load("@bazel_skylib//rules:common_settings.bzl", "bool_flag", "string_flag")

CHANGELOG-DCA.rst

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,106 @@
22
Release Notes
33
=============
44

5+
.. _Release Notes_7.82.0:
6+
7+
7.82.0
8+
======
9+
10+
.. _Release Notes_7.82.0_Prelude:
11+
12+
Prelude
13+
-------
14+
15+
Released on: 2026-08-05
16+
Pinned to datadog-agent v7.82.0: `CHANGELOG <https://github.com/DataDog/datadog-agent/blob/main/CHANGELOG.rst#7820>`_.
17+
18+
19+
.. _Release Notes_7.82.0_New Features:
20+
21+
New Features
22+
------------
23+
24+
- The Cluster Agent's Prometheus HTTP Service Discovery provider supports
25+
an optional ``exclude_filter`` field per endpoint entry. The field
26+
accepts a CEL expression evaluated against each discovered target's
27+
``host``, ``port``, and ``labels`` fields. Targets for which the
28+
expression returns ``true`` are skipped at collection time.
29+
30+
31+
.. _Release Notes_7.82.0_Enhancement Notes:
32+
33+
Enhancement Notes
34+
-----------------
35+
36+
- The Cluster Agent's leader election now uses a dedicated Kubernetes API server
37+
client with independently managed client-side rate limiting to be more resilient.
38+
39+
- Reduce scale-up stabilization windows for built-in DPA presets:
40+
Optimize Cost from 300s to 190s, Optimize Balance from 600s to 130s,
41+
and Optimize Performance from 900s to 70s. This allows faster
42+
scale-up response for workloads using autoscaling profiles.
43+
44+
- Cluster check stickiness is now enabled by default. The dispatcher biases
45+
check placement toward the runner where a check previously ran, reducing
46+
unnecessary check migrations. The behavior can be tuned or disabled via the
47+
following configuration options:
48+
49+
- ``cluster_checks.stickiness_enabled`` — enable or disable stickiness (default: ``true``)
50+
- ``cluster_checks.stickiness_factor`` — multiplier applied to check cost when computing the bias (default: ``4.0``)
51+
- ``cluster_checks.stickiness_upper_limit`` — maximum bias applied regardless of check cost (default: ``1.0``)
52+
- ``cluster_checks.stickiness_lower_limit`` — minimum bias applied when stickiness is enabled (default: ``0.05``)
53+
54+
55+
.. _Release Notes_7.82.0_Bug Fixes:
56+
57+
Bug Fixes
58+
---------
59+
60+
- Fixed APM Single Step Instrumentation injecting the library twice when the
61+
admission webhook is reinvoked (for example on GKE Autopilot, where another
62+
mutating webhook triggers reinvocation). In CSI injection mode the pod has no
63+
init container, so the re-admission guard failed to detect that the pod was
64+
already instrumented and appended the injector to ``LD_PRELOAD`` a second time.
65+
The guard now also checks for the instrumentation volume, which is present in
66+
every injection mode.
67+
68+
- Fixed an issue where the Cluster Agent could associate a pod's detected
69+
languages with the wrong Deployment. The Cluster Agent now only attributes a pod's
70+
detected languages to a Deployment when the pod is owned by a ReplicaSet and
71+
the ReplicaSet derived from the pod name matches the owner ReplicaSet. Pods
72+
that are not owned by a ReplicaSet are no longer considered for
73+
Deployment-level language detection.
74+
75+
- Fix ``cluster_checks.nodes_reporting`` gauge drifting upward across
76+
leader elections. The metric is now correctly decremented when the
77+
cluster agent loses leadership and the node store is reset.
78+
79+
- Fix `agent` commands in DCA (listener should always be started)
80+
81+
- Fix permission in docker image when executing "/readsecret.sh" script with dd-agent user
82+
83+
- Fixed an issue in the KSM check where cluster-aggregate metrics
84+
(``kubernetes_state.container.<cpu|memory>_requested.total``,
85+
``kubernetes_state.container.<cpu|memory|gpu|mig>_limit.total``,
86+
and the ``initcontainer`` equivalents) reported incorrect cluster totals
87+
when the check ran with ``pod_collection_mode: node_kubelet``. The
88+
aggregate metrics are now computed from a dedicated instance (running on
89+
the cluster-agent or a cluster-checks runner) in the new
90+
``pod_collection_mode: cluster_aggregates_only`` mode, which watches all
91+
pods directly from the API server. To enable the fix, set the
92+
``cluster_aggregates_enabled: true`` instance option on the
93+
``node_kubelet`` and ``cluster_unassigned`` instances; those instances then
94+
suppress the affected accumulators, eliminating multi-source gauge collision
95+
at ingestion. Without that option the previous (colliding) behavior is
96+
unchanged, so it must be set alongside deploying the
97+
``cluster_aggregates_only`` instance. The fix preserves the per-pod metric
98+
scaling benefit of ``node_kubelet`` mode while restoring correct cluster
99+
aggregates.
100+
101+
- Fix a bug in the orchestrator explorer check that led to trying to collect
102+
Kubernetes subresources under certain custom resource API groups.
103+
104+
5105
.. _Release Notes_7.81.3:
6106

7107
7.81.3

0 commit comments

Comments
 (0)