-
Notifications
You must be signed in to change notification settings - Fork 740
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
Extract the prometheus endpoint #6843
base: master
Are you sure you want to change the base?
Conversation
Hi @AndreiEres ! Could i get a first review of this please ? all tests are passing but i cant get pyroscope or prometheus to show data on my graphana, might be a skill issue on my end |
use color_eyre::eyre; | ||
|
||
/// Show if the app is running under Prometheus monitoring | ||
pub(crate) fn is_prometheus_running() -> bool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure we need it
} | ||
|
||
/// Relaunch the app in Prometheus monitoring mode | ||
pub(crate) fn relaunch_in_prometheus_mode() -> eyre::Result<()> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need to relaunch the bench. I assume you copied the approach with Valgrind, where we should relaunch the bench. Here, it's sufficient to initialize the endpoint.
@@ -101,6 +102,10 @@ struct BenchCli { | |||
/// Enable Cache Misses Profiling with Valgrind. Linux only, Valgrind must be in the PATH | |||
pub cache_misses: bool, | |||
|
|||
#[clap(long, default_value_t = false)] | |||
/// Enable prometheus | |||
pub prometheus: bool, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need a port here as well
Description
Extract the prometheus endpoint launching outside the test, as we already do with valgrind and pyroscope.
This is a PR for #3600