pub struct GroupKeyRegistry<R: MembershipResolver> { /* private fields */ }Implementations§
Source§impl<R: MembershipResolver> GroupKeyRegistry<R>
impl<R: MembershipResolver> GroupKeyRegistry<R>
pub fn new(rekey_policy: RekeyPolicy, resolver: R) -> Result<Self, String>
pub async fn register_group( &self, group: GroupRef, controller: ControllerBinding, ) -> Result<(), String>
Sourcepub async fn prepare_change(
&self,
group: &GroupRef,
change: MembershipChange,
new_keyset_id: impl Into<String>,
) -> Result<PreparedEpoch, String>
pub async fn prepare_change( &self, group: &GroupRef, change: MembershipChange, new_keyset_id: impl Into<String>, ) -> Result<PreparedEpoch, String>
Prepare the next epoch and seal it independently to every resulting
member. Current state remains visible until Self::commit_prepared.
Sourcepub async fn commit_prepared(
&self,
group: &GroupRef,
membership_version: u64,
epoch: u64,
) -> Result<(), String>
pub async fn commit_prepared( &self, group: &GroupRef, membership_version: u64, epoch: u64, ) -> Result<(), String>
Atomically make a prepared membership version and epoch visible.
Sourcepub async fn abort_prepared(
&self,
group: &GroupRef,
keyset_id: &str,
membership_version: u64,
epoch: u64,
) -> Result<(), String>
pub async fn abort_prepared( &self, group: &GroupRef, keyset_id: &str, membership_version: u64, epoch: u64, ) -> Result<(), String>
Discard an uncommitted transaction. The committed epoch is untouched.
pub async fn committed_coordinates( &self, group: &GroupRef, ) -> Option<(String, u64, u64)>
pub async fn pending_epoch(&self, group: &GroupRef) -> Option<PreparedEpoch>
pub async fn k_group(&self, group: &GroupRef) -> Option<[u8; 32]>
pub async fn contains_member(&self, group: &GroupRef, subject_did: &str) -> bool
pub async fn needs_rotation(&self, group: &GroupRef) -> bool
pub fn rekey_policy(&self) -> &RekeyPolicy
pub fn now_millis() -> i64
Auto Trait Implementations§
impl<R> Freeze for GroupKeyRegistry<R>where
R: Freeze,
impl<R> !RefUnwindSafe for GroupKeyRegistry<R>
impl<R> Send for GroupKeyRegistry<R>
impl<R> Sync for GroupKeyRegistry<R>
impl<R> Unpin for GroupKeyRegistry<R>where
R: Unpin,
impl<R> UnsafeUnpin for GroupKeyRegistry<R>where
R: UnsafeUnpin,
impl<R> !UnwindSafe for GroupKeyRegistry<R>
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ServiceExt for T
impl<T> ServiceExt for T
§fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
Apply a transformation to the response body. Read more
§fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using HTTP status codes. Read more
§fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using gRPC headers. Read more