Skip to main content

InterventionProxy

Struct InterventionProxy 

Source
pub struct InterventionProxy<S>
where S: ControlledStore,
{ /* private fields */ }
Expand description

Intervention Proxy: durably admits operations, enforcing authorization, idempotency, monotonic stops, revision ordering, and queue admission barriers.

Implementations§

Source§

impl<S> InterventionProxy<S>
where S: ControlledStore,

Source

pub fn new(store: S) -> InterventionProxy<S>

Source

pub fn store(&self) -> &S

Source

pub fn store_mut(&mut self) -> &mut S

Source

pub fn admit( &mut self, principal: &VerifiedPrincipal, request: AdmissionRequest, ) -> Result<AdmissionReceipt, AdmissionConflict>

Admit an operation through the Proxy into the queue.

Source

pub fn filter_graph_view<'a>( &self, principal: &VerifiedPrincipal, graph_id: &str, raw_graph_data: &'a Value, ) -> Result<&'a Value, AdmissionConflict>

Filter inspected graph read model by the principal’s read authority.

Source

pub fn filter_admitted_receipts( &self, principal: &VerifiedPrincipal, receipts: &[AdmissionReceipt], ) -> Result<Vec<AdmissionReceipt>, AdmissionConflict>

Filter a sequence of admitted receipts, returning only those readable by the principal.

Auto Trait Implementations§

§

impl<S> Forget for InterventionProxy<S>

§

impl<S> Freeze for InterventionProxy<S>
where S: Freeze,

§

impl<S> Move for InterventionProxy<S>

§

impl<S> RefUnwindSafe for InterventionProxy<S>
where S: RefUnwindSafe,

§

impl<S> Send for InterventionProxy<S>

§

impl<S> Sync for InterventionProxy<S>

§

impl<S> Unpin for InterventionProxy<S>
where S: Unpin,

§

impl<S> UnsafeUnpin for InterventionProxy<S>
where S: UnsafeUnpin,

§

impl<S> UnwindSafe for InterventionProxy<S>
where S: UnwindSafe,

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> 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, 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.