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

UnpackContent throws "java.lang.IllegalArgumentException: invalid entry size" and Administratively Yields

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.4.0, 1.5.0
    • 1.7.0
    • None
    • None

    Description

      When using the UnpackContent processor we sometimes receive the error "java.lang.IllegalArgumentException: invalid entry size". Instead of the flow file being routed to the failure relationship, the session is rolled back, the flow file is penalized, and the framework "Administratively Yields". This is causing our flow to back up. We would expect the malformed zip to be routed to the failure relationship, not tried again. We received this exception in both NiFi 1.4.0 and 1.5.0. 

      This is our exception stack trace:

      java.lang.IllegalArgumentException: invalid entry size
      at org.apache.commons.compress.archivers.zip.ZipArchiveEntry.setSize(ZipArchiveEntry.java:679)
      at org.apache.commons.compress.archivers.zip.ZipArchiveInputStream.readDataDescriptor(ZipArchiveInputStream.java:764)
      at org.apache.commons.compress.archivers.zip.ZipArchiveInputStream.closeEntry(ZipArchiveInputStream.java:651)
      at org.apache.commons.compress.archivers.zip.ZipArchiveInputStream.getNextZipEntry(ZipArchiveInputStream.java:225)
      at org.apache.commons.compress.archivers.zip.ZipArchiveInputStream.getNextEntry(ZipArchiveInputStream.java:378)
      at org.apache.nifi.processors.standard.UnpackContent$ZipUnpacker$1.process(UnpackContent.java:362)
      at org.apache.nifi.controller.repository.StandardProcessSession.read(StandardProcessSession.java:2175)
      at org.apache.nifi.controller.repository.StandardProcessSession.read(StandardProcessSession.java:2145)
      at org.apache.nifi.processors.standard.UnpackContent$ZipUnpacker.unpack(UnpackContent.java:356)
      at org.apache.nifi.processors.standard.UnpackContent.onTrigger(UnpackContent.java:255)
      at org.apache.nifi.processor.AbstractProcessor.onTrigger(AbstractProcessor.java:27)
      at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1122)
      at org.apache.nifi.controller.tasks.ContinuallyRunProcessorTask.call(ContinuallyRunProcessorTask.java:147)
      at org.apache.nifi.controller.tasks.ContinuallyRunProcessorTask.call(ContinuallyRunProcessorTask.java:47)
      at org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:128)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
      at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at java.lang.Thread.run(Thread.java:748)

      Attachments

        1. UnpackContent-NIFI-4988.xml
          15 kB
          Andrew Psaltis
        2. 1474113567697855.zip
          1.0 kB
          Andrew Psaltis
        3. 1474061523922903.zip
          6 kB
          Andrew Psaltis

        Issue Links

          Activity

            People

              apsaltis Andrew Psaltis
              wvilwock William Vilwock
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: