pub enum AppSecretManager {
Aws(AwsSecretManager),
Memory(MemorySecretManager),
Json(JsonSecretManager),
}Variants§
Implementations§
Source§impl AppSecretManager
impl AppSecretManager
Sourcepub fn from_config(aws_config: &SdkConfig, config: SecretsManagerConfig) -> Self
pub fn from_config(aws_config: &SdkConfig, config: SecretsManagerConfig) -> Self
Create the secret manager from the provided config
pub async fn get_secret(&self, name: &str) -> Result<Option<Secret>>
pub async fn create_secret(&self, name: &str, value: &str) -> Result<()>
Sourcepub async fn parsed_secret<D: DeserializeOwned>(
&self,
name: &str,
) -> Result<Option<D>>
pub async fn parsed_secret<D: DeserializeOwned>( &self, name: &str, ) -> Result<Option<D>>
Obtains a secret parsing it as JSON of type [D]
Trait Implementations§
Source§impl DbSecretManager for AppSecretManager
impl DbSecretManager for AppSecretManager
async fn get_secret( &self, name: &str, ) -> Result<Option<DbSecrets>, DbConnectErr>
Auto Trait Implementations§
impl !Freeze for AppSecretManager
impl !RefUnwindSafe for AppSecretManager
impl Send for AppSecretManager
impl Sync for AppSecretManager
impl Unpin for AppSecretManager
impl !UnwindSafe for AppSecretManager
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
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 moreCreates a shared type from an unshared type.