NIFI-129: Fixed bug that caused root group port's isTransmitting to return 
false, even when there is data being transferred


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

Branch: refs/heads/NIFI-632
Commit: e50b20c4ce513046b692154e370b0b1f87e21e0a
Parents: 66365b0
Author: Mark Payne <marka...@hotmail.com>
Authored: Thu Jun 18 08:26:49 2015 -0400
Committer: Mark Payne <marka...@hotmail.com>
Committed: Thu Jun 18 09:03:54 2015 -0400

----------------------------------------------------------------------
 .../java/org/apache/nifi/remote/StandardRootGroupPort.java   | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/e50b20c4/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-site-to-site/src/main/java/org/apache/nifi/remote/StandardRootGroupPort.java
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-site-to-site/src/main/java/org/apache/nifi/remote/StandardRootGroupPort.java
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-site-to-site/src/main/java/org/apache/nifi/remote/StandardRootGroupPort.java
index 67f28d2..4bb1683 100644
--- 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-site-to-site/src/main/java/org/apache/nifi/remote/StandardRootGroupPort.java
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-site-to-site/src/main/java/org/apache/nifi/remote/StandardRootGroupPort.java
@@ -252,7 +252,7 @@ public class StandardRootGroupPort extends AbstractPort 
implements RootGroupPort
 
     @Override
     public boolean isValid() {
-        return (getConnectableType() == ConnectableType.INPUT_PORT) ? 
!getConnections(Relationship.ANONYMOUS).isEmpty() : true;
+        return getConnectableType() == ConnectableType.INPUT_PORT ? 
!getConnections(Relationship.ANONYMOUS).isEmpty() : true;
     }
 
     @Override
@@ -275,14 +275,10 @@ public class StandardRootGroupPort extends AbstractPort 
implements RootGroupPort
             return false;
         }
 
-        if (processScheduler.getActiveThreadCount(this) > 0) {
+        if (!requestQueue.isEmpty()) {
             return true;
         }
 
-        if (requestQueue.isEmpty()) {
-            return false;
-        }
-
         requestLock.lock();
         try {
             return !activeRequests.isEmpty();

Reply via email to