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

fix: set service name as a tag in metrics #1786

Merged
merged 2 commits into from
Nov 25, 2020
Merged

Conversation

macaptain
Copy link
Contributor

@macaptain macaptain commented Nov 25, 2020

Overview

Currently the service name is part of the prefix for metrics, but it
would be far better if it were a tag, so that services could be compared
side by side in Datadog.

Rename the prefix to 'elixir'.

Changes

  • Move the service name from being part of the prefix in the name of a metric to a tag on the metric.

Testing

docker-compose -f docker-compose-watcher.yml -f docker-compose.dev.yml up
make docker-update-watcher
make docker-update-watcher_info

Check that metrics appear as omg.phoenix. ... with the service as a tag in Datadog. And this has been tested.

@macaptain macaptain added the chore Technical work that does not affect service behaviour label Nov 25, 2020
macaptain pushed a commit to omgnetwork/omg-childchain-v1 that referenced this pull request Nov 25, 2020
Currently the service name is part of the prefix for metrics, but it
would be far better if it were a tag, so that services could be compared
side by side in Datadog.

See also: omgnetwork/elixir-omg#1786
version: version
],
host: dd_host,
port: dd_port,
prefix: "omg.#{service}",
prefix: "omg",
Copy link
Contributor Author

@macaptain macaptain Nov 25, 2020

Choose a reason for hiding this comment

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

I may change this to "elixir" rather than "omg". I think the important part is that these metrics come from an elixir app.

@pnowosie pnowosie self-requested a review November 25, 2020 12:19
Currently the service name is part of the prefix for metrics, but it
would be far better if it were a tag, so that services could be compared
side by side in Datadog.
@macaptain macaptain merged commit 9571ac0 into master Nov 25, 2020
@macaptain macaptain deleted the dd-metrics-service-tag branch November 25, 2020 13:15
macaptain pushed a commit to omgnetwork/omg-childchain-v1 that referenced this pull request Nov 25, 2020
Currently the service name is part of the prefix for metrics, but it
would be far better if it were a tag, so that services could be compared
side by side in Datadog.

See also: omgnetwork/elixir-omg#1786
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Technical work that does not affect service behaviour
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants