Enum Class FcEventType
- All Implemented Interfaces:
Serializable, Comparable<FcEventType>, Constable
Execution outcomes of an
FcCommand, replacing com.netflix.hystrix.HystrixEventType.
The first ten constants are one-for-one with the Hystrix event types Frontcache can produce, and
their rolling counts feed the rollingCount* fields of the dashboard JSON - so the set is
fixed by that wire contract, not by what the code happens to need. COLLAPSED and
RESPONSE_FROM_CACHE are here for exactly that reason: Frontcache never emits them (it
registers no collapsers and does not use request caching), but the dashboard asserts their fields
exist, so the emitter needs a counter to read a zero from.
See docs/archive/hystrix-to-resilience4j-proposal.md sections 4.1 and 7.3.-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionNOT a Hystrix event, and deliberately so.Never emitted - Frontcache registers no collapsers.The command threw out ofexecute()instead of returning a fallback.Never emitted.Never emitted - Frontcache does not use Hystrix request caching. -
Method Summary
Modifier and TypeMethodDescriptionbooleanTrue for the outcomes that mean "the origin/cache call itself did not complete normally".static FcEventTypeReturns the enum constant of this class with the specified name.static FcEventType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
SUCCESS
-
FAILURE
-
TIMEOUT
-
BAD_REQUEST
-
SHORT_CIRCUITED
-
THREAD_POOL_REJECTED
-
SEMAPHORE_REJECTED
-
FALLBACK_SUCCESS
-
FALLBACK_FAILURE
-
FALLBACK_REJECTION
Never emitted. The fallback semaphore is parsed and reported but deliberately not enforced - every call that reaches a fallback already holds an Input-Request permit, so this state is unreachable. Kept sorollingCountFallbackRejectionhas a counter to read 0 from. See proposal section 6.3. -
EXCEPTION_THROWN
The command threw out ofexecute()instead of returning a fallback. -
RESPONSE_FROM_CACHE
Never emitted - Frontcache does not use Hystrix request caching. -
COLLAPSED
Never emitted - Frontcache registers no collapsers. -
BUDGET_OVERRUN_OBSERVED
NOT a Hystrix event, and deliberately so. A semaphore-isolated command that ran past its configured timeout budget. It is observed and reported by the watchdog (FcCommandMetrics.sweepOverruns()) and nothing else: it does not abort the call, is not mapped byFallbackLogger.failureType(List), and must never be counted as a circuit-breaker failure or folded intorollingCountTimeout- Hystrix treats a timeout as a failure, so doing that would move errorPercentage and could open a circuit on a request that succeeded. It surfaces as an additional JSON field, which is safe because the dashboard asserts key presence and ignores extras. See proposal section 6.2.
-
-
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
-
isFailureOutcome
public boolean isFailureOutcome()True for the outcomes that mean "the origin/cache call itself did not complete normally".
-