pub struct ActiveLock {
pub lock_key: String,
pub holder_agent: String,
pub task_id: Option<String>,
pub acquired_at: String,
pub ttl_secs: u64,
}Expand description
An active mutex lock held by an agent.
Fields§
§lock_key: String§holder_agent: String§task_id: Option<String>§acquired_at: String§ttl_secs: u64Implementations§
Source§impl ActiveLock
impl ActiveLock
Sourcepub fn is_expired(&self) -> bool
pub fn is_expired(&self) -> bool
Check if this lock has expired based on current time.
Trait Implementations§
Source§impl Clone for ActiveLock
impl Clone for ActiveLock
Source§fn clone(&self) -> ActiveLock
fn clone(&self) -> ActiveLock
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ActiveLock
impl Debug for ActiveLock
Source§impl<'de> Deserialize<'de> for ActiveLock
impl<'de> Deserialize<'de> for ActiveLock
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ActiveLock, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ActiveLock, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for ActiveLock
impl Serialize for ActiveLock
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for ActiveLock
impl RefUnwindSafe for ActiveLock
impl Send for ActiveLock
impl Sync for ActiveLock
impl Unpin for ActiveLock
impl UnsafeUnpin for ActiveLock
impl UnwindSafe for ActiveLock
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