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

FetchS3Object gets stuck with Key cannot be empty

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Patch Available
    • Major
    • Resolution: Unresolved
    • 1.11.4, 1.12.1
    • None
    • Core Framework
    • None

    Description

      When setting property Object Key of FetchS3Object in flow file attribute expression language and it evaluates as empty string (or null) processor throws IllegalArgumentException: Key cannot be empty. FlowFiles gets stuck and penalized infinitely.

       

      FlowFiles must transfer into failure relation in that case.

       

       

       

      at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)
      at org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:213)
      at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1176)
      at org.apache.nifi.processors.aws.s3.FetchS3Object.onTrigger(FetchS3Object.java:159)
      at com.amazonaws.services.s3.AmazonS3Client.getObject(AmazonS3Client.java:1436)
      at com.amazonaws.util.ValidationUtils.assertStringNotEmpty(ValidationUtils.java:89)
      java.lang.IllegalArgumentException: Key cannot be empty
      apache-nifi-1 log: 2020-08-11 13:24:26,943 ERROR [Timer-Driven Process Thread-10] o.a.nifi.processors.aws.s3.FetchS3Object FetchS3Object[id=50445e3e-d1a8-1269-0000-0000227b631b] FetchS3Object[id=50445e3e-d1a8-1269-0000-0000227b631b] failed to process session due to java.l

       

      Maybe should add | IllegalArgumentException at line https://github.com/apache/nifi/blob/master/nifi-nar-bundles/nifi-aws-bundle/nifi-aws-processors/src/main/java/org/apache/nifi/processors/aws/s3/FetchS3Object.java#L209

       

      Attachments

        1. 2020-08-11_17-21-52.png
          177 kB
          Gordeev Artem
        2. 2020-08-11_17-23-51.png
          38 kB
          Gordeev Artem

        Activity

          People

            kotarot Kotaro Terada
            gordeevart Gordeev Artem
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 3.5h
                3.5h