Struct persist::indexed::AppliedState[][src]

struct AppliedState {
    saved_seqno: SeqNo,
    highest_assigned_seqno: SeqNo,
    id_mapping: Vec<StreamRegistration>,
    graveyard: Vec<StreamRegistration>,
    arrangements: BTreeMap<Id, Arrangement>,
}
Expand description

The cumulative state that results from applying some prefix of the persist state change log.

BlobMeta is the serialized version of exactly this state.

Fields

saved_seqno: SeqNohighest_assigned_seqno: SeqNoid_mapping: Vec<StreamRegistration>graveyard: Vec<StreamRegistration>arrangements: BTreeMap<Id, Arrangement>

Implementations

Drain pending writes to unsealed.

The caller is responsible for committing metadata after this succeeds, and restoring metadata if this fails.

Construct a new BlobUnsealedBatch out of the provided updates and add it to the unsealed for id.

The caller is responsible for updating META after they’ve finished updating unsealeds.

Atomically moves all writes in unsealed not in advance of the trace’s seal frontier into the trace and does any necessary resulting eviction work to remove unnecessary batches.

Returns the current “sealed” frontier for an id.

This frontier represents a contract of time such that all updates with a time less than it have arrived. This frontier is advanced though the seal method. Once a time has been sealed for an id, it becomes an error to later seal it at an time less than the sealed frontier. It is also an error to write new data with a time less than the sealed frontier.

Apply a seal command to in-memory state if it is valid.

Appends the given batch to the unsealed for id, writing the data into blob storage.

The caller is responsible for updating META after they’ve finished updating unsealeds.

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more