pub struct BasicConf {Show 25 fields
pub name: Option<String>,
pub error_template: Option<String>,
pub pid_file: Option<String>,
pub upgrade_sock: Option<String>,
pub user: Option<String>,
pub group: Option<String>,
pub threads: Option<usize>,
pub work_stealing: Option<bool>,
pub listener_tasks_per_fd: Option<usize>,
pub grace_period: Option<Duration>,
pub graceful_shutdown_timeout: Option<Duration>,
pub upstream_keepalive_pool_size: Option<usize>,
pub webhook: Option<String>,
pub webhook_type: Option<String>,
pub webhook_notifications: Option<Vec<String>>,
pub log_level: Option<String>,
pub log_buffered_size: Option<ByteSize>,
pub log_format_json: Option<bool>,
pub sentry: Option<String>,
pub pyroscope: Option<String>,
pub auto_restart_check_interval: Option<Duration>,
pub log_compress_algorithm: Option<String>,
pub log_compress_level: Option<u8>,
pub log_compress_days_ago: Option<u16>,
pub log_compress_time_point_hour: Option<u8>,
}Expand description
Basic configuration options for the application
Fields§
§name: Option<String>Application name
error_template: Option<String>Error page template
pid_file: Option<String>Path to PID file (default: /run/pingap.pid)
upgrade_sock: Option<String>Unix domain socket path for graceful upgrades(default: /tmp/pingap_upgrade.sock)
user: Option<String>User for daemon
group: Option<String>Group for daemon
threads: Option<usize>Number of worker threads(default: 1)
work_stealing: Option<bool>Enable work stealing between worker threads(default: true)
listener_tasks_per_fd: Option<usize>Number of listener tasks to use per fd. This allows for parallel accepts.
grace_period: Option<Duration>Grace period before forcefully terminating during shutdown(default: 5m)
graceful_shutdown_timeout: Option<Duration>Maximum time to wait for graceful shutdown
upstream_keepalive_pool_size: Option<usize>Maximum number of idle connections to keep in upstream connection pool
webhook: Option<String>Webhook URL for notifications
webhook_type: Option<String>Type of webhook (e.g. “wecom”, “dingtalk”)
webhook_notifications: Option<Vec<String>>List of events to send webhook notifications for
log_level: Option<String>Log level (debug, info, warn, error)
log_buffered_size: Option<ByteSize>Size of log buffer before flushing
log_format_json: Option<bool>Whether to format logs as JSON
sentry: Option<String>Sentry DSN for error reporting
pyroscope: Option<String>Pyroscope server URL for continuous profiling
auto_restart_check_interval: Option<Duration>How often to check for configuration changes that require restart
log_compress_algorithm: Option<String>§log_compress_level: Option<u8>Log compress level
log_compress_days_ago: Option<u16>Log compress days ago
log_compress_time_point_hour: Option<u8>Log compress time point hour
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for BasicConf
impl<'de> Deserialize<'de> for BasicConf
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for BasicConf
impl RefUnwindSafe for BasicConf
impl Send for BasicConf
impl Sync for BasicConf
impl Unpin for BasicConf
impl UnsafeUnpin for BasicConf
impl UnwindSafe for BasicConf
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request