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

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

/// Recommendation is used to serialize a recommendation.
///
/// This struct was generated based on the Go types of the official Nomad API.
#[derive(Clone, Debug, Default, PartialEq, Serialize, Deserialize, Builder)]
pub struct Recommendation {
    #[serde(rename = "Region")]
    pub region: String,

    #[serde(rename = "JobVersion")]
    pub job_version: u64,

    #[serde(rename = "ModifyIndex")]
    pub modify_index: u64,

    #[serde(rename = "Namespace")]
    pub namespace: String,

    #[serde(rename = "Value")]
    pub value: i64,

    #[serde(rename = "Current")]
    pub current: i64,

    #[serde(rename = "Stats")]
    pub stats: std::collections::HashMap<String, f64>,

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

    #[serde(rename = "EnforceVersion")]
    pub enforce_version: bool,

    #[serde(rename = "ID")]
    pub id: String,

    #[serde(rename = "Group")]
    pub group: String,

    #[serde(rename = "Task")]
    pub task: String,

    #[serde(rename = "Resource")]
    pub resource: String,

    #[serde(rename = "Meta")]
    pub meta: std::collections::HashMap<String, serde_json::Value>,

    #[serde(rename = "JobID")]
    pub job_id: String,

    #[serde(rename = "SubmitTime")]
    pub submit_time: i64,
}
