Enum Class ConsumerCryptoFailureAction
java.lang.Object
java.lang.Enum<ConsumerCryptoFailureAction>
org.apache.pulsar.client.api.v5.auth.ConsumerCryptoFailureAction
- All Implemented Interfaces:
Serializable, Comparable<ConsumerCryptoFailureAction>, Constable
Action a consumer takes when message decryption fails (e.g. the
PrivateKeyProvider cannot be reached, returns no key, or the
ciphertext is malformed).-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic ConsumerCryptoFailureActionReturns the enum constant of this class with the specified name.static ConsumerCryptoFailureAction[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
FAIL
Fail thereceivecall. The application sees the decryption error and the message stays unacknowledged so it will be redelivered. -
DISCARD
Silently acknowledge and skip the message. Useful when the consumer legitimately cannot read some encrypted streams (e.g. a side channel) but should keep moving forward through the rest. -
CONSUME
Deliver the message to the application as-is, with the still-encrypted payload. The application can then handle decryption out-of-band.
-
-
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
-