pub struct ChunkComponentRevisions { /* private fields */ }Expand description
Component revisions for a one-step chunk definition.
Implementations§
Source§impl ChunkComponentRevisions
impl ChunkComponentRevisions
Sourcepub const fn new(
reader: ComponentRevision,
processor: ComponentRevision,
writer: ComponentRevision,
checkpoint: ComponentRevision,
restart: ChunkRestartContract,
) -> Self
pub const fn new( reader: ComponentRevision, processor: ComponentRevision, writer: ComponentRevision, checkpoint: ComponentRevision, restart: ChunkRestartContract, ) -> Self
Constructs the four restart-relevant chunk component revisions.
Registers no ItemStream namespaces and no completion-policy
revision; use with_stream_revision and
with_completion_policy_revision
to add them.
Sourcepub fn with_stream_revision(
self,
identity: ComponentStreamIdentity,
revision: ComponentRevision,
) -> Self
pub fn with_stream_revision( self, identity: ComponentStreamIdentity, revision: ComponentRevision, ) -> Self
Registers one ItemStream namespace’s restart-relevant revision.
Namespaces are kept in a deterministic (sorted, not insertion) order so the manifest and fingerprint never depend on registration order. A definition with no registered streams produces a manifest and fingerprint byte-for-byte identical to one built before this method existed.
Sourcepub fn stream_revisions(
&self,
) -> impl Iterator<Item = (&ComponentStreamIdentity, &ComponentRevision)>
pub fn stream_revisions( &self, ) -> impl Iterator<Item = (&ComponentStreamIdentity, &ComponentRevision)>
Iterates registered ItemStream namespace revisions in deterministic
(sorted) order.
Sourcepub fn with_completion_policy_revision(
self,
revision: ComponentRevision,
) -> Self
pub fn with_completion_policy_revision( self, revision: ComponentRevision, ) -> Self
Records the restart-relevant revision of an installed
crate::CompletionPolicy
(an early-completion policy supplementing the chunk’s ChunkSize
ceiling).
A definition with no completion policy installed produces a manifest and fingerprint byte-for-byte identical to one built before this method existed.
Sourcepub const fn completion_policy_revision(&self) -> Option<&ComponentRevision>
pub const fn completion_policy_revision(&self) -> Option<&ComponentRevision>
Borrows the completion policy’s restart-relevant revision, if one was registered.
Sourcepub const fn delivery_mode(&self) -> ChunkDeliveryMode
pub const fn delivery_mode(&self) -> ChunkDeliveryMode
Returns the delivery mode declared by the restart contract.
Sourcepub const fn in_flight_policy(&self) -> InFlightPolicy
pub const fn in_flight_policy(&self) -> InFlightPolicy
Returns the shutdown policy of an already-open chunk.
Sourcepub const fn reader(&self) -> &ComponentRevision
pub const fn reader(&self) -> &ComponentRevision
Borrows the revision of the component that reads items.
Sourcepub const fn processor(&self) -> &ComponentRevision
pub const fn processor(&self) -> &ComponentRevision
Borrows the revision of the component that processes items.
Sourcepub const fn writer(&self) -> &ComponentRevision
pub const fn writer(&self) -> &ComponentRevision
Borrows the revision of the component that writes items.
Sourcepub const fn checkpoint(&self) -> &ComponentRevision
pub const fn checkpoint(&self) -> &ComponentRevision
Borrows the revision of the component that produces checkpoints.
Sourcepub const fn checkpoint_schema(&self) -> &StateSchemaId
pub const fn checkpoint_schema(&self) -> &StateSchemaId
Borrows the declared checkpoint schema.
Sourcepub const fn checkpoint_schema_version(&self) -> StateSchemaVersion
pub const fn checkpoint_schema_version(&self) -> StateSchemaVersion
Returns the declared checkpoint schema version.
Sourcepub const fn context_schema(&self) -> &StateSchemaId
pub const fn context_schema(&self) -> &StateSchemaId
Borrows the declared execution-context schema.
Sourcepub const fn context_schema_version(&self) -> StateSchemaVersion
pub const fn context_schema_version(&self) -> StateSchemaVersion
Returns the declared execution-context schema version.