Details
-
Improvement
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
Unknown
Description
I think we should be able to allow finer control of which exceptions can trigger a pause and which doesn't. For instance, we should be able to do something like:
onException(SomeException.class) .pausable(consumerListener, o -> canContinue()); from(from).routeId("pausable-it") .process(exchange -> LOG.info("Got record from Kafka: {}", exchange.getMessage().getBody())) .to(intermediate);
So that if AnotherException is thrown, the consumer does not pause.
Note: those using the circuit breaker can already filter unwanted exceptions via the event publisher - although, it is not very elegant.