Skip to content

Conversation

@dustmop
Copy link
Contributor

@dustmop dustmop commented Jan 28, 2026

What does this PR do?

  1. Move ValidateBasicTypes to pkg/config/basic in order to remove a dependency from nodetreemodel -> viper
  2. Fix ValidateBasicTypes so it properly handles map[string]interface{}, []interface{}, etc
  3. Fix tests in comp/metadata/host/hostimpl/host_test.go in order to remove it from the allowlist in validate_basic.go

This PR is best reviewed one commit at a time.

Motivation

We want to move towards a world where data passed to SetWithoutSource is only using basic types (int, float, string, slice, map, etc), and no structs.

Describe how you validated your changes

Unit tests cover the behavior change

Additional Notes

@dustmop dustmop requested review from a team as code owners January 28, 2026 15:20
@dustmop dustmop requested a review from nathan-b January 28, 2026 15:21
@dustmop dustmop added changelog/no-changelog qa/done QA done before merge and regressions are covered by tests team/agent-configuration labels Jan 28, 2026
@dustmop dustmop requested a review from s-alad January 28, 2026 15:21
@github-actions github-actions bot added component/system-probe long review PR is complex, plan time to review it labels Jan 28, 2026
Copy link
Contributor

@jeremy-hanna jeremy-hanna left a comment

Choose a reason for hiding this comment

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

👍 for #agent-runtime owned files

@agent-platform-auto-pr
Copy link
Contributor

agent-platform-auto-pr bot commented Jan 28, 2026

Go Package Import Differences

Baseline: df987c6
Comparison: 8fd9a05

binaryosarchchange
agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
agentwindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
agentdarwinamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
agentdarwinarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
iot-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
iot-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
heroku-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
cluster-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
cluster-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
cluster-agent-cloudfoundrylinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
cluster-agent-cloudfoundrylinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
dogstatsdlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
dogstatsdlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
process-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
process-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
process-agentwindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
process-agentdarwinamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
process-agentdarwinarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
heroku-process-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
security-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
security-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
security-agentwindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
sbomgenlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
sbomgenlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
system-probelinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
system-probelinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
system-probewindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
system-probedarwinamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
system-probedarwinarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
trace-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
trace-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
trace-agentwindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
trace-agentdarwinamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
trace-agentdarwinarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
heroku-trace-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
otel-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
otel-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
full-host-profilerlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
full-host-profilerlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
loaderlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
loaderlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
loaderdarwinamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
loaderdarwinarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
installerlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
installerlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic
installerwindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/pkg/config/basic

@agent-platform-auto-pr
Copy link
Contributor

agent-platform-auto-pr bot commented Jan 28, 2026

Static quality checks

✅ Please find below the results from static quality gates
Comparison made with ancestor df987c6
📊 Static Quality Gates Dashboard

31 successful checks with minimal change (< 2 KiB)
Quality gate Current Size
agent_deb_amd64 748.098 MiB
agent_deb_amd64_fips 708.158 MiB
agent_heroku_amd64 325.593 MiB
agent_msi 659.741 MiB
agent_rpm_amd64 748.082 MiB
agent_rpm_amd64_fips 708.142 MiB
agent_rpm_arm64 727.172 MiB
agent_rpm_arm64_fips 689.720 MiB
agent_suse_amd64 748.082 MiB
agent_suse_amd64_fips 708.142 MiB
agent_suse_arm64 727.172 MiB
agent_suse_arm64_fips 689.720 MiB
docker_agent_amd64 810.574 MiB
docker_agent_arm64 814.258 MiB
docker_agent_jmx_amd64 1001.452 MiB
docker_agent_jmx_arm64 993.856 MiB
docker_cluster_agent_amd64 180.824 MiB
docker_cluster_agent_arm64 196.670 MiB
docker_cws_instrumentation_amd64 7.135 MiB
docker_cws_instrumentation_arm64 6.689 MiB
docker_dogstatsd_amd64 38.414 MiB
docker_dogstatsd_arm64 36.749 MiB
dogstatsd_deb_amd64 29.630 MiB
dogstatsd_deb_arm64 27.802 MiB
dogstatsd_rpm_amd64 29.630 MiB
dogstatsd_suse_amd64 29.630 MiB
iot_agent_deb_amd64 42.751 MiB
iot_agent_deb_arm64 39.872 MiB
iot_agent_deb_armhf 40.442 MiB
iot_agent_rpm_amd64 42.751 MiB
iot_agent_suse_amd64 42.751 MiB
On-wire sizes (compressed)
Quality gate Change Size (prev → curr → max)
agent_deb_amd64 -14.94 KiB (0.01% reduction) 182.812 → 182.797 → 184.810
agent_deb_amd64_fips +74.65 KiB (0.04% increase) 174.259 → 174.332 → 177.560
agent_heroku_amd64 +3.7 KiB (0.00% increase) 87.285 → 87.288 → 88.450
agent_msi -16.0 KiB (0.01% reduction) 142.453 → 142.438 → 143.300
agent_rpm_amd64 +40.1 KiB (0.02% increase) 185.737 → 185.776 → 188.160
agent_rpm_amd64_fips +20.6 KiB (0.01% increase) 176.695 → 176.715 → 178.900
agent_rpm_arm64 +52.27 KiB (0.03% increase) 168.382 → 168.433 → 169.930
agent_rpm_arm64_fips +33.94 KiB (0.02% increase) 160.753 → 160.786 → 163.120
agent_suse_amd64 +40.1 KiB (0.02% increase) 185.737 → 185.776 → 188.160
agent_suse_amd64_fips +20.6 KiB (0.01% increase) 176.695 → 176.715 → 178.900
agent_suse_arm64 +52.27 KiB (0.03% increase) 168.382 → 168.433 → 169.930
agent_suse_arm64_fips +33.94 KiB (0.02% increase) 160.753 → 160.786 → 163.120
docker_agent_amd64 +4.17 KiB (0.00% increase) 275.086 → 275.090 → 277.400
docker_agent_arm64 -6.3 KiB (0.00% reduction) 262.675 → 262.669 → 266.040
docker_agent_jmx_amd64 +8.11 KiB (0.00% increase) 343.721 → 343.728 → 346.020
docker_agent_jmx_arm64 +13.09 KiB (0.00% increase) 327.292 → 327.305 → 330.660
docker_cluster_agent_amd64 neutral 63.876 MiB → 64.510
docker_cluster_agent_arm64 +7.86 KiB (0.01% increase) 60.136 → 60.143 → 61.170
docker_cws_instrumentation_amd64 neutral 2.994 MiB → 3.330
docker_cws_instrumentation_arm64 neutral 2.726 MiB → 3.090
docker_dogstatsd_amd64 neutral 14.864 MiB → 15.820
docker_dogstatsd_arm64 neutral 14.203 MiB → 14.830
dogstatsd_deb_amd64 neutral 7.833 MiB → 8.790
dogstatsd_deb_arm64 neutral 6.719 MiB → 7.710
dogstatsd_rpm_amd64 neutral 7.842 MiB → 8.800
dogstatsd_suse_amd64 neutral 7.842 MiB → 8.800
iot_agent_deb_amd64 neutral 11.210 MiB → 12.040
iot_agent_deb_arm64 neutral 9.584 MiB → 10.450
iot_agent_deb_armhf neutral 9.782 MiB → 10.620
iot_agent_rpm_amd64 neutral 11.231 MiB → 12.060
iot_agent_suse_amd64 neutral 11.231 MiB → 12.060

@cit-pr-commenter-54b7da
Copy link

cit-pr-commenter-54b7da bot commented Jan 28, 2026

Regression Detector

Regression Detector Results

Metrics dashboard
Target profiles
Run ID: e7f64b0e-ef3e-4f79-ae3b-985c9a99a6e4

Baseline: df987c6
Comparison: 8fd9a05
Diff

Optimization Goals: ✅ No significant changes detected

Experiments ignored for regressions

Regressions in experiments with settings containing erratic: true are ignored.

perf experiment goal Δ mean % Δ mean % CI trials links
docker_containers_cpu % cpu utilization +8.52 [+5.32, +11.72] 1 Logs

Fine details of change detection per experiment

perf experiment goal Δ mean % Δ mean % CI trials links
docker_containers_cpu % cpu utilization +8.52 [+5.32, +11.72] 1 Logs
ddot_metrics_sum_cumulative memory utilization +0.60 [+0.44, +0.76] 1 Logs
docker_containers_memory memory utilization +0.40 [+0.32, +0.48] 1 Logs
tcp_syslog_to_blackhole ingress throughput +0.27 [+0.21, +0.33] 1 Logs
uds_dogstatsd_20mb_12k_contexts_20_senders memory utilization +0.21 [+0.16, +0.26] 1 Logs
ddot_metrics_sum_delta memory utilization +0.18 [-0.01, +0.38] 1 Logs
quality_gate_idle memory utilization +0.18 [+0.14, +0.22] 1 Logs bounds checks dashboard
file_to_blackhole_0ms_latency egress throughput +0.04 [-0.46, +0.53] 1 Logs
file_to_blackhole_500ms_latency egress throughput +0.03 [-0.36, +0.42] 1 Logs
file_to_blackhole_1000ms_latency egress throughput +0.02 [-0.38, +0.43] 1 Logs
uds_dogstatsd_to_api_v3 ingress throughput +0.01 [-0.11, +0.13] 1 Logs
uds_dogstatsd_to_api ingress throughput -0.00 [-0.12, +0.12] 1 Logs
tcp_dd_logs_filter_exclude ingress throughput -0.00 [-0.10, +0.09] 1 Logs
file_to_blackhole_100ms_latency egress throughput -0.04 [-0.08, +0.01] 1 Logs
ddot_logs memory utilization -0.05 [-0.11, -0.00] 1 Logs
quality_gate_idle_all_features memory utilization -0.22 [-0.26, -0.18] 1 Logs bounds checks dashboard
quality_gate_logs % cpu utilization -0.26 [-1.81, +1.28] 1 Logs bounds checks dashboard
ddot_metrics_sum_cumulativetodelta_exporter memory utilization -0.30 [-0.53, -0.07] 1 Logs
otlp_ingest_metrics memory utilization -0.40 [-0.56, -0.25] 1 Logs
file_tree memory utilization -0.41 [-0.46, -0.35] 1 Logs
ddot_metrics memory utilization -0.61 [-0.83, -0.40] 1 Logs
otlp_ingest_logs memory utilization -0.89 [-1.00, -0.77] 1 Logs
quality_gate_metrics_logs memory utilization -1.11 [-1.33, -0.90] 1 Logs bounds checks dashboard

Bounds Checks: ✅ Passed

perf experiment bounds_check_name replicates_passed links
docker_containers_cpu simple_check_run 10/10
docker_containers_memory memory_usage 10/10
docker_containers_memory simple_check_run 10/10
file_to_blackhole_0ms_latency lost_bytes 10/10
file_to_blackhole_0ms_latency memory_usage 10/10
file_to_blackhole_1000ms_latency lost_bytes 10/10
file_to_blackhole_1000ms_latency memory_usage 10/10
file_to_blackhole_100ms_latency lost_bytes 10/10
file_to_blackhole_100ms_latency memory_usage 10/10
file_to_blackhole_500ms_latency lost_bytes 10/10
file_to_blackhole_500ms_latency memory_usage 10/10
quality_gate_idle intake_connections 10/10 bounds checks dashboard
quality_gate_idle memory_usage 10/10 bounds checks dashboard
quality_gate_idle_all_features intake_connections 10/10 bounds checks dashboard
quality_gate_idle_all_features memory_usage 10/10 bounds checks dashboard
quality_gate_logs intake_connections 10/10 bounds checks dashboard
quality_gate_logs lost_bytes 10/10 bounds checks dashboard
quality_gate_logs memory_usage 10/10 bounds checks dashboard
quality_gate_metrics_logs cpu_usage 10/10 bounds checks dashboard
quality_gate_metrics_logs intake_connections 10/10 bounds checks dashboard
quality_gate_metrics_logs lost_bytes 10/10 bounds checks dashboard
quality_gate_metrics_logs memory_usage 10/10 bounds checks dashboard

Explanation

Confidence level: 90.00%
Effect size tolerance: |Δ mean %| ≥ 5.00%

Performance changes are noted in the perf column of each table:

  • ✅ = significantly better comparison variant performance
  • ❌ = significantly worse comparison variant performance
  • ➖ = no significant change in performance

A regression test is an A/B test of target performance in a repeatable rig, where "performance" is measured as "comparison variant minus baseline variant" for an optimization goal (e.g., ingress throughput). Due to intrinsic variability in measuring that goal, we can only estimate its mean value for each experiment; we report uncertainty in that value as a 90.00% confidence interval denoted "Δ mean % CI".

For each experiment, we decide whether a change in performance is a "regression" -- a change worth investigating further -- if all of the following criteria are true:

  1. Its estimated |Δ mean %| ≥ 5.00%, indicating the change is big enough to merit a closer look.

  2. Its 90.00% confidence interval "Δ mean % CI" does not contain zero, indicating that if our statistical model is accurate, there is at least a 90.00% chance there is a difference in performance between baseline and comparison variants.

  3. Its configuration does not mark it "erratic".

CI Pass/Fail Decision

Passed. All Quality Gates passed.

  • quality_gate_logs, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_logs, bounds check lost_bytes: 10/10 replicas passed. Gate passed.
  • quality_gate_logs, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_idle_all_features, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_idle_all_features, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check lost_bytes: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check cpu_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_idle, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_idle, bounds check memory_usage: 10/10 replicas passed. Gate passed.

@dustmop dustmop force-pushed the dustin.long/validate-basic-fix branch from 7b05c81 to 9046b71 Compare January 29, 2026 20:44
@dustmop dustmop force-pushed the dustin.long/validate-basic-fix branch from 9046b71 to 2234c4f Compare January 29, 2026 20:51
@dustmop
Copy link
Contributor Author

dustmop commented Jan 30, 2026

/merge

@gh-worker-devflow-routing-ef8351
Copy link

gh-worker-devflow-routing-ef8351 bot commented Jan 30, 2026

View all feedbacks in Devflow UI.

2026-01-30 16:04:38 UTC ℹ️ Start processing command /merge


2026-01-30 16:04:46 UTC ℹ️ MergeQueue: waiting for PR to be ready

This pull request is not mergeable according to GitHub. Common reasons include pending required checks, missing approvals, or merge conflicts — but it could also be blocked by other repository rules or settings.
It will be added to the queue as soon as checks pass and/or get approvals. View in MergeQueue UI.
Note: if you pushed new commits since the last approval, you may need additional approval.
You can remove it from the waiting list with /remove command.


2026-01-30 20:05:06 UTC ⚠️ MergeQueue: This merge request was unqueued

devflow unqueued this merge request: It did not become mergeable within the expected time

@dustmop dustmop removed the request for review from a team January 30, 2026 20:49
@dustmop dustmop force-pushed the dustin.long/validate-basic-fix branch from 463cc27 to 8fd9a05 Compare January 30, 2026 20:50
@dustmop
Copy link
Contributor Author

dustmop commented Jan 30, 2026

/merge

@gh-worker-devflow-routing-ef8351
Copy link

gh-worker-devflow-routing-ef8351 bot commented Jan 30, 2026

View all feedbacks in Devflow UI.

2026-01-30 21:09:29 UTC ℹ️ Start processing command /merge


2026-01-30 21:09:38 UTC ℹ️ MergeQueue: waiting for PR to be ready

This pull request is not mergeable according to GitHub. Common reasons include pending required checks, missing approvals, or merge conflicts — but it could also be blocked by other repository rules or settings.
It will be added to the queue as soon as checks pass and/or get approvals. View in MergeQueue UI.
Note: if you pushed new commits since the last approval, you may need additional approval.
You can remove it from the waiting list with /remove command.


2026-01-30 22:35:21 UTC ℹ️ MergeQueue: merge request added to the queue

The expected merge time in main is approximately 2h (p90).


2026-01-30 23:16:08 UTC ℹ️ MergeQueue: This merge request was merged

@gh-worker-dd-mergequeue-cf854d gh-worker-dd-mergequeue-cf854d bot merged commit b41c751 into main Jan 30, 2026
618 checks passed
@gh-worker-dd-mergequeue-cf854d gh-worker-dd-mergequeue-cf854d bot deleted the dustin.long/validate-basic-fix branch January 30, 2026 23:16
@github-actions github-actions bot locked and limited conversation to collaborators Jan 30, 2026
@github-actions github-actions bot added this to the 7.77.0 milestone Jan 30, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

changelog/no-changelog component/system-probe long review PR is complex, plan time to review it qa/done QA done before merge and regressions are covered by tests team/agent-configuration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants