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

feat: add custom metrics, and an initial cache size metric #1254

Merged
merged 2 commits into from
Feb 6, 2025

Conversation

ctron
Copy link
Contributor

@ctron ctron commented Feb 5, 2025

Closes: #1255

@ctron ctron force-pushed the feature/metrics_1 branch from dbf75b0 to 8a22968 Compare February 5, 2025 17:13
@@ -141,19 +131,14 @@ pub fn init_tracing(name: &str, tracing: Tracing) {
INIT.call_once(init_no_tracing);
}
Tracing::Enabled => {
init_otlp(name);
init_otlp_tracing(name);
Copy link
Collaborator

Choose a reason for hiding this comment

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

@helio-frota
Copy link
Collaborator

helio-frota commented Feb 5, 2025

2025-02-05_14-30

@helio-frota
Copy link
Collaborator

@jcrossley3 fixed that annoying logs for actix-web-prom #335

without actix-web-prom we can remove that as well 👍

@helio-frota helio-frota linked an issue Feb 5, 2025 that may be closed by this pull request
Copy link
Contributor

@chirino chirino left a comment

Choose a reason for hiding this comment

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

lgtm

let graph_cache = graph_cache.clone();
meter
.u64_observable_gauge("cache_size")
.with_callback(move |inst| inst.observe(graph_cache.size_used(), &[]))
Copy link
Contributor

Choose a reason for hiding this comment

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

nice.

@ctron ctron added this pull request to the merge queue Feb 6, 2025
Merged via the queue into trustification:main with commit 110c7db Feb 6, 2025
2 checks passed
@ctron ctron deleted the feature/metrics_1 branch February 6, 2025 08:43
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.

OTEL metrics - Infra rust code
3 participants