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

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

/// WriteMeta is used to return meta data about a write
///
/// This struct was generated based on the Go types of the official Nomad API.
#[derive(Clone, Debug, Default, PartialEq, Serialize, Deserialize, Builder)]
pub struct WriteMeta {
    /// How long did the request take
    #[serde(
        rename = "RequestTime",
        serialize_with = "crate::serialize_duration",
        deserialize_with = "crate::deserialize_duration"
    )]
    pub request_time: chrono::TimeDelta,

    /// LastIndex. This can be used as a WaitIndex to perform
    /// a blocking query
    #[serde(rename = "LastIndex")]
    pub last_index: u64,
}
