pub struct ErrorDetails {Show 17 fields
pub commit_id: Option<CommitId>,
pub committed_seq: Option<ChangeSeq>,
pub committed_fingerprint: Option<String>,
pub operation_index: Option<u32>,
pub fenced_epoch: Option<WriterEpoch>,
pub active_writer_epoch: Option<WriterEpoch>,
pub active_writer: Option<String>,
pub active_acquired_at_ms: Option<u64>,
pub inode_id: Option<InodeId>,
pub expected_revision: Option<RevisionNo>,
pub actual_revision: Option<RevisionNo>,
pub after_seq: Option<ChangeSeq>,
pub retention_floor_seq: Option<ChangeSeq>,
pub requested_deletion_seq: Option<ChangeSeq>,
pub active_deletion_seq: Option<ChangeSeq>,
pub expected_head_seq: Option<ChangeSeq>,
pub actual_head_seq: Option<ChangeSeq>,
}Expand description
Structured, machine-readable context accompanying an ApiError.
Every field is optional: a code populates the fields that apply to it (API spec, “Standard error contract”), and clients must tolerate absent fields exactly as they tolerate unknown codes. Retry decisions still key off the code; these fields carry the identity a caller needs to act — which commit to resubmit, which epoch displaced it, which revision the precondition saw.
Fields§
§commit_id: Option<CommitId>Idempotency key of the commit the error concerns.
committed_seq: Option<ChangeSeq>Sequence at which that commit id already landed. Present when the failure was decided against a durable commit receipt, which is what holds the sequence; absent when nothing has committed under the id yet and two live requests are simply claiming it at once.
committed_fingerprint: Option<String>Semantic identity of the mutation that already landed under that
commit id, from the same receipt as committed_seq and present
exactly when it is. A retry recomputes this value from the request it
just made — see
put_retry_fingerprint — and equality
is what proves the two are the same request.
operation_index: Option<u32>Position, in the request’s operation list, of the operation that failed. A commit applies all of its operations or none of them, so this names the one that stopped the whole request.
fenced_epoch: Option<WriterEpoch>Epoch the failing writer session held when it was displaced.
active_writer_epoch: Option<WriterEpoch>Epoch that currently owns the namespace.
active_writer: Option<String>Writer id recorded by the current epoch’s acquirer, when the head recorded one.
active_acquired_at_ms: Option<u64>Unix milliseconds at which the current epoch’s acquirer took it, when the head recorded one. Writer ids are process labels, so two runs on one machine can share one; the stamp is what tells them apart.
inode_id: Option<InodeId>Inode the failed precondition or operation targeted.
expected_revision: Option<RevisionNo>Revision the request expected to be current.
actual_revision: Option<RevisionNo>Revision that is actually current; absent when the inode has none.
after_seq: Option<ChangeSeq>Change-feed cursor the request asked to resume after.
retention_floor_seq: Option<ChangeSeq>Oldest sequence still promised for incremental replay.
requested_deletion_seq: Option<ChangeSeq>Deletion generation an undelete asked to recover.
active_deletion_seq: Option<ChangeSeq>Deletion generation actually active for the inode.
expected_head_seq: Option<ChangeSeq>Head sequence a namespace delete required the namespace to still be at.
actual_head_seq: Option<ChangeSeq>Head sequence the namespace was actually at, which is what a caller that still means to delete it retries against.
Trait Implementations§
Source§impl Clone for ErrorDetails
impl Clone for ErrorDetails
Source§fn clone(&self) -> ErrorDetails
fn clone(&self) -> ErrorDetails
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more