/*
 * This is an auto-generated file.
 * Any manual changes may be overwritten without notice!
 */

use derive_builder::Builder;
use serde::{Deserialize, Serialize};

/// NodeEvent is a single unit representing a node’s state change
///
/// This struct was generated based on the Go types of the official Nomad API.
#[derive(Clone, Debug, Default, PartialEq, Serialize, Deserialize, Builder)]
pub struct NodeEvent {
    #[serde(rename = "Subsystem")]
    pub subsystem: String,

    #[serde(rename = "Details")]
    pub details: std::collections::HashMap<String, String>,

    #[serde(rename = "Timestamp")]
    pub timestamp: chrono::DateTime<chrono::Utc>,

    #[serde(rename = "CreateIndex")]
    pub create_index: u64,

    #[serde(rename = "Message")]
    pub message: String,
}
