pub struct CredentialRegistry { /* private fields */ }Expand description
Validated references plus provider implementations, without serialized secret values.
Implementations§
Source§impl CredentialRegistry
impl CredentialRegistry
pub fn new(declarations: Vec<CredentialConfig>) -> Result<Self, CredentialError>
Sourcepub fn register_provider(
&mut self,
name: String,
provider: Arc<dyn CredentialProvider>,
) -> Result<(), CredentialError>
pub fn register_provider( &mut self, name: String, provider: Arc<dyn CredentialProvider>, ) -> Result<(), CredentialError>
Registration cannot replace an existing provider, including the built-in env adapter.
pub fn kind(&self, name: &str) -> Result<CredentialKind, CredentialError>
pub fn cache_lifetime( &self, name: &str, ) -> Result<CredentialCacheLifetime, CredentialError>
pub fn resolve(&self, name: &str) -> Result<CredentialMaterial, CredentialError>
pub fn update( &self, name: &str, material: Vec<u8>, ) -> Result<(), CredentialError>
Auto Trait Implementations§
impl !RefUnwindSafe for CredentialRegistry
impl !UnwindSafe for CredentialRegistry
impl Freeze for CredentialRegistry
impl Send for CredentialRegistry
impl Sync for CredentialRegistry
impl Unpin for CredentialRegistry
impl UnsafeUnpin for CredentialRegistry
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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