Skip to content

Conversation

@syphar
Copy link
Member

@syphar syphar commented Nov 16, 2025

datadog is the target system for logs & metrics in the new infra. We're already running the datadog agent locally on the server to ship our logs, so we can also start using it for metrics. I already activated the OTLP endpoint, and also enabled the process & nginx monitoring. I'll be able to setup & test in more detail when I have the necessary permissions.

This way we can have both systems running side by side for some time, and compare.

In our codebase I chose not the "native" datadog libraries, but opentelemetry as standard solution. Hopefully this will lead to us never having to refactor any more, only choose new exporters.

After I validated everything and created the necessary dashboards in datadog, we can drop the whole prometheus logic & integration.

Some detail notes:

  • I chose a simple approach where I dropped custom histogram bucket sizes, wanting to see first how they look like in datadog.
  • I didn't migrate the whole recent_* metrics, I'm thinking about either dropping them completely (after the initial learning they brought, I didn't see much additional value), or perhaps using datadog log-based metrics for them, where datadog generates metrics by parsing logs.
  • I tried to move from a glocal god-object for metrics to each main component having its own metrics.
  • the thread- and file-descriptor-count metrics should be replacable by using the datadog process monitor. I configured this and can evaluate when I have the increased access I need.
  • In my mind, the metrics that I would relate to the builder should be in one struct, but are used in two places. This is a pending refactor, but not now.

@syphar syphar self-assigned this Nov 16, 2025
@syphar syphar requested a review from a team as a code owner November 16, 2025 16:00
@github-actions github-actions bot added the S-waiting-on-review Status: This pull request has been implemented and needs to be reviewed label Nov 16, 2025
@syphar syphar changed the title set up opentelemetry metrics for new metrics set up opentelemetry metrics for new infra (and now) Nov 16, 2025
@GuillaumeGomez
Copy link
Member

Does it need to be setup when running locally? Also: can we access these new logs locally? If so, please add it into the README or the docs.

@syphar
Copy link
Member Author

syphar commented Nov 16, 2025

Does it need to be setup when running locally? Also: can we access these new logs locally? If so, please add it into the README or the docs.

It's optionally, and it's not logs but metrics. So no local change is needed.

If you want to debug the metrics, see what is pushed to the exporter, I can add a couple of lines how to configure it for debugging.

( it's why I added the new opentelemetry container)

@syphar syphar merged commit 1edd545 into rust-lang:master Nov 17, 2025
13 checks passed
@syphar syphar deleted the datadog-metrics branch November 17, 2025 11:05
@github-actions github-actions bot added S-waiting-on-deploy This PR is ready to be merged, but is waiting for an admin to have time to deploy it and removed S-waiting-on-review Status: This pull request has been implemented and needs to be reviewed labels Nov 17, 2025
@syphar syphar removed the S-waiting-on-deploy This PR is ready to be merged, but is waiting for an admin to have time to deploy it label Nov 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants