From edce66d34f711e667225903b5c9adace502ba135 Mon Sep 17 00:00:00 2001 From: Matt Gilman Date: Thu, 16 Jun 2016 20:17:16 -0400 Subject: [PATCH] NIFI-1941: - Ensuring descendent components are scheduled/unscheduled according to their respective ProcessGroups. --- .../nifi/web/dao/impl/StandardProcessGroupDAO.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/dao/impl/StandardProcessGroupDAO.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/dao/impl/StandardProcessGroupDAO.java index 3494f93ccd..8f528965c6 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/dao/impl/StandardProcessGroupDAO.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/dao/impl/StandardProcessGroupDAO.java @@ -106,19 +106,19 @@ public class StandardProcessGroupDAO extends ComponentDAO implements ProcessGrou final Connectable connectable = group.findConnectable(componentId); if (ScheduledState.RUNNING.equals(state)) { if (ConnectableType.PROCESSOR.equals(connectable.getConnectableType())) { - group.startProcessor((ProcessorNode) connectable); + connectable.getProcessGroup().startProcessor((ProcessorNode) connectable); } else if (ConnectableType.INPUT_PORT.equals(connectable.getConnectableType())) { - group.startInputPort((Port) connectable); + connectable.getProcessGroup().startInputPort((Port) connectable); } else if (ConnectableType.OUTPUT_PORT.equals(connectable.getConnectableType())) { - group.startOutputPort((Port) connectable); + connectable.getProcessGroup().startOutputPort((Port) connectable); } } else { if (ConnectableType.PROCESSOR.equals(connectable.getConnectableType())) { - group.stopProcessor((ProcessorNode) connectable); + connectable.getProcessGroup().stopProcessor((ProcessorNode) connectable); } else if (ConnectableType.INPUT_PORT.equals(connectable.getConnectableType())) { - group.stopInputPort((Port) connectable); + connectable.getProcessGroup().stopInputPort((Port) connectable); } else if (ConnectableType.OUTPUT_PORT.equals(connectable.getConnectableType())) { - group.stopOutputPort((Port) connectable); + connectable.getProcessGroup().stopOutputPort((Port) connectable); } } }