MistAlarm

Struct MistAlarm 

Source
pub struct MistAlarm {
Show 30 fields pub alert_id: Option<String>, pub category: Option<String>, pub aps: Option<Vec<String>>, pub count: u32, pub detail: Option<String>, pub details: Option<MistAlarmDetails>, pub email_content: Option<MistEmailContent>, pub fw_version: Option<String>, pub group: String, pub hostnames: Option<Vec<String>>, pub id: String, pub impacted_entities: Option<Vec<MistImpactedEntity>>, pub impacted_entity_count: Option<u16>, pub last_seen: String, pub model: Option<String>, pub org_id: String, pub org_name: Option<String>, pub peer: Option<Map<String, Value>>, pub port_id: Option<String>, pub port_ids: Option<Vec<String>>, pub reasons: Option<Vec<String>>, pub root_cause: Option<String>, pub severity: String, pub site_id: String, pub site_name: String, pub status: Option<String>, pub suggestion: Option<String>, pub switches: Option<Vec<String>>, pub timestamp: f64, pub type: String,
}
Expand description

Mist Alarm Payload

Fields§

§alert_id: Option<String>

Alert Id

§category: Option<String>

Alert Category

§aps: Option<Vec<String>>

Optional list of access point IDs

§count: u32

Count of alarms seen

§detail: Option<String>

Optional Detail

§details: Option<MistAlarmDetails>

Optional Details object

§email_content: Option<MistEmailContent>

Email Content

§fw_version: Option<String>

Firmware Version (Optional)

§group: String

Group

§hostnames: Option<Vec<String>>

Optional list of hostnames

§id: String

Alarm Id

§impacted_entities: Option<Vec<MistImpactedEntity>>

Timestamp of last occurance Impacted Entities

§impacted_entity_count: Option<u16>

Impacted Entity Count

§last_seen: String

Last Seen Timestamp

§model: Option<String>

Model

§org_id: String

Organisation Id

§org_name: Option<String>

Organisation Name

§peer: Option<Map<String, Value>>

Peer (Optional)

§port_id: Option<String>

Port Id

§port_ids: Option<Vec<String>>

Port Ids

§reasons: Option<Vec<String>>

Optional reason if known

§root_cause: Option<String>

Severity: CRITICAL, MAJOR, MINOR, WARN, INFO Root Cause (if known)

§severity: String

Alarm Severity

§site_id: String

Site Id

§site_name: String

Site Name

§status: Option<String>

Status

§suggestion: Option<String>

Suggestion

§switches: Option<Vec<String>>

Optional list of switches

§timestamp: f64

ISO Timestamp of this event

§type: String

Categorisation of alarm

Implementations§

Source§

impl MistAlarm

Source

pub fn split<F>(event: &MistAlarm, get_ci: F) -> Option<Vec<MistAlarm>>
where F: FnOnce(String) -> String,

Split an event by hostname

§Input

A normal MistAlarm event payload

§Output

Vector of MistAlarm payloads each with only a single hostname.

Trait Implementations§

Source§

impl Clone for MistAlarm

Source§

fn clone(&self) -> MistAlarm

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for MistAlarm

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for MistAlarm

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for MistAlarm

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CloneToUninit for T
where T: Clone,

§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,