You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nifi.apache.org by ma...@apache.org on 2015/01/06 16:17:32 UTC

[3/7] incubator-nifi git commit: NIFI-226: when pre-fetching FlowFiles from queue, if a FlowFile is penalized, it is lost

NIFI-226: when pre-fetching FlowFiles from queue, if a FlowFile is penalized, it is lost


Project: http://git-wip-us.apache.org/repos/asf/incubator-nifi/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-nifi/commit/a2ecfe33
Tree: http://git-wip-us.apache.org/repos/asf/incubator-nifi/tree/a2ecfe33
Diff: http://git-wip-us.apache.org/repos/asf/incubator-nifi/diff/a2ecfe33

Branch: refs/heads/develop
Commit: a2ecfe3355f1ac75285e42d3f34bb9761723cc5b
Parents: 68b7ad7
Author: Mark Payne <ma...@hotmail.com>
Authored: Mon Jan 5 15:36:40 2015 -0500
Committer: Mark Payne <ma...@hotmail.com>
Committed: Mon Jan 5 15:36:40 2015 -0500

----------------------------------------------------------------------
 .../java/org/apache/nifi/controller/StandardFlowFileQueue.java    | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/a2ecfe33/nar-bundles/framework-bundle/framework/core-api/src/main/java/org/apache/nifi/controller/StandardFlowFileQueue.java
----------------------------------------------------------------------
diff --git a/nar-bundles/framework-bundle/framework/core-api/src/main/java/org/apache/nifi/controller/StandardFlowFileQueue.java b/nar-bundles/framework-bundle/framework/core-api/src/main/java/org/apache/nifi/controller/StandardFlowFileQueue.java
index 3b880bb..59d2308 100644
--- a/nar-bundles/framework-bundle/framework/core-api/src/main/java/org/apache/nifi/controller/StandardFlowFileQueue.java
+++ b/nar-bundles/framework-bundle/framework/core-api/src/main/java/org/apache/nifi/controller/StandardFlowFileQueue.java
@@ -1011,6 +1011,9 @@ public final class StandardFlowFileQueue implements FlowFileQueue {
             if (record == null || record.isPenalized()) {
                 // not enough unpenalized records to pull. Put all records back and return
                 activeQueue.addAll(buffer);
+                if ( record != null ) {
+                    activeQueue.add(record);
+                }
                 return;
             } else {
                 buffer.add(record);