-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
[pkg/otlp] Make debug section aligned with logging exporter #14072
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM for ASC files 👍
## @param verbosity - string - optional - default: normal | ||
## @env DD_OTLP_CONFIG_DEBUG_VERBOSITY - string - optional - default: normal | ||
## Verbosity of debug logs when Datadog Agent receives otlp traces/metrics. | ||
## Valid values are basic, normal, detailed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is so weird and confusing given that the API for logging still contains the logging level analogous methods (or did that change too?) logger.Info
, logger.Error
, etc...
Is basic then warn
level, normal
info level, and detailed error
level?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The levels are defined here: https://pkg.go.dev/go.opentelemetry.io/[email protected]/config/configtelemetry#Level
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just a question to clarify. If you can link to an upstream issue in the PR description which shows how the verbosity config setting works (to better understand the transition), that would be helpful for posterity.
The issue where this change was proposed is open-telemetry/opentelemetry-collector/issues/5878, I just realized the examples upstream are not updated, I will open a PR for that. This issue was opened after open-telemetry/opentelemetry-collector/pull/5678, which was necessary to fix open-telemetry/opentelemetry-collector/issues/5652. The TL;DR: because of limitations on the library used for logging we changed all messages to be at |
* Revert "Bump OpenTelemetry Collector dependencies to v0.63.0 (#14067)" This reverts commit 34610f5. * Revert "Bump OpenTelemetry Collector dependencies to v0.62.0 (#13860)" This reverts commit a5fe32e. * Revert "[pkg/otlp] Make debug section aligned with logging exporter (#14072)" This reverts commit 057e1f4. * Revert "[pkg/trace] Remove deprecated function calls (#14086)" This reverts commit 41e8a2f.
What does this PR do?
Make the
otlp_config.debug
section aligned with thelogging
exporter by supporting (slightly) the same settings.Motivation
The logging exporter added the
verbosity
option on v0.63.0 to deprecateloglevel
. In order to be aligned with upstream, we are adding support for it.Possible Drawbacks / Trade-offs
Describe how to test/QA your changes
Test the Agent with the following setups:
loglevel
todisabled
; check that there is no log mentioning the logging exporter and/or that no logs come up when sending metrics/traces. Example config for this:debug
section. Check that the logging exporter does show up on logs and that the logs come up in metrics/traces. Example config:verbosity
todetailed
and send some metrics/traces. Check that verbose logs (including all details from payload) show up in the Agent logs.Reviewer's Checklist
Triage
milestone is set.major_change
label if your change either has a major impact on the code base, is impacting multiple teams or is changing important well-established internals of the Agent. This label will be use during QA to make sure each team pay extra attention to the changed behavior. For any customer facing change use a releasenote.changelog/no-changelog
label has been applied.qa/skip-qa
label is not applied.team/..
label has been applied, indicating the team(s) that should QA this change.need-change/operator
andneed-change/helm
labels have been applied.k8s/<min-version>
label, indicating the lowest Kubernetes version compatible with this feature.