Skip to content

Commit df83f28

Browse files
committed
chore: move arg to metrics
1 parent 4e0f1d1 commit df83f28

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

src/cli.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -320,6 +320,9 @@ pub struct Metrics {
320320
/// Where to listen for Prometheus metrics scraping
321321
#[clap(env, long)]
322322
pub metrics_listen: Option<SocketAddr>,
323+
/// How frequently to refresh statistics about API boundary nodes
324+
#[clap(env, long, default_value = "30s", value_parser = parse_duration)]
325+
pub api_boundary_nodes_stats_refresh_interval: Duration,
323326
}
324327

325328
#[derive(Args)]
@@ -478,10 +481,6 @@ pub struct Misc {
478481
/// Defaults to the number of CPUs
479482
#[clap(env, long)]
480483
pub threads: Option<usize>,
481-
482-
/// How frequently to refresh statistics about API boundary nodes
483-
#[clap(env, long, default_value = "30s", value_parser = parse_duration)]
484-
pub api_boundary_nodes_stats_refresh_interval: Duration,
485484
}
486485

487486
#[derive(Args)]

src/routing/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ pub fn setup_router(
322322
tasks.add_interval(
323323
"api_boundary_nodes_stats",
324324
Arc::new(ApiBoundaryNodesStats::new(route_provider.clone(), registry)),
325-
cli.misc.api_boundary_nodes_stats_refresh_interval,
325+
cli.metrics.api_boundary_nodes_stats_refresh_interval,
326326
);
327327

328328
// Prepare the states

0 commit comments

Comments
 (0)