Skip to content

Commit dabefa0

Browse files
committed
feat(health): add endpoint TCP reachability telemetry
Signed-off-by: Jay Zhu <jayzhu@nvidia.com>
1 parent 9d296f6 commit dabefa0

13 files changed

Lines changed: 1445 additions & 29 deletions

File tree

crates/health/example/config.example.toml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,16 @@ max_jitter = "40ms"
201201
refresh_interval = "60m"
202202
discovery_concurrency = 1
203203

204+
# Optional direct TCP checks for ports used by eligible enabled collectors.
205+
# Every check emits a metric; "unreachable" logs failures and "all" logs every result.
206+
# Checks bypass BMC proxies and do not verify TLS, authentication, or protocol readiness.
207+
# Results never create health reports or alerts.
208+
[collectors.reachability]
209+
enabled = true
210+
interval = "30s"
211+
timeout = "3s"
212+
log_mode = "unreachable"
213+
204214
[collectors.sensors]
205215
sensor_fetch_interval = "1m"
206216
sensor_fetch_concurrency = 10

crates/health/src/collectors/mod.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ mod nmxt;
2727
mod nvue;
2828
#[cfg(test)]
2929
pub(in crate::collectors) mod projection_test_support;
30+
mod reachability;
3031
mod runtime;
3132
mod sensors;
3233

@@ -42,9 +43,14 @@ pub use logs::{
4243
SseLogCollector, SseLogCollectorConfig,
4344
};
4445
pub use nmxc::{NmxcCollector, NmxcCollectorConfig};
46+
pub(crate) use nmxt::NMXT_PORT;
4547
pub use nmxt::{NmxtCollector, NmxtCollectorConfig};
4648
pub(crate) use nvue::gnmi::subscriber::spawn_gnmi_collector;
4749
pub use nvue::rest::collector::{NvueRestCollector, NvueRestCollectorConfig};
50+
pub(crate) use reachability::{
51+
COLLECTOR_TYPE as REACHABILITY_COLLECTOR_TYPE, ReachabilityCollector,
52+
ReachabilityCollectorStartConfig, ReachabilityService, ReachabilityTarget,
53+
};
4854
pub use runtime::{
4955
BackoffConfig, Collector, CollectorStartContext, EventStream, ExponentialBackoff,
5056
IterationResult, PeriodicCollector, StreamMetrics, StreamingCollector,

crates/health/src/collectors/nmxt.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ use crate::endpoint::BmcEndpoint;
4141
use crate::sink::{CollectorEvent, DataSink, EventContext, MetricSample};
4242
use crate::tls::MtlsHttpClientProvider;
4343

44-
/// default NMX-T port
45-
const NMXT_PORT: u16 = 9352;
44+
/// Default TCP port for NMX-T.
45+
pub(crate) const NMXT_PORT: u16 = 9352;
4646

4747
/// NMX-T endpoint
4848
const NMXT_ENDPOINT: &str = "/xcset/nvlink_domain_telemetry";

0 commit comments

Comments
 (0)