Repository: nifi
Updated Branches:
  refs/heads/master 4d21f9b34 -> 51ed618cf


NIFI-5708 Fixing the creation of ValidationContextFactory for controller 
services so it uses the ComponentVariableRegistry and not the file-based 
instance

Signed-off-by: Matthew Burgess <[email protected]>

This closes #3081


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

Branch: refs/heads/master
Commit: 51ed618cf02b56fcb1683f6e4f6069a70e8e5ca6
Parents: 4d21f9b
Author: Bryan Bende <[email protected]>
Authored: Tue Oct 16 13:58:48 2018 -0400
Committer: Matthew Burgess <[email protected]>
Committed: Tue Oct 16 15:38:32 2018 -0400

----------------------------------------------------------------------
 .../controller/service/StandardControllerServiceProvider.java     | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/nifi/blob/51ed618c/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/service/StandardControllerServiceProvider.java
----------------------------------------------------------------------
diff --git 
a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/service/StandardControllerServiceProvider.java
 
b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/service/StandardControllerServiceProvider.java
index 3e212c0..1762068 100644
--- 
a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/service/StandardControllerServiceProvider.java
+++ 
b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/service/StandardControllerServiceProvider.java
@@ -157,12 +157,13 @@ public class StandardControllerServiceProvider implements 
ControllerServiceProvi
 
             originalService.initialize(new 
StandardControllerServiceInitializationContext(id, terminationAwareLogger, 
this, getStateManager(id), nifiProperties));
 
-            final ValidationContextFactory validationContextFactory = new 
StandardValidationContextFactory(this, variableRegistry);
+
 
             final LoggableComponent<ControllerService> 
originalLoggableComponent = new LoggableComponent<>(originalService, 
bundleCoordinate, terminationAwareLogger);
             final LoggableComponent<ControllerService> 
proxiedLoggableComponent = new LoggableComponent<>(proxiedService, 
bundleCoordinate, terminationAwareLogger);
 
             final ComponentVariableRegistry componentVarRegistry = new 
StandardComponentVariableRegistry(this.variableRegistry);
+            final ValidationContextFactory validationContextFactory = new 
StandardValidationContextFactory(this, componentVarRegistry);
             final ControllerServiceNode serviceNode = new 
StandardControllerServiceNode(originalLoggableComponent, 
proxiedLoggableComponent, invocationHandler,
                 id, validationContextFactory, this, componentVarRegistry, 
flowController, validationTrigger);
             serviceNode.setName(rawClass.getSimpleName());

Reply via email to