Package io.digdag.spi
Interface SecretProvider
-
- All Known Implementing Classes:
SecretProvider.ScopedSecretProvider
public interface SecretProviderA VFS style secret access interface.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classSecretProvider.ScopedSecretProviderA secret provider that implements a virtual subtree view.
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default java.lang.StringgetSecret(java.lang.String key)Get a secret identified by a key.com.google.common.base.Optional<java.lang.String>getSecretOptional(java.lang.String key)Get a secret identified by a key.default SecretProvidergetSecrets(java.lang.String path)Get a view of a subtree of the secret VFS.
-
-
-
Method Detail
-
getSecret
default java.lang.String getSecret(java.lang.String key)
Get a secret identified by a key.- Parameters:
key- A key identifing the secret to get.- Returns:
- A secret.
- Throws:
SecretNotFoundException- if no matching secret was found.
-
getSecretOptional
com.google.common.base.Optional<java.lang.String> getSecretOptional(java.lang.String key)
Get a secret identified by a key.- Parameters:
key- A key identifing the secret to get.- Returns:
Optional.of(Object)with a secret orOptional.absent()if no matching secret was found.
-
getSecrets
default SecretProvider getSecrets(java.lang.String path)
Get a view of a subtree of the secret VFS. All secret accesses by the returnedSecretProviderare prefixed by the specified path.
-
-