[
https://issues.apache.org/jira/browse/NIFI-902?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14721788#comment-14721788
]
ASF subversion and git services commented on NIFI-902:
------------------------------------------------------
Commit a8b063d61b1646d595a8f4ea5a54ea7867292779 in nifi's branch
refs/heads/master from [~markap14]
[ https://git-wip-us.apache.org/repos/asf?p=nifi.git;h=a8b063d ]
NIFI-902: Ensure that we close the underlying file stream when we roll over a
partition instead of the bufferedoutputstream, which could cause corruption of
there was a failure to flush the entire buffer previously.
> NiFi does not properly handle error conditions if writing to FlowFile
> repository fails
> --------------------------------------------------------------------------------------
>
> Key: NIFI-902
> URL: https://issues.apache.org/jira/browse/NIFI-902
> Project: Apache NiFi
> Issue Type: Bug
> Components: Core Framework
> Reporter: Mark Payne
> Assignee: Mark Payne
> Priority: Critical
> Fix For: 0.3.0
>
> Attachments:
> 0001-NIFI-902-Ensure-that-if-we-get-an-IOException-during.patch,
> 0002-NIFI-902-Ensure-that-we-close-the-underlying-file-st.patch
>
>
> I ran out of disk space on my FlowFile Repository. After cleaning up some
> files on the partition, I was able to continue running but when the FlowFile
> Repo attempted to checkpoint, I got the following Exception in the logs:
> {noformat}
> 2015-08-27 15:59:58,398 ERROR [pool-20-thread-1]
> o.a.n.c.r.WriteAheadFlowFileRepository Unable to checkpoint FlowFile
> Repository due to java.io.IOException: Stream Closed
> java.io.IOException: Stream Closed
> at java.io.FileOutputStream.writeBytes(Native Method) ~[na:1.8.0_45]
> at java.io.FileOutputStream.write(FileOutputStream.java:326)
> ~[na:1.8.0_45]
> at
> org.apache.nifi.stream.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:69)
> ~[nifi-utils-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> org.apache.nifi.stream.io.BufferedOutputStream.flush(BufferedOutputStream.java:126)
> ~[nifi-utils-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at java.io.DataOutputStream.flush(DataOutputStream.java:123)
> ~[na:1.8.0_45]
> at java.io.FilterOutputStream.close(FilterOutputStream.java:158)
> ~[na:1.8.0_45]
> at
> org.wali.MinimalLockingWriteAheadLog$Partition.rollover(MinimalLockingWriteAheadLog.java:723)
> ~[nifi-write-ahead-log-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> org.wali.MinimalLockingWriteAheadLog.checkpoint(MinimalLockingWriteAheadLog.java:512)
> ~[nifi-write-ahead-log-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> org.apache.nifi.controller.repository.WriteAheadFlowFileRepository.checkpoint(WriteAheadFlowFileRepository.java:392)
> ~[nifi-framework-core-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> org.apache.nifi.controller.repository.WriteAheadFlowFileRepository$1.run(WriteAheadFlowFileRepository.java:364)
> ~[nifi-framework-core-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
> [na:1.8.0_45]
> at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
> [na:1.8.0_45]
> at
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
> [na:1.8.0_45]
> at
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
> [na:1.8.0_45]
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> [na:1.8.0_45]
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> [na:1.8.0_45]
> at java.lang.Thread.run(Thread.java:745) [na:1.8.0_45]
> Suppressed: java.io.IOException: Stream Closed
> at java.io.FileOutputStream.writeBytes(Native Method)
> ~[na:1.8.0_45]
> at java.io.FileOutputStream.write(FileOutputStream.java:326)
> ~[na:1.8.0_45]
> at
> org.apache.nifi.stream.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:69)
> ~[nifi-utils-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> org.apache.nifi.stream.io.BufferedOutputStream.flush(BufferedOutputStream.java:126)
> ~[nifi-utils-0.3.0-SNAPSHOT.jar:0.3.0-SNAPSHOT]
> at
> java.io.FilterOutputStream.close(FilterOutputStream.java:158) ~[na:1.8.0_45]
> at
> java.io.FilterOutputStream.close(FilterOutputStream.java:159) ~[na:1.8.0_45]
> ... 11 common frames omitted
> {noformat}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)