Skip to main content

OrderingViolation

Enum OrderingViolation 

Source
pub enum OrderingViolation {
    UnauthorizedSubmission {
        subject: Subject,
        order: OrderId,
        authorized_subjects: Vec<Subject>,
    },
    OrderSubjectDrift {
        order: OrderId,
        first: Subject,
        later: Subject,
    },
    AcknowledgmentWithoutSubmission {
        order: OrderId,
    },
    FillWithoutAcknowledgment {
        order: OrderId,
    },
    ReconciliationWithoutFill {
        order: OrderId,
    },
    OutOfOrderTransition {
        order: OrderId,
        attempted: PhaseKind,
        current: Option<PhaseKind>,
    },
    AmbiguousWriteRetriedWithoutKey {
        subject: Subject,
        ambiguous_order: OrderId,
        retry_order: OrderId,
        retry_key: Option<ClientOrderKey>,
    },
    AmbiguityUnavailable {
        subject: Subject,
        prior_order: OrderId,
        retry_order: OrderId,
    },
    DuplicateTransition {
        order: OrderId,
        phase: PhaseKind,
    },
    UnreconciledFill {
        order: OrderId,
    },
    SubmissionWithoutDecision {
        subject: Subject,
        order: OrderId,
    },
    DecisionWithoutObservation {
        subject: Subject,
    },
}
Expand description

An ordering failure in the trading lifecycle.

Block-severity variants are the ones that let an agent move capital without the control that was supposed to gate it. Warn-severity variants are bookkeeping failures: the control ran, the record is incomplete.

Variants§

§

UnauthorizedSubmission

An order was submitted for a subject that had no passing risk evaluation before it. Block severity.

authorized_subjects lists the subjects that were authorized at that point, so the report distinguishes “no risk evaluation ran at all” from “a risk evaluation ran, on something else”. The second case is the one a subject-blind ordering check would wave through.

Fields

§subject: Subject
§order: OrderId
§authorized_subjects: Vec<Subject>
§

OrderSubjectDrift

Two transitions for the same order named different subjects. Block severity: whatever was authorized is not what settled.

Fields

§order: OrderId
§first: Subject
§later: Subject
§

AcknowledgmentWithoutSubmission

An acknowledgment arrived for an order that was never submitted. Block severity.

Fields

§order: OrderId
§

FillWithoutAcknowledgment

An order filled without ever being acknowledged. Block severity.

Fields

§order: OrderId
§

ReconciliationWithoutFill

A reconciliation ran against an order that had not filled. Block severity.

Fields

§order: OrderId
§

OutOfOrderTransition

Any other backwards or skipping transition for an order. Block severity.

Fields

§order: OrderId
§attempted: PhaseKind
§

AmbiguousWriteRetriedWithoutKey

A write whose outcome the trace records as unknown was retried under a different intent, so the venue is free to hold both. Block severity: if the first submission committed, the position just doubled, and no control downstream can tell the two apart.

retry_key names what the retry claimed — None when it claimed nothing, Some when it claimed a key the ambiguous submission did not carry, which is a different order under a borrowed name rather than the same one again.

Fields

§subject: Subject
§ambiguous_order: OrderId
§retry_order: OrderId
§

AmbiguityUnavailable

A resubmission for a subject whose earlier submission has no recorded outcome: neither acknowledged nor marked unobserved. Warn severity, and deliberately not an ambiguous-write finding — the trace does not establish whether the first write was ambiguous, so the check reports the missing evidence instead of guessing a verdict in either direction.

Fields

§subject: Subject
§prior_order: OrderId
§retry_order: OrderId
§

DuplicateTransition

The same stage was recorded twice in a row for one order. Warn severity: duplicated bookkeeping, not a bypassed control.

Fields

§order: OrderId
§

UnreconciledFill

The trace ended with a fill that was never reconciled. Warn severity.

Fields

§order: OrderId
§

SubmissionWithoutDecision

An order was submitted for a subject with no recorded decision. Warn severity: the risk gate still ran, but the stated intent is missing.

Fields

§subject: Subject
§order: OrderId
§

DecisionWithoutObservation

A decision was formed for a subject that was never observed. Warn severity.

Fields

§subject: Subject

Implementations§

Source§

impl OrderingViolation

Source

pub fn is_block(&self) -> bool

Whether this violation is catastrophic (a control was bypassed).

Trait Implementations§

Source§

impl Clone for OrderingViolation

Source§

fn clone(&self) -> OrderingViolation

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for OrderingViolation

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for OrderingViolation

Source§

fn eq(&self, other: &OrderingViolation) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for OrderingViolation

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for OrderingViolation

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.