You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nifi.apache.org by mc...@apache.org on 2015/03/26 16:56:25 UTC

incubator-nifi git commit: NIFI-250: - Using the correct state variable when determining how to update a given controller service.

Repository: incubator-nifi
Updated Branches:
  refs/heads/NIFI-250 6c678bfe6 -> 5b56982d2


NIFI-250:
- Using the correct state variable when determining how to update a given controller service.

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

Branch: refs/heads/NIFI-250
Commit: 5b56982d20b3a24ca59362a482c39ef6d4329b8d
Parents: 6c678bf
Author: Matt Gilman <ma...@gmail.com>
Authored: Thu Mar 26 11:55:56 2015 -0400
Committer: Matt Gilman <ma...@gmail.com>
Committed: Thu Mar 26 11:55:56 2015 -0400

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


http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/5b56982d/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/StandardFlowSynchronizer.java
----------------------------------------------------------------------
diff --git a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/StandardFlowSynchronizer.java b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/StandardFlowSynchronizer.java
index 91e7c86..243f7c5 100644
--- a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/StandardFlowSynchronizer.java
+++ b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/StandardFlowSynchronizer.java
@@ -358,12 +358,12 @@ public class StandardFlowSynchronizer implements FlowSynchronizer {
     private void updateControllerService(final FlowController controller, final Element controllerServiceElement, final StringEncryptor encryptor) {
     	final ControllerServiceDTO dto = FlowFromDOMFactory.getControllerService(controllerServiceElement, encryptor);
     	
-    	final ControllerServiceState state = ControllerServiceState.valueOf(dto.getState());
-        final boolean dtoEnabled = (state == ControllerServiceState.ENABLED || state == ControllerServiceState.ENABLING);
+    	final ControllerServiceState dtoState = ControllerServiceState.valueOf(dto.getState());
+        final boolean dtoEnabled = (dtoState == ControllerServiceState.ENABLED || dtoState == ControllerServiceState.ENABLING);
         
         final ControllerServiceNode serviceNode = controller.getControllerServiceNode(dto.getId());
         final ControllerServiceState serviceState = serviceNode.getState();
-        final boolean serviceEnabled = (serviceState == ControllerServiceState.ENABLED || state == ControllerServiceState.ENABLING);
+        final boolean serviceEnabled = (serviceState == ControllerServiceState.ENABLED || serviceState == ControllerServiceState.ENABLING);
         
     	if (dtoEnabled && !serviceEnabled) {
     		controller.enableControllerService(controller.getControllerServiceNode(dto.getId()));