Github user olegz commented on a diff in the pull request: https://github.com/apache/nifi/pull/1652#discussion_r110541076 --- Diff: nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/repository/StandardProcessSession.java --- @@ -2201,7 +2202,10 @@ public int read(final byte[] b, final int off, final int len) throws IOException @Override public void close() throws IOException { - StandardProcessSession.this.bytesRead += countingStream.getBytesRead(); + if (!closed) { + StandardProcessSession.this.bytesRead += countingStream.getBytesRead(); + closed = true; + } --- End diff -- Technically the above is not thread safe, consider adding some synchronization.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---