Class ManagedSecretsProcedure
java.lang.Object
overit.geocall.secrets.procedures.ManagedSecretsProcedure
- All Implemented Interfaces:
SecretsProcedure
Create a new procedure lookup whose fetching logic is managed by a secret manager.
-
Constructor Summary
ConstructorsConstructorDescriptionManagedSecretsProcedure(@NotNull String key, @NotNull overit.geocall.secrets.procedures.WorkingStrategy strategy, long factory, SecretsManagerType type) Create a new secrets procedure lookup based on passed secrets manager type -
Method Summary
-
Constructor Details
-
ManagedSecretsProcedure
public ManagedSecretsProcedure(@NotNull @NotNull String key, @NotNull @NotNull overit.geocall.secrets.procedures.WorkingStrategy strategy, long factory, SecretsManagerType type) Create a new secrets procedure lookup based on passed secrets manager type- Parameters:
key- the configuration keystrategy- the strategy used to fetch the keys and verification phasefactory- the factory idtype-SecretsManagerTypeabout the secrets manager type.
-
-
Method Details
-
getKey
Description copied from interface:SecretsProcedureReturns the configuration key- Specified by:
getKeyin interfaceSecretsProcedure- Returns:
- the configuration key
-
get
Description copied from interface:SecretsProcedureGet the secret fetched- Specified by:
getin interfaceSecretsProcedure- Returns:
- the instance of the fetched secret
- Throws:
SecretsManagerException- in case of errors while communicating with the secret manager or in case the requested secret has not been found.
-
verify
Description copied from interface:SecretsProcedureExecute the validation process- Specified by:
verifyin interfaceSecretsProcedure- Type Parameters:
T- the result type- Parameters:
versionId- the version id. It's mandatory if the strategy isVERSIONED, otherwise it can benull.controller- the validation function- Returns:
- the output produced by the validation function
-