Package org.apache.juneau.commons.secret
Enum Class FailMode
- All Implemented Interfaces:
Serializable,Comparable<FailMode>,Constable
The policy a network- or OS-backed
SecretStore applies when its backing store cannot answer — for
example when the OS keychain tool is missing or a remote vault is unreachable.
Modeled on the FailMode of ReplayCache: the policy is a
consumer decision rather than a fixed SPI behavior. The built-in InMemorySecretStore and
EnvVarSecretStore never encounter an unavailable backend, so this enum is only meaningful for the
out-of-commons implementations that reach an external secret backend.
Note this is orthogonal to a key simply being absent — a store that successfully answers "no secret
under this key" is not a failure and is never resolved through a FailMode.
- Since:
- 10.0.0
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionTreat a backend failure as an error and propagate it, so the operation fails loudly rather than silently reporting a secret as absent (the safe default).Treat a backend failure as a missing secret:findreturns empty,exists/deletereturnfalse (availability-preserving). -
Method Summary
-
Enum Constant Details
-
FAIL_OPEN
Treat a backend failure as a missing secret:findreturns empty,exists/deletereturnfalse (availability-preserving). -
FAIL_CLOSED
Treat a backend failure as an error and propagate it, so the operation fails loudly rather than silently reporting a secret as absent (the safe default).
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-