Skip to main content

CheckpointRecordState

Struct CheckpointRecordState 

Source
pub struct CheckpointRecordState {
    pub checkpoint_id: CheckpointId,
    pub namespace_id: NamespaceId,
    pub manifest_id: ManifestId,
    pub manifest_object_id: ManifestObjectId,
    pub manifest_head_seq: ChangeSeq,
    pub manifest_payload_checksum: String,
    pub head_commit_id: CommitId,
    pub created_at_ms: u64,
    pub expires_at_ms: Option<u64>,
    pub owner: CheckpointOwner,
    pub state: CheckpointRecordLifecycle,
}
Expand description

A checkpoint record: pins one metadata manifest (its basis) so garbage collection keeps everything the manifest references.

Stored as its own object under checkpoints/; never part of a manifest and never an input to latest visibility. Created write-then-verify: the record is written active, then the basis manifest is re-verified against the floor, and a failed verification flips the record to released.

Fields§

§checkpoint_id: CheckpointId

Freshly generated record identity, one per logical pin. Nothing derives it, and no caller supplies it, so a new pin can never land on a released record’s key.

§namespace_id: NamespaceId

Source namespace whose manifest and metadata remain pinned.

§manifest_id: ManifestId

Logical manifest position of the pinned basis.

§manifest_object_id: ManifestObjectId

Immutable manifest candidate selected at manifest_id.

§manifest_head_seq: ChangeSeq

Greatest source sequence materialized by the pinned manifest.

§manifest_payload_checksum: String

Must equal payload_checksum in the referenced manifest envelope.

§head_commit_id: CommitId

Commit identity at the pinned manifest head, verified against its payload.

§created_at_ms: u64

Unix-millisecond creation stamp used by GC grace policy, never validity ordering.

§expires_at_ms: Option<u64>

When garbage collection may release this record without asking anyone.

A user pin carries the caller’s ttl_ms, or nothing at all, in which case it is held until released. A fork-owned record always carries one: it is the lease covering a single fork attempt, and its expiry is how an abandoned attempt becomes collectable.

§owner: CheckpointOwner

Party whose durable lifecycle determines when this pin can be released.

§state: CheckpointRecordLifecycle

Current lifecycle, advanced only by the one-way release compare-and-swap.

Trait Implementations§

Source§

impl Clone for CheckpointRecordState

Source§

fn clone(&self) -> CheckpointRecordState

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for CheckpointRecordState

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for CheckpointRecordState

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Eq for CheckpointRecordState

Source§

impl PartialEq for CheckpointRecordState

Source§

fn eq(&self, other: &CheckpointRecordState) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for CheckpointRecordState

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for CheckpointRecordState

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.