[dsd] Support container ID field from dogstatsd 1.2#10659
Conversation
45b902f to
d2df487
Compare
d00bc11 to
abe1cb5
Compare
Co-authored-by: May Lee <may.lee@datadoghq.com>
7f484ba to
c30af3b
Compare
01ca6e7 to
b428db0
Compare
hush-hush
left a comment
There was a problem hiding this comment.
Added a nit-pick on the release note. Looks good otherwise
Co-authored-by: maxime mouial <hush-hush@users.noreply.github.com>
vickenty
left a comment
There was a problem hiding this comment.
Would it make sense to c
| // We use the UDS socket origin if no origin ID was specify in the tags | ||
| // or 'dogstatsd_entity_id_precedence' is set to False (default false). | ||
| if entityIDValue == "" || !entityIDPrecedenceEnabled { | ||
| if originFromTag == "" || !entityIDPrecedenceEnabled { |
There was a problem hiding this comment.
Should we skip originFromUDS if we are going to use originFromMsg? It would be nice to avoid tagging metrics with two container tags if a proxy is using UDS to send metrics on behalf of another container.
There was a problem hiding this comment.
UDS origin detection is opt-in and not enabled by default, I'd rather let the user have control.
There was a problem hiding this comment.
This feature would probably interest users that use origin detection today, so they may be inclined to have both options enabled: use uds to tag traffic on older clients, while using benefits of client-side origin detection with newer clients. Unless double-tagging is a use case we explicitly want to support, I think it would make more sense to assign only one origin per metric.
There was a problem hiding this comment.
I'd rather keep it simple as is currently and not make any assumptions.
We agreed that extending the protocol is always an option in the future, so if we want to turn on and off UDS origin detection on-demand it would be best to let the client do it via a new field.
Co-authored-by: Vickenty Fesunov <vickenty@users.noreply.github.com>
What does this PR do?
Extend origin detection on by supporting a new field in the dsd protocol, the new field
c:<id>holds the container ID discovered by the client.Motivation
Additional Notes
Possible Drawbacks / Trade-offs
Describe how to test/QA your changes
Deploy the agent with
DD_DOGSTATSD_ORIGIN_DETECTION_CLIENT=trueYou should be able to see container tags attached to the
testing.dsd.containermetric on the app.Reviewer's Checklist
Triagemilestone is set.team/..label has been applied, if known.major_changelabel 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-changeloglabel has been applied.qa/skip-qalabel is not applied.need-change/operatorandneed-change/helmlabels have been applied.