pub struct BoxLock {
pub locked: bool,
pub user: Option<String>,
pub holder_type: Option<String>,
pub locked_at: Option<String>,
pub last_heartbeat: Option<String>,
pub ttl_seconds: Option<i64>,
pub previous_user: Option<String>,
}Expand description
Box lock state, as returned by the /lock family of endpoints (the same
ones lager boxes lock uses). locked: false with everything else
None means the box is free.
Fields§
§locked: boolWhether the box is currently locked.
user: Option<String>Lock holder.
holder_type: Option<String>Holder classification ("user", "ci", "ephemeral", or another
service’s reservation origin).
locked_at: Option<String>When the lock was acquired (ISO 8601 UTC).
last_heartbeat: Option<String>Last heartbeat (ISO 8601 UTC).
ttl_seconds: Option<i64>Lock TTL in seconds; None means the lock never auto-expires.
previous_user: Option<String>On acquire: the holder before this call (None when the box was
free). Distinguishes “just acquired” from “already held it”.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for BoxLock
impl<'de> Deserialize<'de> for BoxLock
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for BoxLock
impl RefUnwindSafe for BoxLock
impl Send for BoxLock
impl Sync for BoxLock
impl Unpin for BoxLock
impl UnsafeUnpin for BoxLock
impl UnwindSafe for BoxLock
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more