Class DistributedCounterException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.apache.synapse.commons.throttle.core.DistributedCounterException
- All Implemented Interfaces:
Serializable
Unchecked exception thrown by
DistributedCounterManager operations.
Carries a DistributedCounterException.Kind that classifies the failure so callers can make
fine-grained decisions (retry strategy, log level, alert routing) without
coupling the Synapse layer to any specific backing store or client library.
The convenience method isTransient() derives the transient/permanent
split from DistributedCounterException.Kind, keeping existing callers compatible.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumClassifies the nature of the distributed-counter failure in infrastructure-neutral terms. -
Constructor Summary
ConstructorsConstructorDescriptionDistributedCounterException(String message, Throwable cause, DistributedCounterException.Kind kind) -
Method Summary
Modifier and TypeMethodDescriptiongetKind()Returns the structured failure kind for fine-grained handling.booleanReturnstrueif this exception represents a transient infrastructure failure (DistributedCounterException.Kind.CONNECTION_FAILUREorDistributedCounterException.Kind.POOL_EXHAUSTED) that may succeed on retry.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
DistributedCounterException
public DistributedCounterException(String message, Throwable cause, DistributedCounterException.Kind kind)
-
-
Method Details
-
getKind
Returns the structured failure kind for fine-grained handling. -
isTransient
public boolean isTransient()Returnstrueif this exception represents a transient infrastructure failure (DistributedCounterException.Kind.CONNECTION_FAILUREorDistributedCounterException.Kind.POOL_EXHAUSTED) that may succeed on retry. Returnsfalsefor permanent errors.
-