You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Bryan Bende (JIRA)" <ji...@apache.org> on 2019/02/15 16:41:00 UTC

[jira] [Created] (NIFI-6041) MergeRecord can NPE if all flow files have 0 records

Bryan Bende created NIFI-6041:
---------------------------------

             Summary: MergeRecord can NPE if all flow files have 0 records
                 Key: NIFI-6041
                 URL: https://issues.apache.org/jira/browse/NIFI-6041
             Project: Apache NiFi
          Issue Type: Bug
    Affects Versions: 1.9.0
            Reporter: Bryan Bende


If you create a MergeRecord processor with a Max Bin Age set, and then send in a bunch of flow files that all have no records, then eventually it will attempt to complete a bin based on the bin age, but will NPE because the record writer was never initialized...
{code:java}
2019-02-15 10:25:51,939 ERROR [Timer-Driven Process Thread-4] o.a.nifi.processors.standard.MergeRecord MergeRecord[id=f1ae2102-0168-1000-fdf0-55ae047ea383] Failed to merge FlowFiles to create new bin due to java.lang.NullPointerException: java.lang.NullPointerException
java.lang.NullPointerException: null
    at org.apache.nifi.processors.standard.merge.RecordBin.complete(RecordBin.java:340)
    at org.apache.nifi.processors.standard.merge.RecordBinManager.handleCompletedBins(RecordBinManager.java:272)
    at org.apache.nifi.processors.standard.merge.RecordBinManager.completeExpiredBins(RecordBinManager.java:238)
    at org.apache.nifi.processors.standard.MergeRecord.onTrigger(MergeRecord.java:350)
    at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1162)
    at org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:205)
    at org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:117)
    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){code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)