pub struct MetadataCompactionLeaseState {
pub job_id: MetadataCompactionId,
pub namespace_id: NamespaceId,
pub writer_id: String,
pub status: CompactionLeaseStatus,
pub started_at_ms: u64,
pub heartbeat_at_ms: u64,
}Expand description
Records ownership of a streaming compaction’s output prefix.
The lease contains no cursor, output descriptor, or progress. The job refreshes it while running. Garbage collection claims an expired lease by compare-and-swap before reclaiming the prefix (format spec, “Garbage collection”, rule 12).
Fields§
§job_id: MetadataCompactionIdJob this lease belongs to, which is also the prefix its output sits under.
namespace_id: NamespaceIdNamespace whose family group the job is rebuilding.
writer_id: StringWriter identity the job runs under, for an operator reading the object. This is the same label the namespace head records.
status: CompactionLeaseStatusWho owns the prefix: the job that wrote the lease, or the collector that claimed it.
started_at_ms: u64Unix-millisecond stamp of the job’s first lease write.
heartbeat_at_ms: u64Unix-millisecond stamp of the most recent lease write, and the only
input to whether an active lease has expired.
Trait Implementations§
Source§impl Clone for MetadataCompactionLeaseState
impl Clone for MetadataCompactionLeaseState
Source§fn clone(&self) -> MetadataCompactionLeaseState
fn clone(&self) -> MetadataCompactionLeaseState
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more