pub enum DatabaseImagePublication {
Rebound {
receipt: DatabaseImageReceipt,
},
CommittedConnectionPoisoned {
receipt: DatabaseImageReceipt,
detail: String,
},
}Expand description
Outcome of a whole-database-image publication that crossed its commit point.
Both variants mean the replacement image is durable. They differ only in
whether the publishing connection survived the mandatory post-commit rebind,
which is why publication cannot report success as a bare (): a caller that
keeps using a poisoned connection would read stale root-page bindings from
an image that no longer exists.
Precommit refusals, validation failures, races, and rollback-complete faults
are returned as Err instead, never as a variant here.
Variants§
Rebound
The image committed and this live connection was rebound successfully.
Fields
receipt: DatabaseImageReceiptExact receipt of the counter-repaired, validated candidate bytes.
CommittedConnectionPoisoned
The image committed, but this live connection could not be rebound and has been permanently poisoned against later operations.
Fields
receipt: DatabaseImageReceiptExact receipt of the committed candidate bytes.
Implementations§
Source§impl DatabaseImagePublication
impl DatabaseImagePublication
Sourcepub const fn receipt(&self) -> &DatabaseImageReceipt
pub const fn receipt(&self) -> &DatabaseImageReceipt
Exact receipt of the image that crossed the durable commit point.
Sourcepub const fn connection_is_usable(&self) -> bool
pub const fn connection_is_usable(&self) -> bool
Whether the publishing connection is usable for subsequent operations.
Sourcepub fn poison_detail(&self) -> Option<&str>
pub fn poison_detail(&self) -> Option<&str>
Rebind-failure detail when the committed connection was poisoned.
Trait Implementations§
Source§impl Clone for DatabaseImagePublication
impl Clone for DatabaseImagePublication
Source§fn clone(&self) -> DatabaseImagePublication
fn clone(&self) -> DatabaseImagePublication
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more