Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add logsagentpipeline component for OTLP ingest paths #25032

Merged
merged 21 commits into from
Apr 26, 2024

Conversation

liustanley
Copy link
Contributor

@liustanley liustanley commented Apr 23, 2024

What does this PR do?

This PR adds logs agent setup files in comp/otelcol/logsagentpipeline. This includes agent.go which mirrors the logs agent initialization files in comp/logs/agent, with only the pipeline components that are needed for OTLP ingest paths (otel-agent and collector datadog exporter).

This PR also modifies the otel-agent run subcommand to use logsagentpipeline instead of the logs agent in comp/logs/agent.

Motivation

This code was initially added to collector-contrib in this PR: open-telemetry/opentelemetry-collector-contrib#32327, but needs to be added in datadog-agent instead to be used by the otel-agent.

Additional Notes

Possible Drawbacks / Trade-offs

Describe how to test/QA your changes

@liustanley liustanley requested review from a team as code owners April 23, 2024 20:08
@liustanley liustanley requested a review from mx-psi April 23, 2024 20:08
@liustanley liustanley added this to the 7.54.0 milestone Apr 23, 2024
@gh123man gh123man self-requested a review April 23, 2024 20:20
Copy link
Contributor

@gh123man gh123man left a comment

Choose a reason for hiding this comment

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

I don't see any obvious issues with how this is set up. so LGTM 👍
Just made a couple of small suggestions.

you may also consider renaming these files to be more otel specific - up to you though.

@pr-commenter
Copy link

pr-commenter bot commented Apr 23, 2024

Regression Detector

Regression Detector Results

Run ID: 6ff0dc23-18a7-4f33-a65d-23249d8f91da
Baseline: 9581bfe
Comparison: 8c8d4b3

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 +15.13 [+8.96, +21.30]

Fine details of change detection per experiment

perf experiment goal Δ mean % Δ mean % CI
file_to_blackhole % cpu utilization +15.13 [+8.96, +21.30]
basic_py_check % cpu utilization +2.09 [-0.51, +4.70]
idle memory utilization +0.32 [+0.29, +0.36]
uds_dogstatsd_to_api ingress throughput +0.02 [-0.19, +0.22]
trace_agent_json ingress throughput +0.01 [-0.01, +0.02]
otel_to_otel_logs ingress throughput -0.00 [-0.36, +0.35]
trace_agent_msgpack ingress throughput -0.01 [-0.02, -0.00]
process_agent_standard_check_with_stats memory utilization -0.05 [-0.10, +0.00]
tcp_dd_logs_filter_exclude ingress throughput -0.06 [-0.10, -0.02]
process_agent_real_time_mode memory utilization -0.24 [-0.27, -0.20]
process_agent_standard_check memory utilization -0.25 [-0.31, -0.20]
file_tree memory utilization -0.47 [-0.56, -0.37]
uds_dogstatsd_to_api_cpu % cpu utilization -1.11 [-3.90, +1.67]
pycheck_1000_100byte_tags % cpu utilization -1.31 [-6.06, +3.45]
tcp_syslog_to_blackhole ingress throughput -7.72 [-28.09, +12.66]

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

@liustanley liustanley requested a review from a team as a code owner April 24, 2024 15:07
Copy link

cit-pr-commenter bot commented Apr 24, 2024

Go Package Import Differences

Baseline: 9581bfe
Comparison: 8c8d4b3

binaryosarchchange
agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
agentwindowsamd64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
agentwindows386
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
agentdarwinamd64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
agentdarwinarm64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
iot-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
iot-agentlinuxarm64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline
heroku-agentlinuxamd64
+1, -0
+github.com/DataDog/datadog-agent/comp/otelcol/logsagentpipeline

@pr-commenter
Copy link

pr-commenter bot commented Apr 24, 2024

Test changes on VM

Use this command from test-infra-definitions to manually test this PR changes on a VM:

inv create-vm --pipeline-id=33063667 --os-family=ubuntu

Copy link
Contributor

@dustmop dustmop left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@CelianR CelianR left a comment

Choose a reason for hiding this comment

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

Lgtm for agent ci experience files 👍

comp/otelcol/logsagentpipeline/component.go Outdated Show resolved Hide resolved
@liustanley
Copy link
Contributor Author

/merge

@dd-devflow
Copy link

dd-devflow bot commented Apr 26, 2024

🚂 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
Copy link

dd-devflow bot commented Apr 26, 2024

🚂 MergeQueue

Pull request added to the queue.

There are 6 builds ahead! (estimated merge in less than 3h)

Use /merge -c to cancel this operation!

@dd-mergequeue dd-mergequeue bot merged commit a1ef7ed into main Apr 26, 2024
195 of 196 checks passed
@dd-mergequeue dd-mergequeue bot deleted the stanley.liu/logsagentpipeline branch April 26, 2024 23:28
alexgallotta pushed a commit that referenced this pull request May 9, 2024
* Add logs agent pipeline files

* Add modules

* Replace logs agent in otel-agent with logs agent pipeline

* Fix dependency version

* Add health liveness

* PR feedback

* Move component

* Fix otel-agent

* Fix lint

* Fix imports

* Make dependencies public

* Fix lint

* Edit component interface

* Fix fx

* Rename method

* Update comments

* Fix license year

* Fix go mods

* Fix lint
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.

None yet

5 participants