pub struct RuleAlert {
pub rule_name: String,
pub severity: AlertSeverity,
pub status: AlertStatus,
pub message: String,
pub observed_value: f64,
pub timestamp: DateTime<Utc>,
}Expand description
An alert emitted by AlertEvaluator when a rule trips or recovers.
Named distinctly from crate::event::Alert so both can coexist; this one
is rule-centric (carries the rule name, status, and observed value) whereas
crate::event::Alert is event-centric.
Fields§
§rule_name: StringName of the rule that produced this alert.
severity: AlertSeveritySeverity inherited from the rule.
status: AlertStatusWhether the rule is firing or has resolved.
message: StringHuman-readable description of why the alert fired.
observed_value: f64The observed value that drove the decision (rate, depth, or seconds of silence depending on the rule kind).
timestamp: DateTime<Utc>When the alert was generated.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RuleAlert
impl RefUnwindSafe for RuleAlert
impl Send for RuleAlert
impl Sync for RuleAlert
impl Unpin for RuleAlert
impl UnsafeUnpin for RuleAlert
impl UnwindSafe for RuleAlert
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