msr_plugin_csv_event_journal/api/
event.rs

1use super::{Config, State};
2
3#[derive(Debug, Clone)]
4pub enum Event {
5    Lifecycle(LifecycleEvent),
6    Notification(NotificationEvent),
7    Incident(IncidentEvent),
8}
9
10/// Common lifecycle events
11#[derive(Debug, Clone)]
12pub enum LifecycleEvent {
13    Started,
14    Stopped,
15    ConfigChanged(Config),
16    StateChanged(State),
17}
18
19/// Regular notifications for informational purposes
20#[derive(Debug, Clone)]
21pub struct NotificationEvent {
22    // Empty placeholder
23}
24
25/// Unexpected incidents that might require (manual) intervention
26#[derive(Debug, Clone)]
27pub enum IncidentEvent {
28    IoWriteError {
29        os_code: Option<i32>,
30        message: String,
31    },
32}