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

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

/// This struct was generated based on the Go types of the official Nomad API.
#[derive(Clone, Debug, Default, PartialEq, Serialize, Deserialize, Builder)]
pub struct VariableLock {
    /// ID is generated by Nomad to provide a unique caller ID which can be used
    /// for renewals and unlocking.
    #[serde(rename = "ID")]
    pub id: String,

    /// TTL describes the time-to-live of the current lock holder.
    /// This is a string version of a time.Duration like "2m".
    #[serde(rename = "TTL")]
    pub ttl: String,

    /// LockDelay describes a grace period that exists after a lock is lost,
    /// before another client may acquire the lock. This helps protect against
    /// split-brains. This is a string version of a time.Duration like "2m".
    #[serde(rename = "LockDelay")]
    pub lock_delay: String,
}
