[ 
https://issues.apache.org/jira/browse/NIFI-7347?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17079951#comment-17079951
 ] 

Brandon Rhys DeVries commented on NIFI-7347:
--------------------------------------------

Update... ran more data through the flow, and did not get an NPE.  However, 
replicated the "data stuck / not moving" issue.  On further review, the files 
"stuck" going in to MergeRecord were all empty JSON arrays ("[]").  I think 
they're "stuck" because the bin has a min count of "1", but the sum of all the 
records in all these files is "0". 

 

I wonder if these empty files cause a problem with the "max number of bins" 
that led to the NPE, but I haven't had time to investigate further.

> NPE in MergeRecord
> ------------------
>
>                 Key: NIFI-7347
>                 URL: https://issues.apache.org/jira/browse/NIFI-7347
>             Project: Apache NiFi
>          Issue Type: Bug
>    Affects Versions: 1.9.0
>            Reporter: Brandon Rhys DeVries
>            Priority: Major
>
> Got an NPE in MergeRecord.  Even after a restart, the processor won't resume 
> processing data.  Even copies of the processor won't process data. 
>  
> Configuration:
> {code:java}
> Record Reader: JsonTreeReader
> Record Writer: AvroRecordSetWriter
> Merge Strategy: Bin-Packing Algorithm
> Correlation Attribute Name: No value set
> Attribute Strategy: Keep Only Common Attributes
> Minimum Number of Records: 10000
> Maximum Number of Records: 20000
> Minimum Bin Size: 0 B
> Maximum Bin Size: No value set
> Max Bin Age: 10 sec
> Maximum Number of Bins: 10 {code}
> Stack Trace:
> {code}
> MergeRecord[id=ef343265-5156-1564-92fa-8f74649fb548] 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:1161)
>       at 
> org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:213)
>       at 
> org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:117)
>       at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)
>       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
(v8.3.4#803005)

Reply via email to