scuffle_bootstrap_telemetry

Trait TelemetryConfig

Source
pub trait TelemetryConfig: Global {
    // Provided methods
    fn enabled(&self) -> bool { ... }
    fn bind_address(&self) -> Option<SocketAddr> { ... }
    fn http_server_name(&self) -> &str { ... }
    fn health_check(&self) -> impl Future<Output = Result<(), Error>> + Send { ... }
    fn prometheus_metrics_registry(&self) -> Option<&Registry> { ... }
    fn opentelemetry(&self) -> Option<&OpenTelemetry> { ... }
}

Provided Methods§

Source

fn enabled(&self) -> bool

Return true if the service is enabled.

Source

fn bind_address(&self) -> Option<SocketAddr>

Return the bind address to listen on.

Source

fn http_server_name(&self) -> &str

Return the http server name.

Source

fn health_check(&self) -> impl Future<Output = Result<(), Error>> + Send

Return a health check to determine if the service is healthy.

Source

fn prometheus_metrics_registry(&self) -> Option<&Registry>

Return a Prometheus metrics registry to scrape metrics from.

Source

fn opentelemetry(&self) -> Option<&OpenTelemetry>

Pass an OpenTelemetry instance to the service. If provided the service will flush and shutdown the OpenTelemetry instance when the service shuts down.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§