datadog-agent icon indicating copy to clipboard operation
datadog-agent copied to clipboard

add --target-tag as argument for dca hacky image build

Open adel121 opened this issue 1 year ago • 2 comments
trafficstars

What does this PR do?

Add --target-tag as an argument for cluster-agent.hacky-dev-image-build invoke command.

Motivation

Be consistent with agent.hacky-dev-image-build invoke command.

Additional Notes

Possible Drawbacks / Trade-offs

Describe how to test/QA your changes

Veriication:

inv cluster-agent.hacky-dev-image-build --target-image=cluster-agent --target-tag=custom-tag        
--- Setting rtloader paths to lib:/workspaces/datadog-agent/dev/lib | header:/workspaces/datadog-agent/dev/include | common headers:
Successfully wrote /workspaces/datadog-agent/Dockerfiles/cluster-agent/datadog-cluster.yaml
Loading release versions for nightly-a7
Security Agent polices for nightly-a7: master
Cloning into 'Dockerfiles/cluster-agent/security-agent-policies'...
DEPRECATED: The legacy builder is deprecated and will be removed in a future release.
            Install the buildx component to build images with BuildKit:
            https://docs.docker.com/go/buildx/

Sending build context to Docker daemon  1.328GB
Step 1/16 : FROM ubuntu:latest AS src
 ---> a50ab9f16797
Step 2/16 : COPY . /usr/src/datadog-agent
 ---> 28ea334ec26d
Step 3/16 : RUN find /usr/src/datadog-agent -type f \! -name \*.go -print0 | xargs -0 rm
 ---> Running in 11ebb2d373d6
 ---> Removed intermediate container 11ebb2d373d6
 ---> 4505b347626a
Step 4/16 : RUN find /usr/src/datadog-agent -type d -empty -print0 | xargs -0 rmdir
 ---> Running in cb7b43e50ee8
 ---> Removed intermediate container cb7b43e50ee8
 ---> cf113d458154
Step 5/16 : FROM golang:latest AS dlv
 ---> 9cbeef2f2690
Step 6/16 : RUN go install github.com/go-delve/delve/cmd/dlv@latest
 ---> Using cache
 ---> f82655ff2d87
Step 7/16 : FROM gcr.io/datadoghq/cluster-agent:7.51.1
 ---> 0b3a6698d5a6
Step 8/16 : ENV DEBIAN_FRONTEND=noninteractive
 ---> Using cache
 ---> b977e2465dea
Step 9/16 : RUN apt-get update &&     apt-get install -y bash-completion less vim tshark &&     apt-get clean
 ---> Using cache
 ---> b17b6e5afa1e
Step 10/16 : ENV DELVE_PAGER=less
 ---> Using cache
 ---> 18f2de3a8b47
Step 11/16 : COPY --from=dlv /go/bin/dlv /usr/local/bin/dlv
 ---> Using cache
 ---> 5a68c30ab086
Step 12/16 : COPY --from=src /usr/src/datadog-agent /workspaces/datadog-agent
 ---> Using cache
 ---> 29a7b4b1f7b2
Step 13/16 : COPY bin/datadog-cluster-agent/datadog-cluster-agent /opt/datadog-agent/bin/datadog-cluster-agent
 ---> db737b8c0acc
Step 14/16 : RUN agent                 completion bash > /usr/share/bash-completion/completions/agent
 ---> Running in f3c17b783842
 ---> Removed intermediate container f3c17b783842
 ---> 8ef0db0b2c42
Step 15/16 : RUN datadog-cluster-agent completion bash > /usr/share/bash-completion/completions/datadog-cluster-agent
 ---> Running in 7d3664c3e33f
 ---> Removed intermediate container 7d3664c3e33f
 ---> 6dbba173a81d
Step 16/16 : ENV DD_SSLKEYLOGFILE=/tmp/sslkeylog.txt
 ---> Running in 2bcd68558907
 ---> Removed intermediate container 2bcd68558907
 ---> 51ee3535ec21
Successfully built 51ee3535ec21
Successfully tagged cluster-agent:custom-tag

adel121 avatar Feb 29 '24 14:02 adel121

Bloop Bleep... Dogbot Here

Regression Detector Results

Run ID: ff200007-e702-4124-a7d9-136294787db6 Baseline: 95808e2d0a6422e6daf97695873b6b21239e367c Comparison: 960f599b1674c578055529b5e82a043eed161b72

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

Experiments with missing or malformed data

  • basic_py_check

Usually, this warning means that there is no usable optimization goal data for that experiment, which could be a result of misconfiguration.

No significant changes in experiment optimization goals

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

There were no significant changes in experiment optimization goals at this confidence level and effect size tolerance.

Experiments ignored for regressions

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

perf experiment goal Δ mean % Δ mean % CI
file_to_blackhole % cpu utilization -0.04 [-6.63, +6.54]

Fine details of change detection per experiment

perf experiment goal Δ mean % Δ mean % CI
idle memory utilization +0.14 [+0.11, +0.18]
file_tree memory utilization +0.07 [+0.00, +0.14]
uds_dogstatsd_to_api_cpu % cpu utilization +0.07 [-1.39, +1.53]
trace_agent_msgpack ingress throughput +0.00 [-0.00, +0.00]
tcp_dd_logs_filter_exclude ingress throughput +0.00 [-0.00, +0.00]
uds_dogstatsd_to_api ingress throughput -0.00 [-0.00, +0.00]
trace_agent_json ingress throughput -0.01 [-0.05, +0.04]
file_to_blackhole % cpu utilization -0.04 [-6.63, +6.54]
process_agent_standard_check memory utilization -0.28 [-0.31, -0.24]
otel_to_otel_logs ingress throughput -0.29 [-0.92, +0.35]
process_agent_real_time_mode memory utilization -0.40 [-0.43, -0.36]
tcp_syslog_to_blackhole ingress throughput -0.41 [-0.46, -0.35]
process_agent_standard_check_with_stats memory utilization -0.65 [-0.68, -0.62]

Explanation

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".

pr-commenter[bot] avatar Feb 29 '24 16:02 pr-commenter[bot]

Hi @adel121 , the qa/skip-qa label is deprecated, if there were no code changes can you please add qa/no-code-changes? This help us triage why PR can skip the QA

pducolin avatar Mar 08 '24 10:03 pducolin

/merge

clamoriniere avatar Mar 22 '24 10:03 clamoriniere

:steam_locomotive: MergeQueue

This merge request is not mergeable yet, because of pending checks/missing approvals. It will be added to the queue as soon as checks pass and/or get approvals. 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.

Use /merge -c to cancel this operation!

dd-devflow[bot] avatar Mar 22 '24 10:03 dd-devflow[bot]

:warning: MergeQueue

This merge request was unqueued

If you need support, contact us on Slack #ci-interfaces!

dd-devflow[bot] avatar Mar 22 '24 14:03 dd-devflow[bot]

[Fast Unit Tests Report]

On pipeline 32600756 (CI Visibility). The following jobs did not run any unit tests:

Jobs:
  • tests_deb-arm64-py3
  • tests_deb-x64-py3
  • tests_flavor_dogstatsd_deb-x64
  • tests_flavor_heroku_deb-x64
  • tests_flavor_iot_deb-x64
  • tests_rpm-arm64-py3
  • tests_rpm-x64-py3
  • tests_windows-x64

If you modified Go files and expected unit tests to run in these jobs, please double check the job logs. If you think tests should have been executed reach out to #agent-developer-experience

Regression Detector

Regression Detector Results

Run ID: a90a7d02-72fc-49b4-b898-d80a4baa0df6 Baseline: 8c1de5925c66c990b686e47ece5ff4dfc1ca9708 Comparison: 1a81f8a0d6863749a98a9c3303087049df30a06d

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

No significant changes in experiment optimization goals

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

There were no significant changes in experiment optimization goals at this confidence level and effect size tolerance.

Experiments ignored for regressions

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

perf experiment goal Δ mean % Δ mean % CI
file_to_blackhole % cpu utilization -1.02 [-7.17, +5.13]

Fine details of change detection per experiment

perf experiment goal Δ mean % Δ mean % CI
uds_dogstatsd_to_api_cpu % cpu utilization +0.74 [-2.21, +3.68]
otel_to_otel_logs ingress throughput +0.04 [-0.45, +0.52]
trace_agent_msgpack ingress throughput +0.03 [+0.02, +0.04]
trace_agent_json ingress throughput +0.01 [-0.03, +0.04]
uds_dogstatsd_to_api ingress throughput -0.00 [-0.20, +0.20]
tcp_dd_logs_filter_exclude ingress throughput -0.00 [-0.04, +0.03]
process_agent_standard_check memory utilization -0.05 [-0.11, +0.01]
process_agent_real_time_mode memory utilization -0.06 [-0.11, -0.01]
process_agent_standard_check_with_stats memory utilization -0.23 [-0.28, -0.18]
file_tree memory utilization -0.24 [-0.36, -0.12]
basic_py_check % cpu utilization -0.32 [-2.79, +2.16]
idle memory utilization -0.32 [-0.37, -0.27]
tcp_syslog_to_blackhole ingress throughput -0.74 [-0.81, -0.67]
file_to_blackhole % cpu utilization -1.02 [-7.17, +5.13]
pycheck_1000_100byte_tags % cpu utilization -2.00 [-6.86, +2.86]

Explanation

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".

pr-commenter[bot] avatar Apr 08 '24 10:04 pr-commenter[bot]

/merge

adel121 avatar Apr 23 '24 09:04 adel121

:steam_locomotive: MergeQueue

Pull request added to the queue.

This build is going to start soon! (estimated merge in less than 24m)

Use /merge -c to cancel this operation!

dd-devflow[bot] avatar Apr 23 '24 09:04 dd-devflow[bot]