pub struct Config {Show 17 fields
pub cronitor_base_url: String,
pub cronitor_api_key: Option<String>,
pub monitor_name: String,
pub server_url: String,
pub endpoint_type: Type,
pub model_name: String,
pub env: String,
pub timeout_seconds: u64,
pub min_success_freq: Option<u8>,
pub schedule: Option<String>,
pub realert_interval: Option<u16>,
pub consecutive_failures: Option<u8>,
pub consecutive_missing: Option<u8>,
pub monitor_group: Option<String>,
pub collection_path: String,
pub environment_path: Option<String>,
pub request_delay_milliseconds: Option<u64>,
}Expand description
Configuration for the monitoring tool
Fields§
§cronitor_base_url: StringBase URL for Cronitor, e.g. https://cronitor.link
cronitor_api_key: Option<String>Base URL for Cronitor, e.g. https://cronitor.link
monitor_name: StringMonitor name / code in Cronitor
server_url: StringBase URL of the server to probe, e.g. https://my-openai-proxy
endpoint_type: TypeOptional: Probe type to use for the probe. Currently only “llm” is supported.
model_name: StringName of the model to query
env: StringEnvironment descriptor (defaults to “production”)
timeout_seconds: u64Request timeout in seconds (default 10)
min_success_freq: Option<u8>The below all require an API key to be set to take effect. minFreqRequiredMins catches inactive alerts - if an alert starts but never completes, it’ll be marked as inactive by Cronitor. To force this into raising an alert, we require a successful ping once per any minFreqRequiredMins period. Beware - this can cause some unpredictable behaviour in Cronitor
schedule: Option<String>Which schedule to display in the frontend and to guide CONSECUTIVE_FAILURES_FOR_ALERT. If none, one isn’t sent to cronitor but will still be running for a cronjob.
realert_interval: Option<u16>How often we want to resend alerts after the first fails, integer in HOURS
consecutive_failures: Option<u8>Optional: how many failed pings are needed to trigger an alert. Cronitor assumes 1 if unset.
consecutive_missing: Option<u8>Optional: how many missing pings are needed to trigger an alert. Cronitor disables this unless specified here as > 0. Requires schedule to be set.
monitor_group: Option<String>Optional: Group to put monitor in, mostly for frontend viewing.
collection_path: StringNewman-specific options
environment_path: Option<String>§request_delay_milliseconds: Option<u64>Trait Implementations§
Source§impl Args for Config
impl Args for Config
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl CommandFactory for Config
impl CommandFactory for Config
Source§impl FromArgMatches for Config
impl FromArgMatches for Config
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.