@@ -489,7 +489,7 @@ impl SystemMetrics {
489489 out
490490 }
491491
492- /// Emit `shutdown_last_duration_ms {phase}` gauges.
492+ /// Emit `nodedb_shutdown_phase_duration_seconds {phase}` gauges.
493493 fn prometheus_shutdown_phases ( & self , out : & mut String ) {
494494 use std:: fmt:: Write as _;
495495 let m = self
@@ -500,17 +500,21 @@ impl SystemMetrics {
500500 return ;
501501 }
502502 let _ = out. write_str (
503- "# HELP shutdown_last_duration_ms Duration of each shutdown phase in the last graceful shutdown\n \
504- # TYPE shutdown_last_duration_ms gauge\n ",
503+ "# HELP nodedb_shutdown_phase_duration_seconds Duration of each shutdown phase in the last graceful shutdown\n \
504+ # TYPE nodedb_shutdown_phase_duration_seconds gauge\n ",
505505 ) ;
506506 let mut pairs: Vec < _ > = m. iter ( ) . collect ( ) ;
507507 pairs. sort_by ( |a, b| a. 0 . cmp ( b. 0 ) ) ;
508508 for ( phase, ms) in pairs {
509- let _ = writeln ! ( out, r#"shutdown_last_duration_ms{{phase="{phase}"}} {ms}"# ) ;
509+ let secs = * ms as f64 / 1_000.0 ;
510+ let _ = writeln ! (
511+ out,
512+ r#"nodedb_shutdown_phase_duration_seconds{{phase="{phase}"}} {secs}"#
513+ ) ;
510514 }
511515 }
512516
513- /// Emit `catalog_sanity_check_total {registry,outcome}` labeled counters.
517+ /// Emit `nodedb_catalog_sanity_check_total {registry,outcome}` labeled counters.
514518 fn prometheus_catalog_sanity ( & self , out : & mut String ) {
515519 use std:: fmt:: Write as _;
516520 let m = self
@@ -521,15 +525,15 @@ impl SystemMetrics {
521525 return ;
522526 }
523527 let _ = out. write_str (
524- "# HELP catalog_sanity_check_total Catalog sanity check outcomes per registry\n \
525- # TYPE catalog_sanity_check_total counter\n ",
528+ "# HELP nodedb_catalog_sanity_check_total Catalog sanity check outcomes per registry\n \
529+ # TYPE nodedb_catalog_sanity_check_total counter\n ",
526530 ) ;
527531 let mut pairs: Vec < _ > = m. iter ( ) . collect ( ) ;
528532 pairs. sort_by ( |a, b| a. 0 . cmp ( b. 0 ) ) ;
529533 for ( ( registry, outcome) , count) in pairs {
530534 let _ = writeln ! (
531535 out,
532- r#"catalog_sanity_check_total {{registry="{registry}",outcome="{outcome}"}} {count}"#
536+ r#"nodedb_catalog_sanity_check_total {{registry="{registry}",outcome="{outcome}"}} {count}"#
533537 ) ;
534538 }
535539 }
0 commit comments