Open m20b27 opened 3 years ago
The following line
camel.source.endpoint.onCompletionExceptionHandler=org.apache.camel.kafkaconnector.CustomLoggingExceptionHandler
should be
camel.source.endpoint.onCompletionExceptionHandler=#class:org.apache.camel.kafkaconnector.CustomLoggingExceptionHandler
@oscerd It works like a charm! Thanks. Also would be great if this is documented somewhere.
Let's keep this open so we could update the docs. Thanks for pointing this out
I've implemented a custom exceptionHandler for experimenting purpose like below (which is pretty much the same with the LoggingExceptionHandler except I'm using System.out.println() and I've added a prefix for every log):
I've configured the sftp source connector to use my own exceptionHandler:
After I started the connector, I removed the read permission for the local sftp directory to trigger an exception, I was expecting all the error messages have
##### From CustomLoggingExceptionHandler #####:
as prefix, but seems like my CustomLoggingExceptionHandler is not being used at all. Below is the actual error message:Any idea of what's wrong with my approach? or what should be the correct way to set up
camel.source.endpoint.exceptionHandler
for the sftp connector? Thanks