pub struct GlobalConfig {Show 16 fields
pub admin_addr: Option<SocketAddr>,
pub log_level: String,
pub log_format: String,
pub grace_period: Duration,
pub http_addr: SocketAddr,
pub https_addr: SocketAddr,
pub http3: bool,
pub proxy_protocol: bool,
pub access_log: Option<LogFileConfig>,
pub error_log: Option<LogFileConfig>,
pub tcp_nodelay: bool,
pub tcp_send_buffer: Option<usize>,
pub tcp_recv_buffer: Option<usize>,
pub otlp_endpoint: Option<String>,
pub otlp_service_name: Option<String>,
pub admin_auth_token: Option<String>,
}Expand description
Global settings.
Fields§
§admin_addr: Option<SocketAddr>§log_level: String§log_format: String§grace_period: Duration§http_addr: SocketAddr§https_addr: SocketAddr§http3: boolEnable HTTP/3 (QUIC) listener on the same address as HTTPS.
Only effective when the http3 feature is enabled and TLS is configured.
proxy_protocol: boolWhen true, expect PROXY protocol v1/v2 headers on incoming connections.
access_log: Option<LogFileConfig>§error_log: Option<LogFileConfig>§tcp_nodelay: boolTCP_NODELAY socket option for accepted connections (default: true).
tcp_send_buffer: Option<usize>SO_SNDBUF send buffer size hint (bytes). Platform-specific; may be ignored.
tcp_recv_buffer: Option<usize>SO_RCVBUF receive buffer size hint (bytes). Platform-specific; may be ignored.
otlp_endpoint: Option<String>OTLP collector endpoint for OpenTelemetry traces, e.g. "http://localhost:4317".
Only used when gatel is compiled with the otlp feature.
otlp_service_name: Option<String>Service name reported in OpenTelemetry traces. Defaults to "gatel".
admin_auth_token: Option<String>Bearer token for admin API authentication. When set, all admin API
requests must include Authorization: Bearer <token>.
Trait Implementations§
Source§impl Clone for GlobalConfig
impl Clone for GlobalConfig
Source§fn clone(&self) -> GlobalConfig
fn clone(&self) -> GlobalConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more