@Experimental public enum SwitchReason extends Enum<SwitchReason>
DatabaseSwitchEvent| Enum Constant and Description |
|---|
CIRCUIT_BREAKER
Switch was triggered by circuit breaker.
|
FAILBACK
Switch was triggered to failback to a more weighted database.
|
FORCED
Switch was triggered by user request.
|
HEALTH_CHECK
Switch was triggered by health check.
|
| Modifier and Type | Method and Description |
|---|---|
static SwitchReason |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SwitchReason[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SwitchReason HEALTH_CHECK
public static final SwitchReason CIRCUIT_BREAKER
public static final SwitchReason FAILBACK
public static final SwitchReason FORCED
public static SwitchReason[] values()
for (SwitchReason c : SwitchReason.values()) System.out.println(c);
public static SwitchReason valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullCopyright © 2026 lettuce.io. All rights reserved.