Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-4680

Improve error handling in Publish/Consume Kafka processors

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.5.0
    • Extensions
    • None

    Description

      While reviewing NIFI-4639, I encountered a couple of issues surrounding how NiFi handles errors in the Publish and Consume Kafka processors.

      If interacting with the Hortonworks Schema Registry and unable to connect to it, the Exception that was thrown was a RuntimeException instead of an IOException. This resulted in ConsumeKafkaRecord continuing to try to parse every record it received. This could cause it to take a very long time to stop the processor in such a case.

      On the publisher side if this happened, some flowfiles were transferred back to their original queues and then attempted to transfer to failure. As a result, the session would rollback instead of transferring anything to failure, and an error message would indicate that flowfile was already transferred.

      When attempting to rollback consumed records, a NPE was thrown if reading from the beginning of the topic (no offsets had been committed).

      Attachments

        Issue Links

          Activity

            People

              markap14 Mark Payne
              markap14 Mark Payne
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: