Enum Class Guarantee
- All Implemented Interfaces:
Serializable
,Comparable<Guarantee>
,Constable
Guarantees define how long an operation (e.g., sending a message or applying a state change) should wait before considering itself complete.
These guarantees are especially relevant when sending messages through gateways such as CommandGateway
or
when scheduling and persisting state changes to the Flux platform.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Method Summary
-
Enum Constant Details
-
NONE
No delivery guarantee is enforced.Operations complete immediately after dispatching, without waiting for acknowledgment from Flux Capacitor or local processing results.
Use this when performance is more important than confirmation, or when confirmation is handled separately.
-
SENT
Guarantees that the message or action was sent successfully.This includes:
- Local delivery to registered handlers
- Sending the message to the Flux Capacitor service
If a message is handled entirely locally, the operation completes once the local handling is done. If the message is sent remotely, the operation waits for acknowledgment that it was sent successfully.
-
STORED
Guarantees that the message or action was stored by Flux Capacitor.The operation waits until a receipt or acknowledgment from Flux Capacitor confirms that the message or state change has been durably stored.
This is the highest level of guarantee and ensures that the message won't be lost even if there is a failure after dispatch.
-
-
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
-