Interface ExceptionPolicyStrategy
- All Known Implementing Classes:
DefaultExceptionPolicyStrategy
public interface ExceptionPolicyStrategy
A strategy to determine which
ExceptionPolicyKey should handle the thrown exception.
To use a custom implementation, then register the custom ExceptionPolicyStrategy instance to the Camel
Registry.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiongetExceptionPolicy(Set<ExceptionPolicyKey> exceptionPolicies, org.apache.camel.Exchange exchange, Throwable exception) Resolves theExceptionPolicyKeythat should handle the thrown exception.
-
Method Details
-
getExceptionPolicy
ExceptionPolicyKey getExceptionPolicy(Set<ExceptionPolicyKey> exceptionPolicies, org.apache.camel.Exchange exchange, Throwable exception) Resolves theExceptionPolicyKeythat should handle the thrown exception.- Parameters:
exceptionPolicies- the configured exception policies to resolve fromexchange- the exchangeexception- the exception that was thrown- Returns:
- the resolved exception type to handle this exception, null if none found.
-