Skip to content

Commit 8be83c8

Browse files
committed
chore: log if metrics_endpoint but no feature flag
1 parent 3261d0d commit 8be83c8

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

stacks-signer/src/lib.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,7 @@ impl<S: Signer<T> + Send + 'static, T: SignerEventTrait + 'static> SpawnedSigner
124124
);
125125
let (res_send, res_recv) = channel();
126126
let ev = SignerEventReceiver::new(config.network.is_mainnet());
127-
#[cfg(feature = "monitoring_prom")]
128-
{
129-
crate::monitoring::start_serving_monitoring_metrics(config.clone()).ok();
130-
}
127+
crate::monitoring::start_serving_monitoring_metrics(config.clone()).ok();
131128
let runloop = RunLoop::new(config.clone());
132129
let mut signer: RunLoopSigner<S, T> = libsigner::Signer::new(runloop, ev, res_send);
133130
let running_signer = signer.spawn(endpoint).expect("Failed to spawn signer");

stacks-signer/src/monitoring/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ use ::prometheus::HistogramTimer;
1919
#[cfg(feature = "monitoring_prom")]
2020
use slog::slog_error;
2121
#[cfg(not(feature = "monitoring_prom"))]
22-
use slog::slog_warn;
22+
use slog::slog_info;
2323
#[cfg(feature = "monitoring_prom")]
2424
use stacks_common::error;
2525
#[cfg(not(feature = "monitoring_prom"))]
26-
use stacks_common::warn;
26+
use stacks_common::info;
2727

2828
use crate::config::GlobalConfig;
2929

@@ -144,7 +144,7 @@ pub fn start_serving_monitoring_metrics(config: GlobalConfig) -> Result<(), Stri
144144
#[cfg(not(feature = "monitoring_prom"))]
145145
{
146146
if config.metrics_endpoint.is_some() {
147-
warn!("Not starting monitoring metrics server as the monitoring_prom feature is not enabled");
147+
info!("`metrics_endpoint` is configured for the signer, but the monitoring_prom feature is not enabled. Not starting monitoring metrics server.");
148148
}
149149
}
150150
Ok(())

0 commit comments

Comments
 (0)