Testing error handlers in elasticsearch 6.5 (kafka to ES)

https://www.elastic.co/guide/en/elasticsearch/hadoop/current/errorhandlers.html

Does anyone has working example of error handling for elasticsearch? I am exploring the elasticsearch 6.5 where error handlers are provided to pipe erroreous records to files

Example:
error.handler.writeFile = org.myproject.myhandlers.OutputToFileHandler es.write.rest.error.handler.writeFile.filename = /path/to/some/output/file

Currently, i am not sure how can i produce sample erroreous records for testing of this feature.
So far, I have placed the error handlers codes into my scala program and managed to compile and run successfully. Records are able to read from kafka and write into ES

Any help would be appreciated on this. Thank you!

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.