Repository: incubator-nifi
Updated Branches:
  refs/heads/develop 4a1684530 -> 3a2b12d7c


NIFI-486: Fixed NPE that occurs if processor allows for controller service as 
optional property and no value set

Signed-off-by: joewitt <[email protected]>


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

Branch: refs/heads/develop
Commit: 3a2b12d7c9919c8f3be2a01125ad60ca22fecc03
Parents: 4a16845
Author: Mark Payne <[email protected]>
Authored: Mon Apr 6 17:59:07 2015 -0400
Committer: joewitt <[email protected]>
Committed: Mon Apr 6 21:13:30 2015 -0400

----------------------------------------------------------------------
 .../nifi/controller/scheduling/StandardProcessScheduler.java     | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/3a2b12d7/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/scheduling/StandardProcessScheduler.java
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/scheduling/StandardProcessScheduler.java
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/scheduling/StandardProcessScheduler.java
index 89850cc..43e05dd 100644
--- 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/scheduling/StandardProcessScheduler.java
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/scheduling/StandardProcessScheduler.java
@@ -297,7 +297,9 @@ public final class StandardProcessScheduler implements 
ProcessScheduler {
                         final Class<? extends ControllerService> 
serviceDefinition = descriptor.getControllerServiceDefinition();
                         if ( serviceDefinition != null ) {
                             final String serviceId = 
processContext.getProperty(descriptor).getValue();
-                            serviceIds.add(serviceId);
+                            if ( serviceId != null ) {
+                               serviceIds.add(serviceId);
+                            }
                         }
                     }
                     

Reply via email to