pub struct CreateAlertRuleParams {
pub name: String,
pub severity: AlertSeverity,
pub rule_config: AlertRuleConfig,
pub description: Option<String>,
pub summary: Option<String>,
pub enabled: Option<bool>,
pub domain: Option<AlertDomain>,
pub time_aggregation: Option<String>,
pub notification_channel_ids: Vec<String>,
}Expand description
The parameters for AlertRulesResource::create.
Fields§
§name: StringThe rule’s display name. Required.
severity: AlertSeverityThe rule’s severity. Required.
rule_config: AlertRuleConfigThe rule’s config. Required.
description: Option<String>The rule’s description.
summary: Option<String>A summary applied to the underlying alert. Not stored on the rule record.
enabled: Option<bool>Whether the alert is active. Surfaces as status, not a returned
enabled field.
domain: Option<AlertDomain>The rule’s domain.
time_aggregation: Option<String>Used when building the alert query. Not persisted on the rule record.
notification_channel_ids: Vec<String>The notification channels to deliver to.
Implementations§
Source§impl CreateAlertRuleParams
impl CreateAlertRuleParams
Sourcepub fn new(
name: impl Into<String>,
severity: AlertSeverity,
rule_config: AlertRuleConfig,
) -> Self
pub fn new( name: impl Into<String>, severity: AlertSeverity, rule_config: AlertRuleConfig, ) -> Self
The required fields, leaving everything else unset.
Trait Implementations§
Source§impl Clone for CreateAlertRuleParams
impl Clone for CreateAlertRuleParams
Source§fn clone(&self) -> CreateAlertRuleParams
fn clone(&self) -> CreateAlertRuleParams
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CreateAlertRuleParams
impl Debug for CreateAlertRuleParams
Auto Trait Implementations§
impl Freeze for CreateAlertRuleParams
impl RefUnwindSafe for CreateAlertRuleParams
impl Send for CreateAlertRuleParams
impl Sync for CreateAlertRuleParams
impl Unpin for CreateAlertRuleParams
impl UnsafeUnpin for CreateAlertRuleParams
impl UnwindSafe for CreateAlertRuleParams
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
Mutably borrows from an owned value. Read more