pub enum Event {
Decision {
actor_id: Option<String>,
workspace: String,
op_type: Option<String>,
accepted: bool,
reject_reason: Option<String>,
seq: Option<u64>,
parent: Option<String>,
decision_latency_us: u64,
},
QueueDepth {
depth: usize,
},
WindowResize {
from: usize,
to: usize,
cause: String,
},
CasFailure {
workspace: String,
expected: Option<String>,
actual: Option<String>,
},
}Expand description
One journalled event.
Every variant serializes to a flat JSON object carrying kind and
format_version, so jq 'select(.kind == "decision")' works without
a schema.
Variants§
Decision
The writer accepted or refused one submission.
Fields
QueueDepth
A sample of how many commands were waiting behind the writer.
Fields
WindowResize
The speculative window changed size.
Fields
CasFailure
A compare-and-swap precondition did not hold.
Recorded distinctly from the refusal it also produces, because “two writers raced this ref” is a fact about contention, and a rejection count alone cannot separate it from a client sending nonsense.
Implementations§
Trait Implementations§
impl Eq for Event
impl StructuralPartialEq for Event
Auto Trait Implementations§
impl Freeze for Event
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnsafeUnpin for Event
impl UnwindSafe for Event
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more