pub struct Registry { /* private fields */ }Expand description
Registry state container.
Implementations§
Source§impl Registry
impl Registry
Sourcepub fn builder() -> RegistryBuilder
pub fn builder() -> RegistryBuilder
Create a RegistryBuilder for advanced configuration.
Sourcepub async fn register(
&self,
registration: IdentityProviderRegistration,
) -> Result<()>
pub async fn register( &self, registration: IdentityProviderRegistration, ) -> Result<()>
Register or update a provider configuration.
Sourcepub async fn resolve(
&self,
tenant_id: &str,
provider_id: &str,
kid: Option<&str>,
) -> Result<Arc<JwkSet>>
pub async fn resolve( &self, tenant_id: &str, provider_id: &str, kid: Option<&str>, ) -> Result<Arc<JwkSet>>
Resolve JWKS for a tenant/provider pair.
Sourcepub async fn refresh(&self, tenant_id: &str, provider_id: &str) -> Result<()>
pub async fn refresh(&self, tenant_id: &str, provider_id: &str) -> Result<()>
Trigger a manual refresh for a registered provider.
Sourcepub async fn unregister(
&self,
tenant_id: &str,
provider_id: &str,
) -> Result<bool>
pub async fn unregister( &self, tenant_id: &str, provider_id: &str, ) -> Result<bool>
Remove a provider registration if present.
Sourcepub async fn provider_status(
&self,
tenant_id: &str,
provider_id: &str,
) -> Result<ProviderStatus>
pub async fn provider_status( &self, tenant_id: &str, provider_id: &str, ) -> Result<ProviderStatus>
Fetch status information for a specific provider.
Sourcepub async fn all_statuses(&self) -> Vec<ProviderStatus>
pub async fn all_statuses(&self) -> Vec<ProviderStatus>
Fetch status for every registered provider.
Sourcepub async fn persist_all(&self) -> Result<()>
pub async fn persist_all(&self) -> Result<()>
Persist snapshots for every provider when persistence is configured.
Sourcepub async fn restore_from_persistence(&self) -> Result<()>
pub async fn restore_from_persistence(&self) -> Result<()>
Restore cached entries from persistence for all active registrations.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Registry
impl !RefUnwindSafe for Registry
impl Send for Registry
impl Sync for Registry
impl Unpin for Registry
impl !UnwindSafe for Registry
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