DD_TAGS env var support
Summary
This PR fixes issue #223 and it is something that I am also interested in using. I hope this is the correct implementation for the problem.
@hush-hush I know you had self-assigned issue #223 to you, so maybe you want to give me a review here? Thanks in advance!
Hi @pedro-stanaka ,
Thanks for opening this PR. Adding support for DD_TAGS across all our DogStatsD clients is something we're looking into.
The main issue being that when DD_TAGS is set for the whole host and the agent/client are running locally it will be picked by both, so we have to be careful. This is especially important when using containers, VMs or k8s deployments. The last thing we want is for the clients or Agent to assign the wrong tags to a metric by default.
We're also looking into aligning the behavior between all clients around this, which is a bit all over the place right now.
In the meantime, clients that want to fetch tags from the env can easily do so using the library constructor. It's not the best but it's an easy workaround.