diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/cds/AbstractCDSProcessingBBUtils.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/cds/AbstractCDSProcessingBBUtils.java
index 9741d4b..424a4f3 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/cds/AbstractCDSProcessingBBUtils.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/cds/AbstractCDSProcessingBBUtils.java
@@ -68,7 +68,7 @@
     private static final String EXCEPTION = "Exception";
 
     @Autowired
-    private ExceptionBuilder exceptionUtil;
+    protected ExceptionBuilder exceptionUtil;
 
     /**
      * Extracting data from execution object and building the ExecutionServiceInput Object
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/ActivitySpec/GenericControllerExecution.json b/bpmn/so-bpmn-building-blocks/src/main/resources/ActivitySpec/GenericControllerExecution.json
new file mode 100644
index 0000000..d4a0e83
--- /dev/null
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/ActivitySpec/GenericControllerExecution.json
@@ -0,0 +1,15 @@
+{
+  "name": "GenericControllerExecution",
+  "description": "Generic controller execution with BuildingBlockExecution context against controller northbound interface",
+  "categoryList": [
+    "VNF",
+    "PNF"
+  ],
+  "inputParameters": [],
+  "outputParameters": [
+    {
+      "name": "WorkflowException",
+      "type": "WorkflowException"
+    }
+  ]
+}
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/ActivitySpec/GenericControllerExecutionDE.json b/bpmn/so-bpmn-building-blocks/src/main/resources/ActivitySpec/GenericControllerExecutionDE.json
new file mode 100644
index 0000000..cd1fa86
--- /dev/null
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/ActivitySpec/GenericControllerExecutionDE.json
@@ -0,0 +1,15 @@
+{
+  "name": "GenericControllerExecutionDE",
+  "description": "Generic controller execution with DelegateExecution context against controller northbound interface",
+  "categoryList": [
+    "VNF",
+    "PNF"
+  ],
+  "inputParameters": [],
+  "outputParameters": [
+    {
+      "name": "WorkflowException",
+      "type": "WorkflowException"
+    }
+  ]
+}
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/Activity/GenericControllerExecution.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/Activity/GenericControllerExecution.bpmn
new file mode 100644
index 0000000..bd60673
--- /dev/null
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/Activity/GenericControllerExecution.bpmn
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_0ky0lyw" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="2.2.4">
+  <bpmn:process id="GenericControllerExecution" name="GenericControllerExecution" isExecutable="true">
+    <bpmn:startEvent id="Start_ControllerExecutionBB" name="Start">
+      <bpmn:outgoing>SequenceFlow_06ab7wm</bpmn:outgoing>
+    </bpmn:startEvent>
+    <bpmn:sequenceFlow id="SequenceFlow_06ab7wm" sourceRef="Start_ControllerExecutionBB" targetRef="Call_ControllerExecutionBB" />
+    <bpmn:endEvent id="End_ControllerExecutionBB" name="End">
+      <bpmn:incoming>SequenceFlow_12srn62</bpmn:incoming>
+    </bpmn:endEvent>
+    <bpmn:sequenceFlow id="SequenceFlow_12srn62" sourceRef="Call_ControllerExecutionBB" targetRef="End_ControllerExecutionBB" />
+    <bpmn:serviceTask id="Call_ControllerExecutionBB" name="Call ControllerExecutionBB&#10;" camunda:expression="${ControllerExecutionBB.execute(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
+      <bpmn:incoming>SequenceFlow_06ab7wm</bpmn:incoming>
+      <bpmn:outgoing>SequenceFlow_12srn62</bpmn:outgoing>
+    </bpmn:serviceTask>
+  </bpmn:process>
+  <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+    <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="GenericControllerExecution">
+      <bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="Start_ControllerExecutionBB">
+        <dc:Bounds x="173" y="102" width="36" height="36" />
+        <bpmndi:BPMNLabel>
+          <dc:Bounds x="180" y="145" width="24" height="14" />
+        </bpmndi:BPMNLabel>
+      </bpmndi:BPMNShape>
+      <bpmndi:BPMNEdge id="SequenceFlow_06ab7wm_di" bpmnElement="SequenceFlow_06ab7wm">
+        <di:waypoint x="209" y="120" />
+        <di:waypoint x="291" y="120" />
+      </bpmndi:BPMNEdge>
+      <bpmndi:BPMNShape id="EndEvent_07e01q3_di" bpmnElement="End_ControllerExecutionBB">
+        <dc:Bounds x="554" y="102" width="36" height="36" />
+        <bpmndi:BPMNLabel>
+          <dc:Bounds x="562" y="145" width="20" height="14" />
+        </bpmndi:BPMNLabel>
+      </bpmndi:BPMNShape>
+      <bpmndi:BPMNEdge id="SequenceFlow_12srn62_di" bpmnElement="SequenceFlow_12srn62">
+        <di:waypoint x="391" y="120" />
+        <di:waypoint x="554" y="120" />
+      </bpmndi:BPMNEdge>
+      <bpmndi:BPMNShape id="ServiceTask_0d1v1dn_di" bpmnElement="Call_ControllerExecutionBB">
+        <dc:Bounds x="291" y="80" width="100" height="80" />
+      </bpmndi:BPMNShape>
+    </bpmndi:BPMNPlane>
+  </bpmndi:BPMNDiagram>
+</bpmn:definitions>
\ No newline at end of file
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/Activity/GenericControllerExecutionDE.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/Activity/GenericControllerExecutionDE.bpmn
new file mode 100644
index 0000000..b5dcec0
--- /dev/null
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/Activity/GenericControllerExecutionDE.bpmn
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_0ky0lyw" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="2.2.4">
+  <bpmn:process id="GenericControllerExecutionDE" name="GenericControllerExecutionDE" isExecutable="true">
+    <bpmn:startEvent id="Start_ControllerExecutionDE" name="Start">
+      <bpmn:outgoing>SequenceFlow_06ab7wm</bpmn:outgoing>
+    </bpmn:startEvent>
+    <bpmn:sequenceFlow id="SequenceFlow_06ab7wm" sourceRef="Start_ControllerExecutionDE" targetRef="Call_ControllerExecutionDE" />
+    <bpmn:endEvent id="End_ControllerExecutionDE" name="End">
+      <bpmn:incoming>SequenceFlow_12srn62</bpmn:incoming>
+    </bpmn:endEvent>
+    <bpmn:sequenceFlow id="SequenceFlow_12srn62" sourceRef="Call_ControllerExecutionDE" targetRef="End_ControllerExecutionDE" />
+    <bpmn:serviceTask id="Call_ControllerExecutionDE" name="Call ControllerExecutionDE&#10;" camunda:delegateExpression="${ControllerExecutionDE}">
+      <bpmn:incoming>SequenceFlow_06ab7wm</bpmn:incoming>
+      <bpmn:outgoing>SequenceFlow_12srn62</bpmn:outgoing>
+    </bpmn:serviceTask>
+  </bpmn:process>
+  <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+    <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="GenericControllerExecutionDE">
+      <bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="Start_ControllerExecutionDE">
+        <dc:Bounds x="173" y="102" width="36" height="36" />
+        <bpmndi:BPMNLabel>
+          <dc:Bounds x="180" y="145" width="24" height="14" />
+        </bpmndi:BPMNLabel>
+      </bpmndi:BPMNShape>
+      <bpmndi:BPMNEdge id="SequenceFlow_06ab7wm_di" bpmnElement="SequenceFlow_06ab7wm">
+        <di:waypoint x="209" y="120" />
+        <di:waypoint x="291" y="120" />
+      </bpmndi:BPMNEdge>
+      <bpmndi:BPMNShape id="EndEvent_07e01q3_di" bpmnElement="End_ControllerExecutionDE">
+        <dc:Bounds x="554" y="102" width="36" height="36" />
+        <bpmndi:BPMNLabel>
+          <dc:Bounds x="562" y="145" width="20" height="14" />
+        </bpmndi:BPMNLabel>
+      </bpmndi:BPMNShape>
+      <bpmndi:BPMNEdge id="SequenceFlow_12srn62_di" bpmnElement="SequenceFlow_12srn62">
+        <di:waypoint x="391" y="120" />
+        <di:waypoint x="554" y="120" />
+      </bpmndi:BPMNEdge>
+      <bpmndi:BPMNShape id="ServiceTask_0d1v1dn_di" bpmnElement="Call_ControllerExecutionDE">
+        <dc:Bounds x="291" y="80" width="100" height="80" />
+      </bpmndi:BPMNShape>
+    </bpmndi:BPMNPlane>
+  </bpmndi:BPMNDiagram>
+</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/BaseBPMNTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/BaseBPMNTest.java
index 5b7fe66..874e341 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/BaseBPMNTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/BaseBPMNTest.java
@@ -55,6 +55,8 @@
 import org.onap.so.bpmn.infrastructure.appc.tasks.AppcOrchestratorPreProcessor;
 import org.onap.so.bpmn.infrastructure.appc.tasks.AppcRunTasks;
 import org.onap.so.bpmn.infrastructure.audit.AuditTasks;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.ControllerExecutionBB;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.ControllerExecutionDE;
 import org.onap.so.bpmn.infrastructure.flowspecific.tasks.ActivateVfModule;
 import org.onap.so.bpmn.infrastructure.flowspecific.tasks.AssignNetwork;
 import org.onap.so.bpmn.infrastructure.flowspecific.tasks.AssignNetworkBBUtils;
@@ -254,6 +256,12 @@
     @MockBean
     protected ManualHandlingTasks manualHandlingTasks;
 
+    @MockBean
+    protected ControllerExecutionBB controllerExecutionBB;
+
+    @MockBean
+    protected ControllerExecutionDE controllerExecutionDE;
+
     @LocalServerPort
     protected int port;
 
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/GenericControllerExecutionDETest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/GenericControllerExecutionDETest.java
new file mode 100644
index 0000000..83cf98e
--- /dev/null
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/GenericControllerExecutionDETest.java
@@ -0,0 +1,54 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.bpmn.subprocess;
+
+import static org.camunda.bpm.engine.test.assertions.ProcessEngineTests.assertThat;
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.Mockito.doThrow;
+import org.camunda.bpm.engine.delegate.BpmnError;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.camunda.bpm.engine.runtime.ProcessInstance;
+import org.junit.Test;
+import org.onap.so.bpmn.BaseBPMNTest;
+
+
+public class GenericControllerExecutionDETest extends BaseBPMNTest {
+
+    @Test
+    public void testExecution_validInput_expectedExecution() {
+
+        ProcessInstance pi = runtimeService.startProcessInstanceByKey("GenericControllerExecutionDE", variables);
+        assertThat(pi).isNotNull();
+        assertThat(pi).isStarted().hasPassedInOrder("Start_ControllerExecutionDE", "Call_ControllerExecutionDE",
+                "End_ControllerExecutionDE");
+        assertThat(pi).isEnded();
+    }
+
+    @Test
+    public void testExecution_failedExecution_exceptionThrown() {
+        doThrow(new BpmnError("7000", "TESTING ERRORS")).when(controllerExecutionDE)
+                .execute(any(DelegateExecution.class));
+        ProcessInstance pi = runtimeService.startProcessInstanceByKey("GenericControllerExecutionDE", variables);
+        assertThat(pi).isNotNull();
+        assertThat(pi).isStarted().hasPassedInOrder("Start_ControllerExecutionDE", "Call_ControllerExecutionDE")
+                .hasNotPassed("End_ControllerExecutionDE");
+        assertThat(pi).isEnded();
+    }
+}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/GenericControllerExecutionTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/GenericControllerExecutionTest.java
new file mode 100644
index 0000000..c2aa3af
--- /dev/null
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/GenericControllerExecutionTest.java
@@ -0,0 +1,54 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.bpmn.subprocess;
+
+import static org.camunda.bpm.engine.test.assertions.ProcessEngineTests.assertThat;
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.Mockito.doThrow;
+import org.camunda.bpm.engine.delegate.BpmnError;
+import org.camunda.bpm.engine.runtime.ProcessInstance;
+import org.junit.Test;
+import org.onap.so.bpmn.BaseBPMNTest;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+
+
+public class GenericControllerExecutionTest extends BaseBPMNTest {
+
+    @Test
+    public void testExecution_validInput_expectedExecution() {
+
+        ProcessInstance pi = runtimeService.startProcessInstanceByKey("GenericControllerExecution", variables);
+        assertThat(pi).isNotNull();
+        assertThat(pi).isStarted().hasPassedInOrder("Start_ControllerExecutionBB", "Call_ControllerExecutionBB",
+                "End_ControllerExecutionBB");
+        assertThat(pi).isEnded();
+    }
+
+    @Test
+    public void testExecution_failedExecution_exceptionThrown() {
+        doThrow(new BpmnError("7000", "TESTING ERRORS")).when(controllerExecutionBB)
+                .execute(any(BuildingBlockExecution.class));
+        ProcessInstance pi = runtimeService.startProcessInstanceByKey("GenericControllerExecution", variables);
+        assertThat(pi).isNotNull();
+        assertThat(pi).isStarted().hasPassedInOrder("Start_ControllerExecutionBB", "Call_ControllerExecutionBB")
+                .hasNotPassed("End_ControllerExecutionBB");
+        assertThat(pi).isEnded();
+    }
+}
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/ControllerContext.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/ControllerContext.java
new file mode 100644
index 0000000..0de211b
--- /dev/null
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/ControllerContext.java
@@ -0,0 +1,95 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+package org.onap.so.bpmn.infrastructure.decisionpoint.api;
+
+import java.util.Map;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+
+/**
+ * This class is used to represent the Context used by {@ref ControllerRunnable}.
+ */
+public class ControllerContext<T> {
+
+    /**
+     * Action to be executed against controller.
+     *
+     * e.g, healthcheck, scaleout, config-assign
+     *
+     * Action is case insensitive.
+     */
+    private String controllerAction;
+
+    /**
+     * Controller actor.
+     *
+     * e.g., CDS, SDNC, APPC.
+     *
+     * actor name is case insensitive.
+     */
+    private String controllerActor;
+
+    /**
+     * scope: PNF, VNF, VF.
+     */
+    private String controllerScope;
+
+    /**
+     * Execution context, buildingblockExecution or DelegateExecution.
+     */
+    private T execution;
+
+    public ControllerContext() {}
+
+    public void setExecution(T execution) {
+        this.execution = execution;
+    }
+
+    public T getExecution() {
+        return execution;
+    }
+
+    public String getControllerAction() {
+        return controllerAction;
+    }
+
+    public void setControllerAction(String controllerAction) {
+        this.controllerAction = controllerAction;
+    }
+
+    public String getControllerActor() {
+        return controllerActor;
+    }
+
+    public void setControllerActor(String controllerActor) {
+        this.controllerActor = controllerActor;
+    }
+
+    public String getControllerScope() {
+        return controllerScope;
+    }
+
+    public void setControllerScope(String controllerScope) {
+        this.controllerScope = controllerScope;
+    }
+
+    public String toString() {
+        return "Controller context for actor: " + controllerActor + ", action: " + controllerAction + ",scope: "
+                + controllerScope;
+    }
+}
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/ControllerRunnable.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/ControllerRunnable.java
new file mode 100644
index 0000000..670f4d3
--- /dev/null
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/ControllerRunnable.java
@@ -0,0 +1,56 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+package org.onap.so.bpmn.infrastructure.decisionpoint.api;
+
+/**
+ * the ControllerRunnable interface should be implemented by any class intended to execute against controller northbound
+ * interface.
+ *
+ */
+public interface ControllerRunnable<T> {
+
+    /**
+     * This method is used to decide whether the implementation is to serve the controller northbound interface.
+     *
+     * @param context {@link ControllerContext} is used as the input to the execution.
+     * @return
+     */
+    Boolean understand(final ControllerContext<T> context);
+
+    /**
+     * this method is used to check whether the controller Northbound interface is ready to use.
+     *
+     * @param context {@link ControllerContext} is used as the input to the execution.
+     * @return True if the controller is ready to use or return false.
+     */
+    Boolean ready(final ControllerContext<T> context);
+
+    /**
+     * This method is used to set up the context so it can be used to run against the controller NB.
+     */
+    void prepare(final ControllerContext<T> context);
+
+    /**
+     * This method is used to run against the controller northbound interface.
+     *
+     * @param context {@link ControllerContext} is used as the input to the execution.
+     */
+    void run(final ControllerContext<T> context);
+
+}
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/controller/ControllerPreparable.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/controller/ControllerPreparable.java
new file mode 100644
index 0000000..98bab2c
--- /dev/null
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/api/controller/ControllerPreparable.java
@@ -0,0 +1,48 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.api.controller;
+
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+
+/**
+ * This interface is used by {@link ControllerRunnable} to prepare the Context.
+ *
+ * The interface should be implementation by controller preparation instance to configure the context required for
+ * execution.
+ */
+public interface ControllerPreparable<T> {
+
+    /**
+     * This method is used to decide whether the implementation is used to configure the {@link ControllerContext}.
+     *
+     * @param controllerContext
+     * @return
+     */
+    boolean understand(final ControllerContext<T> controllerContext);
+
+    /**
+     * This method is used to prepare the {@link ControllerContext}.
+     *
+     * @param controllerContext
+     */
+    void prepare(final ControllerContext<T> controllerContext);
+
+}
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ConfigCheckerDelegate.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ConfigCheckerDelegate.java
index ee86ca4..37b9376 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ConfigCheckerDelegate.java
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ConfigCheckerDelegate.java
@@ -1,15 +1,20 @@
-/*
- * ============LICENSE_START======================================================= Copyright (C) 2019 Nordix
- * Foundation. ================================================================================ Licensed under the
- * Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may
- * obtain a copy of the License at
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
  *
- * http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
- * either express or implied. See the License for the specific language governing permissions and limitations under the
- * License.
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
  *
- * SPDX-License-Identifier: Apache-2.0 ============LICENSE_END=========================================================
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
  */
 
 package org.onap.so.bpmn.infrastructure.pnf.delegate;
@@ -17,6 +22,7 @@
 import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.MODEL_UUID;
 import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_BLUEPRINT_NAME;
 import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_BLUEPRINT_VERSION;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_CONTROLLER_ACTOR;
 import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_CUSTOMIZATION_UUID;
 import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_INSTANCE_NAME;
 import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.SERVICE_MODEL_INFO;
@@ -75,6 +81,7 @@
                 delegateExecution.setVariable(PRC_CUSTOMIZATION_UUID,
                         pnfResourceCustomization.getModelCustomizationUUID());
                 delegateExecution.setVariable(PRC_INSTANCE_NAME, pnfResourceCustomization.getModelInstanceName());
+                delegateExecution.setVariable(PRC_CONTROLLER_ACTOR, pnfResourceCustomization.getControllerActor());
             } else {
                 logger.warn("Unable to find the PNF resource customizations of model service UUID: {}",
                         serviceModelUuid);
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ExecutionVariableNames.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ExecutionVariableNames.java
index c16175b..fab3496 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ExecutionVariableNames.java
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/ExecutionVariableNames.java
@@ -5,6 +5,7 @@
  * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
  * ================================================================================
  * Modifications Copyright 2018 Nokia
+ * Modifications Copyright 2019 Nordix
  * ================================================================================
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -51,6 +52,8 @@
     public static final String PRC_BLUEPRINT_VERSION = "PRC_blueprintVersion";
     public static final String PRC_CUSTOMIZATION_UUID = "PRC_customizationUuid";
     public static final String PRC_INSTANCE_NAME = "PRC_instanceName";
+    public static final String PRC_CONTROLLER_ACTOR = "actor";
+
 
     /**
      * Variable used to contain skipPostInstantiationConfiguration flag.
diff --git a/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/ConfigurePnfResource.bpmn b/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/ConfigurePnfResource.bpmn
index 9a1a7ed..6d5b2a2 100644
--- a/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/ConfigurePnfResource.bpmn
+++ b/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/ConfigurePnfResource.bpmn
@@ -16,45 +16,19 @@
     <bpmn:sequenceFlow id="SequenceFlow_157of54" name="true" sourceRef="ExclusiveGateway_079gavg" targetRef="EndEvent_0xky46v">
       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{SkipPostInstantiationConfiguration}</bpmn:conditionExpression>
     </bpmn:sequenceFlow>
-    <bpmn:serviceTask id="Task_0k2q5vd" name="Prepare Config Assign" camunda:delegateExpression="${PrepareConfigAssignDelegate}">
-      <bpmn:incoming>SequenceFlow_0j3pm2g</bpmn:incoming>
-      <bpmn:outgoing>SequenceFlow_17llfxw</bpmn:outgoing>
-    </bpmn:serviceTask>
-    <bpmn:sequenceFlow id="SequenceFlow_17llfxw" sourceRef="Task_0k2q5vd" targetRef="Task_1u5pka9" />
-    <bpmn:callActivity id="Task_1u5pka9" name="Config Assign&#10;CDS call&#10;" calledElement="AbstractCDSProcessingBB">
-      <bpmn:extensionElements>
-        <camunda:in source="executionObject" target="executionObject" />
-        <camunda:in businessKey="#{execution.processBusinessKey}" />
-        <camunda:out source="CDSStatus" target="CDSStatus" />
-      </bpmn:extensionElements>
-      <bpmn:incoming>SequenceFlow_17llfxw</bpmn:incoming>
-      <bpmn:outgoing>SequenceFlow_0p0aqtx</bpmn:outgoing>
-    </bpmn:callActivity>
     <bpmn:exclusiveGateway id="ExclusiveGateway_0vtv1wi" default="SequenceFlow_1w4p9f7">
-      <bpmn:incoming>SequenceFlow_0p0aqtx</bpmn:incoming>
+      <bpmn:incoming>SequenceFlow_07bmtu7</bpmn:incoming>
       <bpmn:outgoing>SequenceFlow_1owbpsy</bpmn:outgoing>
       <bpmn:outgoing>SequenceFlow_1w4p9f7</bpmn:outgoing>
     </bpmn:exclusiveGateway>
-    <bpmn:sequenceFlow id="SequenceFlow_0p0aqtx" sourceRef="Task_1u5pka9" targetRef="ExclusiveGateway_0vtv1wi" />
-    <bpmn:sequenceFlow id="SequenceFlow_1owbpsy" name="Success" sourceRef="ExclusiveGateway_0vtv1wi" targetRef="Task_1uvsz0c">
+    <bpmn:sequenceFlow id="SequenceFlow_1owbpsy" name="Success" sourceRef="ExclusiveGateway_0vtv1wi" targetRef="Task_14cwhgk">
       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{execution.getVariable("CDSStatus").equals("Success")}</bpmn:conditionExpression>
     </bpmn:sequenceFlow>
-    <bpmn:sequenceFlow id="SequenceFlow_0jfgn7n" sourceRef="Task_1uvsz0c" targetRef="Task_1a5w1si" />
-    <bpmn:callActivity id="Task_1a5w1si" name="Config Deploy&#10;CDS call&#10;" calledElement="AbstractCDSProcessingBB">
-      <bpmn:extensionElements>
-        <camunda:in businessKey="#{execution.processBusinessKey}" />
-        <camunda:in source="executionObject" target="executionObject" />
-        <camunda:out source="CDSStatus" target="CDSStatus" />
-      </bpmn:extensionElements>
-      <bpmn:incoming>SequenceFlow_0jfgn7n</bpmn:incoming>
-      <bpmn:outgoing>SequenceFlow_08voj55</bpmn:outgoing>
-    </bpmn:callActivity>
     <bpmn:exclusiveGateway id="ExclusiveGateway_01jwwmc" default="SequenceFlow_0d24h26">
-      <bpmn:incoming>SequenceFlow_08voj55</bpmn:incoming>
+      <bpmn:incoming>SequenceFlow_02919fh</bpmn:incoming>
       <bpmn:outgoing>SequenceFlow_1n080up</bpmn:outgoing>
       <bpmn:outgoing>SequenceFlow_0d24h26</bpmn:outgoing>
     </bpmn:exclusiveGateway>
-    <bpmn:sequenceFlow id="SequenceFlow_08voj55" sourceRef="Task_1a5w1si" targetRef="ExclusiveGateway_01jwwmc" />
     <bpmn:sequenceFlow id="SequenceFlow_1n080up" name="Success" sourceRef="ExclusiveGateway_01jwwmc" targetRef="EndEvent_0xky46v">
       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{execution.getVariable("CDSStatus").equals("Success")}</bpmn:conditionExpression>
     </bpmn:sequenceFlow>
@@ -74,12 +48,30 @@
     </bpmn:serviceTask>
     <bpmn:sequenceFlow id="SequenceFlow_069mxkg" sourceRef="ConfigurePnfResource_StartEvent" targetRef="Task_1nhh7ob" />
     <bpmn:sequenceFlow id="SequenceFlow_1u89rk8" sourceRef="Task_1nhh7ob" targetRef="ExclusiveGateway_079gavg" />
-    <bpmn:sequenceFlow id="SequenceFlow_0j3pm2g" name="false" sourceRef="ExclusiveGateway_079gavg" targetRef="Task_0k2q5vd">
+    <bpmn:sequenceFlow id="SequenceFlow_0j3pm2g" name="false" sourceRef="ExclusiveGateway_079gavg" targetRef="Task_0zivzd5">
       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{!SkipPostInstantiationConfiguration}</bpmn:conditionExpression>
     </bpmn:sequenceFlow>
-    <bpmn:serviceTask id="Task_1uvsz0c" name="Prepare Config Deploy" camunda:delegateExpression="${PrepareConfigDeployDelegate}">
+    <bpmn:sequenceFlow id="SequenceFlow_07bmtu7" sourceRef="Task_0zivzd5" targetRef="ExclusiveGateway_0vtv1wi" />
+    <bpmn:serviceTask id="Task_0zivzd5" name="ControllerExecutionDE" camunda:delegateExpression="${ControllerExecutionDE}">
+      <bpmn:extensionElements>
+        <camunda:inputOutput>
+          <camunda:inputParameter name="action">config-assign</camunda:inputParameter>
+          <camunda:inputParameter name="scope">pnf</camunda:inputParameter>
+        </camunda:inputOutput>
+      </bpmn:extensionElements>
+      <bpmn:incoming>SequenceFlow_0j3pm2g</bpmn:incoming>
+      <bpmn:outgoing>SequenceFlow_07bmtu7</bpmn:outgoing>
+    </bpmn:serviceTask>
+    <bpmn:sequenceFlow id="SequenceFlow_02919fh" sourceRef="Task_14cwhgk" targetRef="ExclusiveGateway_01jwwmc" />
+    <bpmn:serviceTask id="Task_14cwhgk" name="ControllerExecutionDE" camunda:delegateExpression="${ControllerExecutionDE}">
+      <bpmn:extensionElements>
+        <camunda:inputOutput>
+          <camunda:inputParameter name="action">config-deploy</camunda:inputParameter>
+          <camunda:inputParameter name="scope">pnf</camunda:inputParameter>
+        </camunda:inputOutput>
+      </bpmn:extensionElements>
       <bpmn:incoming>SequenceFlow_1owbpsy</bpmn:incoming>
-      <bpmn:outgoing>SequenceFlow_0jfgn7n</bpmn:outgoing>
+      <bpmn:outgoing>SequenceFlow_02919fh</bpmn:outgoing>
     </bpmn:serviceTask>
   </bpmn:process>
   <bpmn:error id="Error_11v8tez" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
@@ -105,44 +97,19 @@
           <dc:Bounds x="918" y="158" width="19" height="14" />
         </bpmndi:BPMNLabel>
       </bpmndi:BPMNEdge>
-      <bpmndi:BPMNShape id="ServiceTask_0h627qv_di" bpmnElement="Task_0k2q5vd">
-        <dc:Bounds x="486" y="286" width="100" height="80" />
-      </bpmndi:BPMNShape>
-      <bpmndi:BPMNEdge id="SequenceFlow_17llfxw_di" bpmnElement="SequenceFlow_17llfxw">
-        <di:waypoint x="586" y="326" />
-        <di:waypoint x="621" y="326" />
-      </bpmndi:BPMNEdge>
-      <bpmndi:BPMNShape id="CallActivity_0y8mxy4_di" bpmnElement="Task_1u5pka9">
-        <dc:Bounds x="621" y="286" width="100" height="80" />
-      </bpmndi:BPMNShape>
       <bpmndi:BPMNShape id="ExclusiveGateway_0vtv1wi_di" bpmnElement="ExclusiveGateway_0vtv1wi" isMarkerVisible="true">
         <dc:Bounds x="786" y="301" width="50" height="50" />
       </bpmndi:BPMNShape>
-      <bpmndi:BPMNEdge id="SequenceFlow_0p0aqtx_di" bpmnElement="SequenceFlow_0p0aqtx">
-        <di:waypoint x="721" y="326" />
-        <di:waypoint x="786" y="326" />
-      </bpmndi:BPMNEdge>
       <bpmndi:BPMNEdge id="SequenceFlow_1owbpsy_di" bpmnElement="SequenceFlow_1owbpsy">
         <di:waypoint x="836" y="326" />
-        <di:waypoint x="901" y="326" />
+        <di:waypoint x="987" y="326" />
         <bpmndi:BPMNLabel>
-          <dc:Bounds x="847" y="308" width="43" height="14" />
+          <dc:Bounds x="890" y="308" width="43" height="14" />
         </bpmndi:BPMNLabel>
       </bpmndi:BPMNEdge>
-      <bpmndi:BPMNEdge id="SequenceFlow_0jfgn7n_di" bpmnElement="SequenceFlow_0jfgn7n">
-        <di:waypoint x="1001" y="326" />
-        <di:waypoint x="1066" y="326" />
-      </bpmndi:BPMNEdge>
-      <bpmndi:BPMNShape id="CallActivity_1viph1b_di" bpmnElement="Task_1a5w1si">
-        <dc:Bounds x="1066" y="286" width="100" height="80" />
-      </bpmndi:BPMNShape>
       <bpmndi:BPMNShape id="ExclusiveGateway_01jwwmc_di" bpmnElement="ExclusiveGateway_01jwwmc" isMarkerVisible="true">
         <dc:Bounds x="1231" y="301" width="50" height="50" />
       </bpmndi:BPMNShape>
-      <bpmndi:BPMNEdge id="SequenceFlow_08voj55_di" bpmnElement="SequenceFlow_08voj55">
-        <di:waypoint x="1166" y="326" />
-        <di:waypoint x="1231" y="326" />
-      </bpmndi:BPMNEdge>
       <bpmndi:BPMNEdge id="SequenceFlow_1n080up_di" bpmnElement="SequenceFlow_1n080up">
         <di:waypoint x="1256" y="301" />
         <di:waypoint x="1256" y="176" />
@@ -185,13 +152,24 @@
       <bpmndi:BPMNEdge id="SequenceFlow_0j3pm2g_di" bpmnElement="SequenceFlow_0j3pm2g">
         <di:waypoint x="426" y="201" />
         <di:waypoint x="426" y="326" />
-        <di:waypoint x="486" y="326" />
+        <di:waypoint x="551" y="326" />
         <bpmndi:BPMNLabel>
-          <dc:Bounds x="429" y="261" width="24" height="14" />
+          <dc:Bounds x="471" y="308" width="24" height="14" />
         </bpmndi:BPMNLabel>
       </bpmndi:BPMNEdge>
-      <bpmndi:BPMNShape id="ServiceTask_0vmu4wk_di" bpmnElement="Task_1uvsz0c">
-        <dc:Bounds x="901" y="286" width="100" height="80" />
+      <bpmndi:BPMNEdge id="SequenceFlow_07bmtu7_di" bpmnElement="SequenceFlow_07bmtu7">
+        <di:waypoint x="651" y="326" />
+        <di:waypoint x="786" y="326" />
+      </bpmndi:BPMNEdge>
+      <bpmndi:BPMNShape id="ServiceTask_1rqxeyq_di" bpmnElement="Task_0zivzd5">
+        <dc:Bounds x="551" y="286" width="100" height="80" />
+      </bpmndi:BPMNShape>
+      <bpmndi:BPMNEdge id="SequenceFlow_02919fh_di" bpmnElement="SequenceFlow_02919fh">
+        <di:waypoint x="1087" y="326" />
+        <di:waypoint x="1231" y="326" />
+      </bpmndi:BPMNEdge>
+      <bpmndi:BPMNShape id="ServiceTask_0lyl5n4_di" bpmnElement="Task_14cwhgk">
+        <dc:Bounds x="987" y="286" width="100" height="80" />
       </bpmndi:BPMNShape>
     </bpmndi:BPMNPlane>
   </bpmndi:BPMNDiagram>
diff --git a/bpmn/so-bpmn-infrastructure-flows/src/test/java/org/onap/so/bpmn/infrastructure/process/CreateVcpeResCustServiceSimplifiedTest.java b/bpmn/so-bpmn-infrastructure-flows/src/test/java/org/onap/so/bpmn/infrastructure/process/CreateVcpeResCustServiceSimplifiedTest.java
index 1cd8295..aea06b5 100644
--- a/bpmn/so-bpmn-infrastructure-flows/src/test/java/org/onap/so/bpmn/infrastructure/process/CreateVcpeResCustServiceSimplifiedTest.java
+++ b/bpmn/so-bpmn-infrastructure-flows/src/test/java/org/onap/so/bpmn/infrastructure/process/CreateVcpeResCustServiceSimplifiedTest.java
@@ -105,7 +105,6 @@
 
     }
 
-    @Ignore
     @Test
     public void workflow_validInput_expectedOuput() throws InterruptedException {
 
diff --git a/bpmn/so-bpmn-infrastructure-flows/src/test/resources/response/CreateVcpeResCustServiceSimplifiedTest_catalogdb.json b/bpmn/so-bpmn-infrastructure-flows/src/test/resources/response/CreateVcpeResCustServiceSimplifiedTest_catalogdb.json
index 66d1a88..422fb41 100644
--- a/bpmn/so-bpmn-infrastructure-flows/src/test/resources/response/CreateVcpeResCustServiceSimplifiedTest_catalogdb.json
+++ b/bpmn/so-bpmn-infrastructure-flows/src/test/resources/response/CreateVcpeResCustServiceSimplifiedTest_catalogdb.json
@@ -15,6 +15,7 @@
         "blueprintVersion": "1.0.0",
         "skipPostInstConf": false,
         "creationTimestamp": "2019-03-08T12:00:29.000+0000",
+        "controllerActor": "cds",
         "_links": {
           "self": {
             "href": "http://localhost:41023/pnfResourceCustomization/68dc9a92-214c-11e7-93ae-92361f002680"
@@ -34,4 +35,4 @@
       "href": "http://localhost:41023/pnfResourceCustomization/search/findPnfResourceCustomizationByModelUuid?SERVICE_MODEL_UUID=5df8b6de-2083-11e7-93ae-92361f002676"
     }
   }
-}
\ No newline at end of file
+}
diff --git a/bpmn/so-bpmn-tasks/pom.xml b/bpmn/so-bpmn-tasks/pom.xml
index bf129df..d37120b 100644
--- a/bpmn/so-bpmn-tasks/pom.xml
+++ b/bpmn/so-bpmn-tasks/pom.xml
@@ -13,6 +13,7 @@
     <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
     <maven.compiler.target>1.8</maven.compiler.target>
     <maven.compiler.source>1.8</maven.compiler.source>
+    <grpc.version>1.17.1</grpc.version>
   </properties>
   <build>
     <plugins>
@@ -165,5 +166,11 @@
       <version>2.5.1</version>
       <scope>test</scope>
     </dependency>
+    <dependency>
+      <groupId>io.grpc</groupId>
+      <artifactId>grpc-testing</artifactId>
+      <version>${grpc.version}</version>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 </project>
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/AbstractControllerExecution.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/AbstractControllerExecution.java
new file mode 100644
index 0000000..f3b767a
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/AbstractControllerExecution.java
@@ -0,0 +1,174 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl;
+
+import com.google.common.base.Strings;
+import java.util.List;
+import java.util.Optional;
+import java.util.stream.Collectors;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * Abstract class of the controller execution, it should be extended for the controller execution task.
+ * 
+ * @param <T> execution context type, e.g., BuildingBlockExecution or DelegateExecution
+ */
+public abstract class AbstractControllerExecution<T> {
+
+    /**
+     * parameters from the execution context.
+     */
+    protected static final String CONTROLLER_ACTOR_PARAM = "actor";
+    protected static final String CONTROLLER_ACTION_PARAM = "action";
+    protected static final String CONTROLLER_SCOPE_PARAM = "scope";
+    protected static final String RESOURCE_CUSTOMIZATION_UUID_PARAM = "resource_customization_uuid";
+    protected static final String RESOURCE_TYPE_PARAM = "resource_type";
+
+    protected final Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    protected List<ControllerRunnable<T>> availableControllerRunnables;
+
+    @Autowired
+    protected ExceptionBuilder exceptionBuilder;
+
+    /**
+     * Find the {@ref ControllerRunnable} instances understanding the {@ref ControllerContext}.
+     *
+     * Only one instance should be able to understand the context. if more than one or none instances found, return
+     * null.
+     *
+     * @param context controller context
+     * @return Optional of ControllerRunnable instance
+     */
+    protected Optional<ControllerRunnable> getController(ControllerContext<T> context) {
+        List<ControllerRunnable<T>> satisfiedControllers = availableControllerRunnables.stream()
+                .filter(controllerRunnable -> controllerRunnable.understand(context)).collect(Collectors.toList());
+
+        if (logger.isDebugEnabled()) {
+            for (ControllerRunnable<T> satisfiedController : satisfiedControllers) {
+                logger.debug("{} controllerRunnable understands the context", satisfiedController.getClass().getName());
+            }
+        }
+
+        /**
+         * Make sure only one {@ref ControllerRunnable} instance understands the context or else return Null.
+         */
+        if (satisfiedControllers.size() == 1) {
+            return Optional.of(satisfiedControllers.get(0));
+        } else if (satisfiedControllers.isEmpty()) {
+            logger.warn("Can NOT find any ControllerRunnable for context: {}", context);
+        } else if (satisfiedControllers.size() > 1) {
+            logger.warn(
+                    "Found {} instances understanding the context: {}, please make sure only 1 instance understands it",
+                    satisfiedControllers.size(), context);
+        }
+
+        return Optional.empty();
+    }
+
+    /**
+     * Build the {@ref ControllerContext} context based on execution context.
+     * 
+     * @param t execution context instance, e.g., BuildingBlockExecution or DelegateExecution instance
+     * @return controller context instance of the execution context type
+     */
+    protected ControllerContext<T> buildControllerContext(final T t) {
+        String controllerAction = getParameterFromExecution(t, CONTROLLER_ACTION_PARAM);
+        String controllerScope = getParameterFromExecution(t, CONTROLLER_SCOPE_PARAM);
+        String resourceCustomizationUuid = getParameterFromExecution(t, RESOURCE_CUSTOMIZATION_UUID_PARAM);
+        String controllerActor = getControllerActor(t, controllerScope, resourceCustomizationUuid, controllerAction);
+        ControllerContext<T> controllerContext = new ControllerContext<>();
+        controllerContext.setExecution(t);
+        controllerContext.setControllerAction(controllerAction);
+        controllerContext.setControllerActor(controllerActor);
+        controllerContext.setControllerScope(controllerScope);
+        return controllerContext;
+    }
+
+    /**
+     * Retrieve the controller actor.
+     * 
+     * @param t execution context instance, e.g., BuildingBlockExecution or DelegateExecution instance
+     * @param controllerScope controller scope, e.g, pnf, vnf, vfModule
+     * @param resourceCustomizationUuid resource customization UUID, e.g, pnfCustomizationUuid, vnfCustomizationUuid
+     * @param controllerAction controller action, e.g, configAssign, configDeploy
+     * @return controller actor
+     */
+    protected abstract String getControllerActor(T t, String controllerScope, String resourceCustomizationUuid,
+            String controllerAction);
+
+    /**
+     * Controller execution based on the Controller Context.
+     * 
+     * @param controllerContext ControllerContext object
+     */
+    public abstract void controllerExecute(final ControllerContext<T> controllerContext);
+
+    /**
+     * Retrieve the parameter value as String from the execution context.
+     * 
+     * @param t execution context instance, e.g., BuildingBlockExecution or DelegateExecution instance
+     * @param parameterName parameter name to be retrieved
+     * @return String value of the parameter
+     */
+    protected abstract String getParameterFromExecution(final T t, String parameterName);
+
+    /**
+     * Check whether the controller actor value is SO ref value, i.e, equals to SO-REF-DATA.
+     * 
+     * @param controllerActor controller actor, e.g, SO-REF-DATA, SDNC, CDS
+     * @return true if the controller actor is SO-REF-DATA, else return false
+     */
+    protected boolean isSoRefControllerActor(final String controllerActor) {
+        return !Strings.isNullOrEmpty(controllerActor) && controllerActor.equalsIgnoreCase("SO-REF-DATA");
+    }
+
+    /**
+     * Check whether the controller scope is PNF resource related.
+     * 
+     * @param controllerScope controller scope, e.g, pnf, vnf, vfModule
+     * @return true if the controller scope is pnf, else return false
+     */
+    protected boolean isPnfResourceScope(final String controllerScope) {
+        return ("pnf").equalsIgnoreCase(controllerScope);
+    }
+
+    /**
+     * Check whether the controller scope is VNF resource related.
+     * 
+     * @param controllerScope controller scope, e.g, pnf, vnf, vfModule
+     * @return true if the controller scope is vnf or vfModule, else return false
+     */
+    protected boolean isVnfResourceScope(final String controllerScope) {
+        if (Strings.isNullOrEmpty(controllerScope)) {
+            return false;
+        }
+        if (controllerScope.toLowerCase().startsWith("vnf") || controllerScope.equalsIgnoreCase("vfmodule")) {
+            return true;
+        }
+        return false;
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBB.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBB.java
new file mode 100644
index 0000000..39a695b
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBB.java
@@ -0,0 +1,152 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock;
+
+import com.google.common.base.Strings;
+import java.util.Optional;
+import org.onap.logging.filter.base.ONAPComponents;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.AbstractControllerExecution;
+import org.onap.so.db.catalog.beans.ControllerSelectionReference;
+import org.onap.so.db.catalog.beans.PnfResourceCustomization;
+import org.onap.so.db.catalog.beans.VnfResourceCustomization;
+import org.onap.so.db.catalog.client.CatalogDbClient;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class is used for {@ref BuildingBlockExecution} API based execution.
+ *
+ * it decides which controller implementation to use based on the parameters, like actor, scope, action.
+ *
+ * The following parameters are expected in the {@ref BuildingBlockExecution} context,
+ * <ul>
+ * <li>action: action to be executed</li>
+ * <li>scope: type of the resource, i.e, pnf, vnf, vf</li>
+ * <li>resource_customization_uuid: resource customization UUID</li>
+ * <li>resource_type: resource type, optional. It's used to find the controller from controller_selection_reference
+ * table. Same as VNF_TYPE in the table</li>
+ * </ul>
+ */
+@Component
+public class ControllerExecutionBB extends AbstractControllerExecution<BuildingBlockExecution> {
+
+    @Autowired
+    protected CatalogDbClient catalogDbClient;
+
+    public void execute(final BuildingBlockExecution execution) {
+        ControllerContext<BuildingBlockExecution> controllerContext = buildControllerContext(execution);
+        controllerExecute(controllerContext);
+    }
+
+    @Override
+    protected String getParameterFromExecution(BuildingBlockExecution execution, String parameterName) {
+        Object object = execution.getVariable(parameterName);
+        if (object != null) {
+            String paramValue = String.valueOf(object);
+            logger.debug("parameterName: {}, parameterValue: {}", parameterName, paramValue);
+            return paramValue;
+        }
+        return "";
+    }
+
+    /**
+     * this method is used to get the controller actor, there could be few places to get the actor(ordered by priority),
+     *
+     * <ol>
+     * <li>Execution Context, i.e, BuildingBlockExecution</li>
+     * <li>Resource customization table, pnf_resource_customization for PNF or vnf_resource_customization for VNF</li>
+     * <li>controller_selection_reference, resource_type and action will be used to fetch from this table</li>
+     * </ol>
+     *
+     * @param execution BuildingBlockExecution instance
+     * @param controllerScope controller scope, e.g, pnf, vnf, vfModule
+     * @param resourceCustomizationUuid resource customization UUID, e.g, pnfCustomizationUuid, vnfCustomizationUuid
+     * @param controllerAction controller action, e.g, configAssign, configDeploy
+     * @return controller actor name
+     */
+    @Override
+    protected String getControllerActor(BuildingBlockExecution execution, String controllerScope,
+            String resourceCustomizationUuid, String controllerAction) {
+
+        /**
+         * Firstly, check the execution context for actor parameter.
+         */
+        String controllerActor = getParameterFromExecution(execution, CONTROLLER_ACTOR_PARAM);
+
+        /**
+         * If no meaningful controller actor value found in the execution context and the value is not SO-REF-DATA.
+         */
+        if (Strings.isNullOrEmpty(controllerActor) && !isSoRefControllerActor(controllerActor)) {
+
+            /**
+             * For BuildingBlockExecution, we should try to get the resource information from Cached metadata.
+             *
+             * As the current cached metadata doesn't support controller actor, we use the
+             * {@link org.onap.so.db.catalog.client.CatalogDbClient} to fetch information. Once the change is done in
+             * cached metadata, this part should be refactored as well.
+             */
+            if (isPnfResourceScope(controllerScope)) {
+                PnfResourceCustomization pnfResourceCustomization =
+                        catalogDbClient.getPnfResourceCustomizationByModelCustomizationUUID(resourceCustomizationUuid);
+                controllerActor = pnfResourceCustomization.getControllerActor();
+            } else if (isVnfResourceScope(controllerScope)) {
+                VnfResourceCustomization vnfResourceCustomization =
+                        catalogDbClient.getVnfResourceCustomizationByModelCustomizationUUID(resourceCustomizationUuid);
+                controllerActor = vnfResourceCustomization.getControllerActor();
+            } else {
+                logger.warn("Unrecognized scope: {}", controllerScope);
+            }
+        }
+
+        /**
+         * Lastly, can NOT find the controller actor information from resource customization table or the return value
+         * is SO-REF-DATA.
+         */
+        if (Strings.isNullOrEmpty(controllerActor) || isSoRefControllerActor(controllerActor)) {
+            String resourceType = getParameterFromExecution(execution, RESOURCE_TYPE_PARAM);
+            ControllerSelectionReference reference = catalogDbClient
+                    .getControllerSelectionReferenceByVnfTypeAndActionCategory(resourceType, controllerAction);
+
+            controllerActor = reference.getControllerName();
+        }
+        return controllerActor;
+    }
+
+    @Override
+    public void controllerExecute(ControllerContext<BuildingBlockExecution> controllerContext) {
+        Optional<ControllerRunnable> optional = getController(controllerContext);
+        if (optional.isPresent()) {
+            ControllerRunnable controller = optional.get();
+            if (controller.ready(controllerContext)) {
+                controller.prepare(controllerContext);
+                controller.run(controllerContext);
+            } else {
+                exceptionBuilder.buildAndThrowWorkflowException(controllerContext.getExecution(), 9001,
+                        "Controller is NOT Ready for the action", ONAPComponents.SO);
+            }
+        } else {
+            exceptionBuilder.buildAndThrowWorkflowException(controllerContext.getExecution(), 9000,
+                    "Unable to find the controller implementation", ONAPComponents.SO);
+        }
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/LcmControllerBB.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/LcmControllerBB.java
new file mode 100644
index 0000000..d7f6808
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/LcmControllerBB.java
@@ -0,0 +1,68 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller;
+
+import java.util.List;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * This class should be extended by LCM api based controllers.
+ */
+public abstract class LcmControllerBB implements ControllerRunnable<BuildingBlockExecution> {
+
+    protected Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    protected ExceptionBuilder exceptionUtil;
+
+    @Autowired(required = false)
+    protected List<ControllerPreparable<BuildingBlockExecution>> prepareList;
+
+    @Autowired
+    protected ApplicationControllerAction client;
+
+    @Override
+    public void prepare(ControllerContext<BuildingBlockExecution> context) {
+        prepareList.stream().filter(prepare -> prepare.understand(context))
+                .forEach(prepare -> prepare.prepare(context));
+    }
+
+    @Override
+    public void run(ControllerContext<BuildingBlockExecution> context) {
+        callLcmClient(context);
+    }
+
+    /**
+     * This method is used to execute the LCM action by calling LCM client, appc Client or SDNC client.
+     *
+     * @return error code
+     */
+    protected abstract int callLcmClient(ControllerContext<BuildingBlockExecution> context);
+
+    protected abstract int getErrorCode();
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/appc/AppcControllerBB.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/appc/AppcControllerBB.java
new file mode 100644
index 0000000..8650994
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/appc/AppcControllerBB.java
@@ -0,0 +1,66 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.appc;
+
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.LcmControllerBB;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * This implementation of {@link ControllerRunnable} is created to demonstrate how to support Appc based controller.
+ */
+@Component
+public class AppcControllerBB extends LcmControllerBB {
+
+    private static final int APPC_ERROR_CODE = 1002;
+
+    @Autowired
+    private ApplicationControllerAction client;
+
+    @Override
+    public Boolean understand(ControllerContext<BuildingBlockExecution> context) {
+        return context.getControllerActor().equalsIgnoreCase("appc");
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<BuildingBlockExecution> context) {
+        return true;
+    }
+
+    /**
+     * This method is left empty intentionally. If you are planning to use the Appc Controller, please implement here.
+     *
+     * You can use the {@ref ApplicationControllerAction}, {@ref ApplicationControllerOrchestrator},
+     * {@ref ApplicationControllerClient} or create your own Appc Client proxy.
+     */
+    @Override
+    protected int callLcmClient(ControllerContext<BuildingBlockExecution> context) {
+        return 0;
+    }
+
+    @Override
+    protected int getErrorCode() {
+        return APPC_ERROR_CODE;
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/SdncControllerBB.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/SdncControllerBB.java
new file mode 100644
index 0000000..6baf881
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/SdncControllerBB.java
@@ -0,0 +1,73 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.sdnc;
+
+import java.util.Arrays;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.LcmControllerBB;
+import org.springframework.stereotype.Component;
+
+/**
+ * This implementation of {@link ControllerRunnable} is created to demonstrate how to support SDNC based controller.
+ *
+ * For demo purpose, the following actions are supported, UpgradePreCheck UpgradeSoftware UpgradePostCheck, all of these
+ * actions are appc based actions and they need to be refactored to proper SDNC LCM actions.
+ */
+@Component
+public class SdncControllerBB extends LcmControllerBB {
+
+    private static final String[] supportedActions = new String[] {};
+
+    private static final int SDNC_ERROR_CODE = 1002;
+
+    @Override
+    public Boolean understand(ControllerContext<BuildingBlockExecution> context) {
+        return context.getControllerActor().equalsIgnoreCase("sdnc");
+    }
+
+    private boolean isActionSupported(ControllerContext<BuildingBlockExecution> context) {
+        return Arrays.stream(supportedActions).anyMatch(action -> action.equals(context.getControllerAction()));
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<BuildingBlockExecution> context) {
+        return true;
+    }
+
+    /**
+     * This method is left empty intentionally. If you are planning to use the SDNC Controller, please implement here.
+     *
+     * You can use the Appc Client proxy, like, {@ref ApplicationControllerAction}
+     * {@ref ApplicationControllerOrchestrator} {@ref ApplicationControllerClient}
+     *
+     * Or create your own SDNC Client proxy.
+     */
+    @Override
+    protected int callLcmClient(ControllerContext<BuildingBlockExecution> context) {
+        return 0;
+    }
+
+    @Override
+    protected int getErrorCode() {
+        return SDNC_ERROR_CODE;
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/prepare/PrepareSdncBB.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/prepare/PrepareSdncBB.java
new file mode 100644
index 0000000..dd75107
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/prepare/PrepareSdncBB.java
@@ -0,0 +1,47 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.sdnc.prepare;
+
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * This abstract class should be extended by all the SDNC based {@ControllerPreparable}. It defines some common
+ * behavior.
+ */
+public abstract class PrepareSdncBB implements ControllerPreparable<BuildingBlockExecution> {
+
+    protected Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    protected ExceptionBuilder exceptionUtil;
+
+    @Autowired
+    protected ExtractPojosForBB extractPojosForBB;
+
+    public boolean understand(final ControllerContext<BuildingBlockExecution> controllerContext) {
+        return controllerContext.getControllerActor().equalsIgnoreCase("sdnc");
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/prepare/PrepareSdncUpgradePreCheckPnfBB.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/prepare/PrepareSdncUpgradePreCheckPnfBB.java
new file mode 100644
index 0000000..c659290
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/prepare/PrepareSdncUpgradePreCheckPnfBB.java
@@ -0,0 +1,60 @@
+/*
+ * ============LICENSE_START======================================================= Copyright (C) 2019 Nordix
+ * ================================================================================ Licensed under the Apache License,
+ * Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy
+ * of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
+ * either express or implied. See the License for the specific language governing permissions and limitations under the
+ * License.
+ *
+ * SPDX-License-Identifier: Apache-2.0 ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.sdnc.prepare;
+
+import org.json.JSONArray;
+import org.json.JSONObject;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class is used to prepare the {@ref ControllerContext} for SDNC UpgradePreCheck action.
+ */
+@Component
+public class PrepareSdncUpgradePreCheckPnfBB extends PrepareSdncBB {
+
+    @Override
+    public boolean understand(ControllerContext<BuildingBlockExecution> controllerContext) {
+        return super.understand(controllerContext) && controllerContext.getControllerAction().equals("UpgradePreCheck")
+                && controllerContext.getControllerScope().equalsIgnoreCase("pnf");
+    }
+
+    @Override
+    public void prepare(ControllerContext<BuildingBlockExecution> controllerContext) {
+
+        String payload = controllerContext.getExecution().getVariable("payload");
+        String actualPayLoad = constructPayload(payload, controllerContext.getControllerAction());
+
+        controllerContext.getExecution().setVariable("payload", actualPayLoad);
+    }
+
+    private String constructPayload(String payload, String action) {
+
+        JSONObject jsonObject = new JSONObject(payload);
+        if (jsonObject.has("action")) {
+            JSONArray jsonArray = jsonObject.getJSONArray("action");
+
+            for (int i = 0; i < jsonArray.length(); i++) {
+                JSONObject jsonObject1 = jsonArray.getJSONObject(i);
+                if (jsonObject1.has(action)) {
+                    return jsonObject1.toString();
+                }
+            }
+        }
+        return payload;
+    }
+}
+
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDE.java
new file mode 100644
index 0000000..0458d3c
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDE.java
@@ -0,0 +1,148 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda;
+
+import com.google.common.base.Strings;
+import java.util.Optional;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.camunda.bpm.engine.delegate.JavaDelegate;
+import org.onap.logging.filter.base.ONAPComponents;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.AbstractControllerExecution;
+import org.onap.so.db.catalog.beans.ControllerSelectionReference;
+import org.onap.so.db.catalog.beans.PnfResourceCustomization;
+import org.onap.so.db.catalog.beans.VnfResourceCustomization;
+import org.onap.so.db.catalog.client.CatalogDbClient;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class is used for camunda {@ref DelegateExecution} API based controller execution.
+ *
+ * The following parameters are expected in the {@ref DelegateExecution} context,
+ *
+ * <ul>
+ * <li>action: action to be executed</li>
+ * <li>scope: type of the resource, i.e, pnf, vnf, vf</li>
+ * <li>resource_customization_uuid: resource customization UUID</li>
+ * <li>resource_type: resource type, optional. It's used to find the controller from controller_selection_reference
+ * table. Same as VNF_TYPE in the table</li>
+ * </ul>
+ */
+@Component
+public class ControllerExecutionDE extends AbstractControllerExecution<DelegateExecution> implements JavaDelegate {
+
+    @Autowired
+    protected CatalogDbClient catalogDbClient;
+
+    @Override
+    public void execute(final DelegateExecution execution) {
+        ControllerContext<DelegateExecution> controllerContext = buildControllerContext(execution);
+        controllerExecute(controllerContext);
+    }
+
+    /**
+     * this method is used to get the controller actor, there could be few places to get the actor(ordered by priority),
+     *
+     * <ol>
+     * <li>Execution Context, i.e, DelegateExecution</li>
+     * <li>Resource customization table, pnf_resource_customization for PNF or vnf_resource_customization for VNF</li>
+     * <li>controller_selection_reference, resource_type and action will be used to fetch from this table</li>
+     * </ol>
+     *
+     * @param execution DelegateExecution instance
+     * @param controllerScope controller scope, e.g, pnf, vnf, vfModule
+     * @param resourceCustomizationUuid resource customization UUID, e.g, pnfCustomizationUuid, vnfCustomizationUuid
+     * @param controllerAction controller action, e.g, configAssign, configDeploy
+     * @return controller actor
+     */
+    protected String getControllerActor(DelegateExecution execution, String controllerScope,
+            String resourceCustomizationUuid, String controllerAction) {
+
+        /**
+         * Firstly, check the execution context for actor parameter.
+         */
+        String controllerActor = getParameterFromExecution(execution, CONTROLLER_ACTOR_PARAM);
+
+        /**
+         * If no meaningful controller actor value found in the execution context and the value is not SO-REF-DATA.
+         */
+        if (Strings.isNullOrEmpty(controllerActor) && !isSoRefControllerActor(controllerActor)) {
+
+            /**
+             * secondly, if no meaningful actor from execution context, getting from resource table in database.
+             */
+            if (isPnfResourceScope(controllerScope)) {
+                PnfResourceCustomization pnfResourceCustomization =
+                        catalogDbClient.getPnfResourceCustomizationByModelCustomizationUUID(resourceCustomizationUuid);
+                controllerActor = pnfResourceCustomization.getControllerActor();
+            } else if (isVnfResourceScope(controllerScope)) {
+                VnfResourceCustomization vnfResourceCustomization =
+                        catalogDbClient.getVnfResourceCustomizationByModelCustomizationUUID(resourceCustomizationUuid);
+                controllerActor = vnfResourceCustomization.getControllerActor();
+            } else {
+                logger.warn("Unrecognized scope: {}", controllerScope);
+            }
+        }
+
+        /**
+         * Lastly, can NOT find the controller actor information from resource customization table or value is
+         * SO-REF-DATA
+         */
+        if (Strings.isNullOrEmpty(controllerActor) || isSoRefControllerActor(controllerActor)) {
+            String resourceType = getParameterFromExecution(execution, RESOURCE_TYPE_PARAM);
+            ControllerSelectionReference reference = catalogDbClient
+                    .getControllerSelectionReferenceByVnfTypeAndActionCategory(resourceType, controllerAction);
+            controllerActor = reference.getControllerName();
+        }
+
+        return controllerActor;
+    }
+
+    @Override
+    public void controllerExecute(ControllerContext<DelegateExecution> controllerContext) {
+        Optional<ControllerRunnable> optional = getController(controllerContext);
+
+        if (optional.isPresent()) {
+            ControllerRunnable controller = optional.get();
+            if (controller.ready(controllerContext)) {
+                controller.prepare(controllerContext);
+                controller.run(controllerContext);
+            } else {
+                exceptionBuilder.buildAndThrowWorkflowException(controllerContext.getExecution(), 9001,
+                        "Controller is NOT Ready for the action", ONAPComponents.SO);
+            }
+        } else {
+            exceptionBuilder.buildAndThrowWorkflowException(controllerContext.getExecution(), 9000,
+                    "Unable to find the controller implementation", ONAPComponents.SO);
+        }
+    }
+
+    @Override
+    protected String getParameterFromExecution(DelegateExecution execution, String parameterName) {
+        if (execution.hasVariable(parameterName)) {
+            String paramValue = String.valueOf(execution.getVariable(parameterName));
+            logger.debug("parameterName: {}, parameterValue: {}", parameterName, paramValue);
+            return paramValue;
+        } else {
+            return "";
+        }
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/LcmControllerDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/LcmControllerDE.java
new file mode 100644
index 0000000..95e270a
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/LcmControllerDE.java
@@ -0,0 +1,69 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller;
+
+import java.util.List;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * This abstract class implements {@link ControllerRunnable} used for {@link DelegateExecution} API based LCM
+ * controller.
+ */
+public abstract class LcmControllerDE implements ControllerRunnable<DelegateExecution> {
+
+    protected final Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    protected ExceptionBuilder exceptionUtil;
+
+    @Autowired
+    protected List<ControllerPreparable<DelegateExecution>> prepareList;
+
+    @Autowired
+    protected ApplicationControllerAction client;
+
+    @Override
+    public void prepare(ControllerContext<DelegateExecution> context) {
+        prepareList.stream().filter(prepare -> prepare.understand(context))
+                .forEach(prepare -> prepare.prepare(context));
+    }
+
+    @Override
+    public void run(ControllerContext<DelegateExecution> context) {
+        callLcmClient(context);
+    }
+
+    /**
+     * This method is used to execute the LCM action by calling LCM client, appc Client or SDNC client.
+     *
+     * @return error code
+     */
+    protected abstract int callLcmClient(ControllerContext<DelegateExecution> context);
+
+    protected abstract int getErrorCode();
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/appc/AppcControllerDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/appc/AppcControllerDE.java
new file mode 100644
index 0000000..7ebd16e
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/appc/AppcControllerDE.java
@@ -0,0 +1,62 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.appc;
+
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.LcmControllerDE;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class is created to demonstrate how to support {@link DelegateExecution} API based APPC controller.
+ *
+ * Function wise, it's similar as {@ref AppcClient} groovy code.
+ */
+@Component
+public class AppcControllerDE extends LcmControllerDE {
+
+    private static final int APPC_DELEGATE_EXECUTION_ERROR_CODE = 1102;
+
+    @Override
+    public Boolean understand(ControllerContext<DelegateExecution> context) {
+        return context.getControllerActor().equalsIgnoreCase("appc");
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<DelegateExecution> context) {
+        return true;
+    }
+
+    /**
+     * This method is left empty intentionally. If you are planning to use the Appc Controller, please implement here.
+     *
+     * You can use the {@ref ApplicationControllerAction}, {@ref ApplicationControllerOrchestrator},
+     * {@ref ApplicationControllerClient} or create your own Appc Client proxy.
+     */
+    @Override
+    protected int callLcmClient(ControllerContext<DelegateExecution> context) {
+        return 0;
+    }
+
+    @Override
+    protected int getErrorCode() {
+        return APPC_DELEGATE_EXECUTION_ERROR_CODE;
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/CdsControllerDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/CdsControllerDE.java
new file mode 100644
index 0000000..6b0cbc0
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/CdsControllerDE.java
@@ -0,0 +1,61 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.cds;
+
+import java.util.List;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.client.cds.AbstractCDSProcessingBBUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * This implementation of {@ref ControllerRunnable} is used for Self service, i.e, blueprint based Controller.
+ */
+@Component
+public class CdsControllerDE extends AbstractCDSProcessingBBUtils implements ControllerRunnable<DelegateExecution> {
+
+    @Autowired(required = false)
+    private List<ControllerPreparable<DelegateExecution>> prepareList;
+
+    @Override
+    public Boolean understand(ControllerContext<DelegateExecution> context) {
+        return context.getControllerActor().equalsIgnoreCase("cds");
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<DelegateExecution> context) {
+        return true;
+    }
+
+    @Override
+    public void prepare(ControllerContext<DelegateExecution> context) {
+        prepareList.stream().filter(prepare -> prepare.understand(context))
+                .forEach(prepare -> prepare.prepare(context));
+    }
+
+    @Override
+    public void run(ControllerContext<DelegateExecution> context) {
+        DelegateExecution execution = context.getExecution();
+        constructExecutionServiceInputObject(execution);
+        sendRequestToCDSClient(execution);
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/prepare/PreparePnfConfigAssignDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/prepare/PreparePnfConfigAssignDE.java
new file mode 100644
index 0000000..b0da075
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/prepare/PreparePnfConfigAssignDE.java
@@ -0,0 +1,50 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.cds.prepare;
+
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.bpmn.infrastructure.pnf.delegate.PrepareConfigAssignDelegate;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class implements {@link ControllerPreparable} interface and is used to set up the context for PNF config-assign
+ * action.
+ */
+@Component
+public class PreparePnfConfigAssignDE implements ControllerPreparable<DelegateExecution> {
+
+    @Autowired
+    private PrepareConfigAssignDelegate prepareConfigAssignDelegate;
+
+    @Override
+    public boolean understand(ControllerContext<DelegateExecution> controllerContext) {
+        return controllerContext.getControllerActor().equalsIgnoreCase("cds")
+                && controllerContext.getControllerAction().equalsIgnoreCase("config-assign")
+                && controllerContext.getControllerScope().equalsIgnoreCase("pnf");
+    }
+
+    @Override
+    public void prepare(ControllerContext<DelegateExecution> controllerContext) {
+        prepareConfigAssignDelegate.execute(controllerContext.getExecution());
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/prepare/PreparePnfConfigDeployDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/prepare/PreparePnfConfigDeployDE.java
new file mode 100644
index 0000000..b88da2e
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/prepare/PreparePnfConfigDeployDE.java
@@ -0,0 +1,50 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.cds.prepare;
+
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.bpmn.infrastructure.pnf.delegate.PrepareConfigDeployDelegate;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class implements {@link ControllerPreparable} interface and is used to set up the context for PNF config-deploy
+ * action.
+ */
+@Component
+public class PreparePnfConfigDeployDE implements ControllerPreparable<DelegateExecution> {
+
+    @Autowired
+    private PrepareConfigDeployDelegate prepareConfigDeployDelegate;
+
+    @Override
+    public boolean understand(ControllerContext<DelegateExecution> controllerContext) {
+        return controllerContext.getControllerActor().equalsIgnoreCase("cds")
+                && controllerContext.getControllerAction().equalsIgnoreCase("config-deploy")
+                && controllerContext.getControllerScope().equalsIgnoreCase("pnf");
+    }
+
+    @Override
+    public void prepare(ControllerContext<DelegateExecution> controllerContext) {
+        prepareConfigDeployDelegate.execute(controllerContext.getExecution());
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/sdnc/SdncControllerDE.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/sdnc/SdncControllerDE.java
new file mode 100644
index 0000000..db0d402
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/sdnc/SdncControllerDE.java
@@ -0,0 +1,62 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.sdnc;
+
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.LcmControllerDE;
+import org.springframework.stereotype.Component;
+
+/**
+ * This class is created to demonstrate how to support {@link DelegateExecution} API based SDNC controller.
+ *
+ * Function wise, it's similar to the Appc Controller, like in the AppcClient groovy code.
+ */
+@Component
+public class SdncControllerDE extends LcmControllerDE {
+
+    private static final int SDNC_DELEGATE_EXECUTION_ERROR_CODE = 1103;
+
+    @Override
+    public Boolean understand(ControllerContext<DelegateExecution> context) {
+        return context.getControllerActor().equalsIgnoreCase("sdnc");
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<DelegateExecution> context) {
+        return true;
+    }
+
+    /**
+     * This method is left empty intentionally. If you are planning to use the SDNC Controller, please implement here.
+     *
+     * You can use the {@ref ApplicationControllerAction}, {@ref ApplicationControllerOrchestrator},
+     * {@ref ApplicationControllerClient} or create your own SDNC Client proxy.
+     */
+    @Override
+    protected int callLcmClient(ControllerContext<DelegateExecution> context) {
+        return 0;
+    }
+
+    @Override
+    protected int getErrorCode() {
+        return SDNC_DELEGATE_EXECUTION_ERROR_CODE;
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/GrpcNettyServer.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/GrpcNettyServer.java
new file mode 100644
index 0000000..e089da6
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/GrpcNettyServer.java
@@ -0,0 +1,113 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so;
+
+import io.grpc.ServerBuilder;
+import io.grpc.stub.StreamObserver;
+import io.grpc.testing.GrpcCleanupRule;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.atomic.AtomicReference;
+import javax.annotation.PostConstruct;
+import org.junit.Rule;
+import org.onap.ccsdk.cds.controllerblueprints.common.api.EventType;
+import org.onap.ccsdk.cds.controllerblueprints.common.api.Status;
+import org.onap.ccsdk.cds.controllerblueprints.processing.api.BluePrintProcessingServiceGrpc.BluePrintProcessingServiceImplBase;
+import org.onap.ccsdk.cds.controllerblueprints.processing.api.ExecutionServiceInput;
+import org.onap.ccsdk.cds.controllerblueprints.processing.api.ExecutionServiceOutput;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.stereotype.Component;
+
+@Component
+public class GrpcNettyServer extends BluePrintProcessingServiceImplBase {
+
+    private static final Logger logger = LoggerFactory.getLogger(GrpcNettyServer.class);
+
+    @Value("${cds.endpoint}")
+    private String host;
+
+    @Value("${cds.port}")
+    private String port;
+
+    @Rule
+    public final GrpcCleanupRule grpcCleanup = new GrpcCleanupRule();
+
+    private final CountDownLatch allRequestsDelivered = new CountDownLatch(1);
+    private final AtomicReference<StreamObserver<ExecutionServiceOutput>> responseObserverRef = new AtomicReference<>();
+    private final List<ExecutionServiceInput> detailedMessages = new ArrayList<>();
+
+    @PostConstruct
+    public void start() throws IOException {
+
+        final BluePrintProcessingServiceImplBase blueprintPrcessorImpl = new BluePrintProcessingServiceImplBase() {
+            @Override
+            public StreamObserver<ExecutionServiceInput> process(
+                    StreamObserver<ExecutionServiceOutput> responseObserver) {
+
+                responseObserverRef.set(responseObserver);
+
+                StreamObserver<ExecutionServiceInput> requestObserver = new StreamObserver<ExecutionServiceInput>() {
+                    @Override
+                    public void onNext(ExecutionServiceInput message) {
+                        detailedMessages.add(message);
+                        logger.info("Message received: {}", message);
+                        ExecutionServiceOutput executionServiceOutput = ExecutionServiceOutput.newBuilder()
+                                .setActionIdentifiers(message.getActionIdentifiers())
+                                .setStatus(Status.newBuilder().setEventType(EventType.EVENT_COMPONENT_EXECUTED).build())
+                                .build();
+
+                        responseObserverRef.get().onNext(executionServiceOutput);
+                        logger.info("Message sent: {}", executionServiceOutput);
+                    }
+
+                    @Override
+                    public void onError(Throwable t) {
+                        responseObserverRef.get().onError(t);
+                    }
+
+                    @Override
+                    public void onCompleted() {
+                        allRequestsDelivered.countDown();
+                        responseObserverRef.get().onCompleted();
+                    }
+                };
+
+                return requestObserver;
+            }
+        };
+        grpcCleanup.register(ServerBuilder.forPort(Integer.valueOf(port)).directExecutor()
+                .addService(blueprintPrcessorImpl).build().start());
+
+    }
+
+    public List<ExecutionServiceInput> getDetailedMessages() {
+        return this.detailedMessages;
+    }
+
+    public void cleanMessage() {
+        this.detailedMessages.clear();
+    }
+
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBBTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBBTest.java
new file mode 100644
index 0000000..0f9b4d9
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBBTest.java
@@ -0,0 +1,160 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock;
+
+import static org.junit.Assert.assertEquals;
+import static org.mockito.Mockito.verify;
+import static org.mockito.Mockito.when;
+import static org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.MockControllerBB.TEST_ACTION;
+import static org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.MockControllerBB.TEST_ACTOR;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.db.catalog.beans.ControllerSelectionReference;
+import org.onap.so.db.catalog.beans.PnfResourceCustomization;
+import org.onap.so.db.catalog.beans.VnfResourceCustomization;
+import org.onap.so.db.catalog.client.CatalogDbClient;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {ControllerExecutionBB.class, MockControllerBB.class, ExceptionBuilder.class})
+public class ControllerExecutionBBTest {
+
+    private static final String ACTOR_PARAM = "actor";
+    private static final String ACTION_PARAM = "action";
+    private static final String RESOURCE_TYPE_PARAM = "resource_type";
+
+    private static final String TEST_RESOURCE_CUSTOMIZATION_UUID = "68dc9a92-214c-11e7-93ae-92361f002680";
+    private static final String TEST_CATALOGDB_CONTROLLER_ACTOR = "cds";
+    private static final String TEST_RESOURCE_TYPE = "Firewall";
+    private static final String TEST_CONTROLLER_REFERENCE_ACTOR = "sdnc";
+    private static final String TEST_SCOPE = "pnf";
+
+    @Autowired
+    private ControllerExecutionBB controllerExecutionBB;
+
+    @MockBean
+    private BuildingBlockExecution execution;
+
+    @MockBean
+    private CatalogDbClient client;
+
+    @MockBean
+    private PnfResourceCustomization pnfResourceCustomization;
+
+    @MockBean
+    private VnfResourceCustomization vnfResourceCustomization;
+
+    @MockBean
+    private ControllerSelectionReference controllerSelectionReference;
+
+    @Before
+    public void setUp() {
+        when(execution.getVariable(ACTOR_PARAM)).thenReturn(TEST_ACTOR);
+        when(execution.getVariable(ACTION_PARAM)).thenReturn(MockControllerBB.TEST_ACTION);
+
+        when(pnfResourceCustomization.getControllerActor()).thenReturn(TEST_CATALOGDB_CONTROLLER_ACTOR);
+        when(client.getPnfResourceCustomizationByModelCustomizationUUID(TEST_RESOURCE_CUSTOMIZATION_UUID))
+                .thenReturn(pnfResourceCustomization);
+
+        when(execution.getVariable(RESOURCE_TYPE_PARAM)).thenReturn(TEST_RESOURCE_TYPE);
+        when(controllerSelectionReference.getControllerName()).thenReturn(TEST_CONTROLLER_REFERENCE_ACTOR);
+        when(client.getControllerSelectionReferenceByVnfTypeAndActionCategory(TEST_RESOURCE_TYPE, TEST_ACTION))
+                .thenReturn(controllerSelectionReference);
+    }
+
+    @Test
+    public void testExecution_validInput_expectedOutput() {
+        controllerExecutionBB.execute(execution);
+        verify(execution).setVariable("stage", "ready");
+        verify(execution).setVariable("stage", "prepare");
+        verify(execution).setVariable("stage", "run");
+    }
+
+    @Test
+    public void testGetController_availableInExecutionContext_returnFromExecutionContext() {
+        String controllerActor = controllerExecutionBB.getControllerActor(execution, TEST_SCOPE, "", TEST_ACTION);
+        assertEquals(TEST_ACTOR, controllerActor);
+    }
+
+    @Test
+    public void testGetController_soRefDataInExecutionContext_returnFromControllerReference() {
+        when(execution.getVariable(ACTOR_PARAM)).thenReturn("so-ref-data");
+        String controllerActor = controllerExecutionBB.getControllerActor(execution, TEST_SCOPE, "", TEST_ACTION);
+        assertEquals(TEST_CONTROLLER_REFERENCE_ACTOR, controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContext_returnFromCatalogdb() {
+        when(execution.getVariable(ACTOR_PARAM)).thenReturn("");
+        String controllerActor = controllerExecutionBB.getControllerActor(execution, TEST_SCOPE,
+                TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+        assertEquals("The controller actor should be the same as in the catalogdb", TEST_CATALOGDB_CONTROLLER_ACTOR,
+                controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContextAndSoRefDataInCatalogdb_returnFromControllerReference() {
+        when(execution.getVariable(ACTOR_PARAM)).thenReturn("");
+        when(pnfResourceCustomization.getControllerActor()).thenReturn("SO-REF-DATA");
+        String controllerActor = controllerExecutionBB.getControllerActor(execution, TEST_SCOPE,
+                TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+        assertEquals("The controller actor should be the same as in the catalogdb", TEST_CONTROLLER_REFERENCE_ACTOR,
+                controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContextAndCatalogdb_returnFromControllerReference() {
+        when(execution.getVariable(ACTOR_PARAM)).thenReturn("");
+        when(pnfResourceCustomization.getControllerActor()).thenReturn("");
+
+        String controllerActor = controllerExecutionBB.getControllerActor(execution, TEST_SCOPE,
+                TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+        assertEquals("The controller actor should be the same as in the controller reference table",
+                TEST_CONTROLLER_REFERENCE_ACTOR, controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContextVnfType_returnFromCatalogdb() {
+        when(execution.getVariable(ACTOR_PARAM)).thenReturn("");
+
+        String expectedVnfControllerActor = "appc";
+
+        String[] controllerScopeArray = new String[] {"vnf", "vfModule"};
+
+        for (String controllerScope : controllerScopeArray) {
+
+            when(vnfResourceCustomization.getControllerActor()).thenReturn(expectedVnfControllerActor);
+            when(client.getVnfResourceCustomizationByModelCustomizationUUID(TEST_RESOURCE_CUSTOMIZATION_UUID))
+                    .thenReturn(vnfResourceCustomization);
+
+            String controllerActor = controllerExecutionBB.getControllerActor(execution, controllerScope,
+                    TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+
+            assertEquals("The controller actor should be the same as in the catalogdb for scope: " + controllerScope,
+                    expectedVnfControllerActor, controllerActor);
+        }
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBBTestIT.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBBTestIT.java
new file mode 100644
index 0000000..5eef671
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/ControllerExecutionBBTestIT.java
@@ -0,0 +1,194 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import static org.assertj.core.api.AssertionsForClassTypes.fail;
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.ArgumentMatchers.eq;
+import static org.mockito.Mockito.times;
+import static org.mockito.Mockito.verify;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.MODEL_UUID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.MSO_REQUEST_ID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PNF_CORRELATION_ID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PNF_UUID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_BLUEPRINT_NAME;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_BLUEPRINT_VERSION;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_CUSTOMIZATION_UUID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_INSTANCE_NAME;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.SERVICE_INSTANCE_ID;
+import com.google.protobuf.Struct;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Optional;
+import org.junit.Before;
+import org.junit.Ignore;
+import org.junit.Test;
+import org.onap.appc.client.lcm.model.Action;
+import org.onap.ccsdk.cds.controllerblueprints.common.api.ActionIdentifiers;
+import org.onap.ccsdk.cds.controllerblueprints.common.api.CommonHeader;
+import org.onap.ccsdk.cds.controllerblueprints.processing.api.ExecutionServiceInput;
+import org.onap.so.BaseIntegrationTest;
+import org.onap.so.GrpcNettyServer;
+import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
+import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+
+public class ControllerExecutionBBTestIT extends BaseIntegrationTest {
+
+    private Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    private ControllerExecutionBB controllerExecutionBB;
+
+    @Autowired
+    private GrpcNettyServer grpcNettyServer;
+
+    private GenericVnf genericVnf;
+
+    private static String TEST_MODEL_UUID = "6bc0b04d-1873-4721-b53d-6615225b2a28";
+    private static String TEST_SERVICE_INSTANCE_ID = "test_service_id";
+    private static String TEST_PROCESS_KEY = "processKey1";
+    private static String TEST_MSO_REQUEST_ID = "ff874603-4222-11e7-9252-005056850d2e";
+
+    private static String TEST_CDS_ACTION = "config-assign";
+    private static String TEST_APPC_ACTION = "HealthCheck";
+
+    private static String TEST_PNF_RESOURCE_INSTANCE_NAME = "PNF_demo_resource";
+    private static String TEST_PNF_CORRELATION_ID = "PNFDemo";
+    private static String TEST_PNF_RESOURCE_BLUEPRINT_NAME = "blueprintOnap";
+    private static String TEST_PNF_RESOURCE_BLUEPRINT_VERSION = "1.0.1";
+    private static String TEST_PNF_RESOURCE_CUSTOMIZATION_UUID = "9acb3a83-8a52-412c-9a45-901764938144";
+    private static String TEST_PNF_UUID = "5df8b6de-2083-11e7-93ae-92361f002671";
+
+    @Before
+    public void setUp() {
+        execution.setVariable(MODEL_UUID, TEST_MODEL_UUID);
+        execution.setVariable(SERVICE_INSTANCE_ID, TEST_SERVICE_INSTANCE_ID);
+        execution.setVariable(MSO_REQUEST_ID, TEST_MSO_REQUEST_ID);
+        execution.setVariable("testProcessKey", TEST_PROCESS_KEY);
+
+        grpcNettyServer.cleanMessage();
+    }
+
+    @Test
+    @Ignore
+    // TODO: re-activate this test case after the SO-CDS generic buildingblock implementation in place
+    public void testExecution_cdsConfigAssign_actionExecuted() {
+
+        configureCdsConfigAssign();
+
+        controllerExecutionBB.execute(execution);
+        List<ExecutionServiceInput> detailedMessages = grpcNettyServer.getDetailedMessages();
+        assertThat(detailedMessages).hasSize(1);
+        try {
+            checkConfigAssign(detailedMessages.get(0));
+        } catch (Exception e) {
+            e.printStackTrace();
+            fail("ConfigAssign request exception", e);
+        }
+    }
+
+    @Test
+    @Ignore
+    // TODO: re-activate this test case after the SDNC controller is fully implemented.
+    public void testExecution_sdncUpgradeHealthCheck_actionExecuted() {
+        configureSdncUpgrade();
+        controllerExecutionBB.execute(execution);
+
+        verify(appCClient, times(1)).runAppCCommand(eq(Action.UpgradePreCheck), eq(TEST_MSO_REQUEST_ID), eq(null),
+                any(Optional.class), any(HashMap.class), eq("sdnc"));
+    }
+
+    private void configureSdncUpgrade() {
+        execution.setVariable("actor", "sdnc");
+        execution.setVariable("action", "UpgradePreCheck");
+        execution.setVariable("payload", "{ \n" + "   \"action\":[ \n" + "      { \n"
+                + "         \"UpgradePreCheck\":{ \n" + "            \"payload\":{ \n"
+                + "               \"pnf-flag\":\"true\",\n" + "               \"pnf-name\":\"5gDU0001\",\n"
+                + "               \"pnfId\":\"5gDU0001\",\n"
+                + "               \"ipaddress-v4-oam\":\"192.168.35.83\",\n"
+                + "               \"oldSwVersion\":\"v1\",\n" + "               \"targetSwVersion\":\"v2\",\n"
+                + "               \"ruleName\":\"r001\",\n" + "               \"Id\":\"10\",\n"
+                + "               \"additionalData\":\"{}\"\n" + "            }\n" + "         }\n" + "      },\n"
+                + "      { \n" + "         \"UpgradeSoftware\":{ \n" + "            \"payload\":{ \n"
+                + "               \"pnf-flag\":\"true\",\n" + "               \"pnfId\":\"5gDU0001\",\n"
+                + "               \"ipaddress-v4-oam\":\"192.168.35.83\",\n"
+                + "               \"swToBeDownloaded\":[ \n" + "                  { \n"
+                + "                     \"swLocation\":\"http://192.168.35.96:10080/ran_du_pkg1-v2.zip\",\n"
+                + "                     \"swFileSize\":353,\n" + "                     \"swFileCompression\":\"ZIP\",\n"
+                + "                     \"swFileFormat\":\"zip\"\n" + "                  }\n" + "               ]\n"
+                + "            }\n" + "         }\n" + "      }\n" + "   ]\n" + "}");
+
+        setServiceInstance();
+        genericVnf = setGenericVnf();
+
+        RequestContext requestContext = setRequestContext();
+        requestContext.setMsoRequestId(TEST_MSO_REQUEST_ID);
+        gBBInput.setRequestContext(requestContext);
+    }
+
+    private void configureCdsConfigAssign() {
+        execution.setVariable("actor", "cds");
+        execution.setVariable("scope", "pnf");
+        execution.setVariable("action", TEST_CDS_ACTION);
+
+        execution.setVariable(PNF_CORRELATION_ID, TEST_PNF_CORRELATION_ID);
+        execution.setVariable(PNF_UUID, TEST_PNF_UUID);
+        execution.setVariable(PRC_INSTANCE_NAME, TEST_PNF_RESOURCE_INSTANCE_NAME);
+        execution.setVariable(PRC_CUSTOMIZATION_UUID, TEST_PNF_RESOURCE_CUSTOMIZATION_UUID);
+        execution.setVariable(PRC_BLUEPRINT_NAME, TEST_PNF_RESOURCE_BLUEPRINT_NAME);
+        execution.setVariable(PRC_BLUEPRINT_VERSION, TEST_PNF_RESOURCE_BLUEPRINT_VERSION);
+    }
+
+    private void checkConfigAssign(ExecutionServiceInput executionServiceInput) {
+
+        logger.info("Checking the configAssign request");
+        ActionIdentifiers actionIdentifiers = executionServiceInput.getActionIdentifiers();
+
+        /**
+         * the fields of actionIdentifiers should match the one in the
+         * response/createVcpeResCustServiceSimplifiedTest_catalogdb.json.
+         */
+        assertThat(actionIdentifiers.getBlueprintName()).isEqualTo(TEST_PNF_RESOURCE_BLUEPRINT_NAME);
+        assertThat(actionIdentifiers.getBlueprintVersion()).isEqualTo(TEST_PNF_RESOURCE_BLUEPRINT_VERSION);
+        assertThat(actionIdentifiers.getActionName()).isEqualTo(TEST_CDS_ACTION);
+        assertThat(actionIdentifiers.getMode()).isEqualTo("sync");
+
+        CommonHeader commonHeader = executionServiceInput.getCommonHeader();
+        assertThat(commonHeader.getOriginatorId()).isEqualTo("SO");
+        assertThat(commonHeader.getRequestId()).isEqualTo(TEST_MSO_REQUEST_ID);
+
+        Struct payload = executionServiceInput.getPayload();
+        Struct requeststruct = payload.getFieldsOrThrow("config-assign-request").getStructValue();
+
+        assertThat(requeststruct.getFieldsOrThrow("resolution-key").getStringValue())
+                .isEqualTo(TEST_PNF_CORRELATION_ID);
+        Struct propertiesStruct = requeststruct.getFieldsOrThrow("config-assign-properties").getStructValue();
+
+        assertThat(propertiesStruct.getFieldsOrThrow("pnf-name").getStringValue()).isEqualTo(TEST_PNF_CORRELATION_ID);
+        assertThat(propertiesStruct.getFieldsOrThrow("service-model-uuid").getStringValue()).isEqualTo(TEST_MODEL_UUID);
+        assertThat(propertiesStruct.getFieldsOrThrow("pnf-customization-uuid").getStringValue())
+                .isEqualTo(TEST_PNF_RESOURCE_CUSTOMIZATION_UUID);
+    }
+
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/MockControllerBB.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/MockControllerBB.java
new file mode 100644
index 0000000..06fd01d
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/MockControllerBB.java
@@ -0,0 +1,54 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock;
+
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.springframework.stereotype.Component;
+
+@Component
+public class MockControllerBB implements ControllerRunnable<BuildingBlockExecution> {
+
+    public static final String TEST_ACTOR = "test-controller";
+    public static final String TEST_ACTION = "configuration";
+
+    @Override
+    public Boolean understand(ControllerContext<BuildingBlockExecution> context) {
+        return context.getControllerAction().equalsIgnoreCase(TEST_ACTION)
+                && context.getControllerActor().equalsIgnoreCase(TEST_ACTOR);
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<BuildingBlockExecution> context) {
+        context.getExecution().setVariable("stage", "ready");
+        return true;
+    }
+
+    @Override
+    public void prepare(ControllerContext<BuildingBlockExecution> context) {
+        context.getExecution().setVariable("stage", "prepare");
+    }
+
+    @Override
+    public void run(ControllerContext<BuildingBlockExecution> context) {
+        context.getExecution().setVariable("stage", "run");
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/appc/AppcControllerBBTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/appc/AppcControllerBBTest.java
new file mode 100644
index 0000000..46cb818
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/appc/AppcControllerBBTest.java
@@ -0,0 +1,65 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.appc;
+
+
+import static junit.framework.TestCase.assertTrue;
+import static org.junit.Assert.assertFalse;
+import static org.mockito.Mockito.when;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {AppcControllerBB.class, ExceptionBuilder.class})
+public class AppcControllerBBTest {
+
+    @Autowired
+    private AppcControllerBB appcControllerBB;
+
+    @MockBean
+    private ControllerContext controllerContext;
+
+    @MockBean
+    protected ApplicationControllerAction client;
+
+    @Before
+    public void setUp() {
+        when(controllerContext.getControllerActor()).thenReturn("appc");
+    }
+
+    @Test
+    public void testUnderstand_validContext_TrueReturned() {
+        assertTrue(appcControllerBB.understand(controllerContext));
+    }
+
+    @Test
+    public void testUnderstand_invalidContext_FalseReturned() {
+        when(controllerContext.getControllerActor()).thenReturn("sdnc");
+        assertFalse(appcControllerBB.understand(controllerContext));
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/SdncControllerBBTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/SdncControllerBBTest.java
new file mode 100644
index 0000000..5c3b439
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/buildingblock/controller/sdnc/SdncControllerBBTest.java
@@ -0,0 +1,64 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.buildingblock.controller.sdnc;
+
+import static junit.framework.TestCase.assertTrue;
+import static org.junit.Assert.assertFalse;
+import static org.mockito.Mockito.when;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {SdncControllerBB.class, ExceptionBuilder.class})
+public class SdncControllerBBTest {
+
+    @Autowired
+    private SdncControllerBB sSdncControllerBB;
+
+    @MockBean
+    private ControllerContext controllerContext;
+
+    @MockBean
+    protected ApplicationControllerAction client;
+
+    @Before
+    public void setUp() {
+        when(controllerContext.getControllerActor()).thenReturn("sdnc");
+    }
+
+    @Test
+    public void testUnderstand_validContext_TrueReturned() {
+        assertTrue(sSdncControllerBB.understand(controllerContext));
+    }
+
+    @Test
+    public void testUnderstand_invalidContext_FalseReturned() {
+        when(controllerContext.getControllerActor()).thenReturn("cds");
+        assertFalse(sSdncControllerBB.understand(controllerContext));
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDETest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDETest.java
new file mode 100644
index 0000000..15a1a1e
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDETest.java
@@ -0,0 +1,160 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.Mockito.when;
+import static org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.MockControllerDE.TEST_ACTION;
+import static org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.MockControllerDE.TEST_ACTOR;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.camunda.bpm.extension.mockito.delegate.DelegateExecutionFake;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.db.catalog.beans.ControllerSelectionReference;
+import org.onap.so.db.catalog.beans.PnfResourceCustomization;
+import org.onap.so.db.catalog.beans.VnfResourceCustomization;
+import org.onap.so.db.catalog.client.CatalogDbClient;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {ControllerExecutionDE.class, MockControllerDE.class, ExceptionBuilder.class})
+public class ControllerExecutionDETest {
+
+    private static final String ACTOR_PARAM = "actor";
+    private static final String ACTION_PARAM = "action";
+    private static final String RESOURCE_TYPE_PARAM = "resource_type";
+
+    private static final String TEST_RESOURCE_CUSTOMIZATION_UUID = "68dc9a92-214c-11e7-93ae-92361f002680";
+    private static final String TEST_CATALOGDB_CONTROLLER_ACTOR = "cds";
+    private static final String TEST_RESOURCE_TYPE = "Firewall";
+    private static final String TEST_CONTROLLER_REFERENCE_ACTOR = "sdnc";
+    private static final String TEST_SCOPE = "pnf";
+
+    @Autowired
+    private ControllerExecutionDE controllerExecutionDE;
+
+    @MockBean
+    private CatalogDbClient client;
+
+    @MockBean
+    private PnfResourceCustomization pnfResourceCustomization;
+
+    @MockBean
+    private VnfResourceCustomization vnfResourceCustomization;
+
+    @MockBean
+    private ControllerSelectionReference controllerSelectionReference;
+
+    private DelegateExecution execution = new DelegateExecutionFake();
+
+    @Before
+    public void setUp() {
+        execution.setVariable(ACTION_PARAM, TEST_ACTION);
+        execution.setVariable(ACTOR_PARAM, TEST_ACTOR);
+
+        when(pnfResourceCustomization.getControllerActor()).thenReturn(TEST_CATALOGDB_CONTROLLER_ACTOR);
+        when(client.getPnfResourceCustomizationByModelCustomizationUUID(TEST_RESOURCE_CUSTOMIZATION_UUID))
+                .thenReturn(pnfResourceCustomization);
+
+        execution.setVariable(RESOURCE_TYPE_PARAM, TEST_RESOURCE_TYPE);
+        when(controllerSelectionReference.getControllerName()).thenReturn(TEST_CONTROLLER_REFERENCE_ACTOR);
+        when(client.getControllerSelectionReferenceByVnfTypeAndActionCategory(TEST_RESOURCE_TYPE, TEST_ACTION))
+                .thenReturn(controllerSelectionReference);
+    }
+
+    @Test
+    public void testExecution_validInput_expectedOutput() {
+        controllerExecutionDE.execute(execution);
+        assertTrue((Boolean) execution.getVariable("ready"));
+        assertTrue((Boolean) execution.getVariable("prepare"));
+        assertTrue((Boolean) execution.getVariable("run"));
+    }
+
+    @Test
+    public void testGetController_availableInExecutionContext_returnFromExecutionContext() {
+        String controllerActor = controllerExecutionDE.getControllerActor(execution, TEST_SCOPE, "", TEST_ACTION);
+        assertEquals(TEST_ACTOR, controllerActor);
+    }
+
+    @Test
+    public void testGetController_soRefDataInExecutionContext_returnFromExecutionContext() {
+        execution.setVariable(ACTOR_PARAM, "so-ref-data");
+        String controllerActor = controllerExecutionDE.getControllerActor(execution, TEST_SCOPE, "", TEST_ACTION);
+        assertEquals(TEST_CONTROLLER_REFERENCE_ACTOR, controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContext_returnFromCatalogdb() {
+        execution.setVariable(ACTOR_PARAM, "");
+        String controllerActor = controllerExecutionDE.getControllerActor(execution, TEST_SCOPE,
+                TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+        assertEquals("The controller actor should be the same as in the catalogdb", TEST_CATALOGDB_CONTROLLER_ACTOR,
+                controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContextAndSoRefDataInCatalogdb_returnFromControllerReference() {
+        execution.setVariable(ACTOR_PARAM, "");
+        when(pnfResourceCustomization.getControllerActor()).thenReturn("SO-REF-DATA");
+        String controllerActor = controllerExecutionDE.getControllerActor(execution, TEST_SCOPE,
+                TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+        assertEquals("The controller actor should be the same as in the catalogdb", TEST_CONTROLLER_REFERENCE_ACTOR,
+                controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContextAndCatalogdb_returnFromControllerReference() {
+        execution.setVariable(ACTOR_PARAM, "");
+        when(pnfResourceCustomization.getControllerActor()).thenReturn("");
+
+        String controllerActor = controllerExecutionDE.getControllerActor(execution, TEST_SCOPE,
+                TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+        assertEquals("The controller actor should be the same as in the controller reference table",
+                TEST_CONTROLLER_REFERENCE_ACTOR, controllerActor);
+    }
+
+    @Test
+    public void testGetController_notAvailableInExecutionContextVnfType_returnFromCatalogdb() {
+        execution.setVariable(ACTOR_PARAM, "");
+
+        String expectedVnfControllerActor = "appc";
+
+        String[] controllerScopeArray = new String[] {"vnf", "vfModule"};
+
+        for (String controllerScope : controllerScopeArray) {
+
+            when(vnfResourceCustomization.getControllerActor()).thenReturn(expectedVnfControllerActor);
+            when(client.getVnfResourceCustomizationByModelCustomizationUUID(TEST_RESOURCE_CUSTOMIZATION_UUID))
+                    .thenReturn(vnfResourceCustomization);
+
+            String controllerActor = controllerExecutionDE.getControllerActor(execution, controllerScope,
+                    TEST_RESOURCE_CUSTOMIZATION_UUID, TEST_ACTION);
+
+            assertEquals("The controller actor should be the same as in the catalogdb for scope: " + controllerScope,
+                    expectedVnfControllerActor, controllerActor);
+        }
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDETestIT.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDETestIT.java
new file mode 100644
index 0000000..860780a
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/ControllerExecutionDETestIT.java
@@ -0,0 +1,144 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import static org.assertj.core.api.AssertionsForClassTypes.fail;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.MODEL_UUID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.MSO_REQUEST_ID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PNF_CORRELATION_ID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PNF_UUID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_BLUEPRINT_NAME;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_BLUEPRINT_VERSION;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_CUSTOMIZATION_UUID;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.PRC_INSTANCE_NAME;
+import static org.onap.so.bpmn.infrastructure.pnf.delegate.ExecutionVariableNames.SERVICE_INSTANCE_ID;
+import com.google.protobuf.Struct;
+import java.util.List;
+import org.junit.Before;
+import org.junit.Test;
+import org.onap.ccsdk.cds.controllerblueprints.common.api.ActionIdentifiers;
+import org.onap.ccsdk.cds.controllerblueprints.common.api.CommonHeader;
+import org.onap.ccsdk.cds.controllerblueprints.processing.api.ExecutionServiceInput;
+import org.onap.so.BaseIntegrationTest;
+import org.onap.so.GrpcNettyServer;
+import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+
+public class ControllerExecutionDETestIT extends BaseIntegrationTest {
+
+    private Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    private ControllerExecutionDE controllerExecutionDE;
+
+    @Autowired
+    private GrpcNettyServer grpcNettyServer;
+
+    private GenericVnf genericVnf;
+
+    private static String TEST_MODEL_UUID = "6bc0b04d-1873-4721-b53d-6615225b2a28";
+    private static String TEST_SERVICE_INSTANCE_ID = "test_service_id";
+    private static String TEST_PROCESS_KEY = "processKey1";
+    private static String TEST_MSO_REQUEST_ID = "ff874603-4222-11e7-9252-005056850d2e";
+
+    private static String TEST_CDS_ACTION = "config-assign";
+    private static String TEST_APPC_ACTION = "HealthCheck";
+
+    private static String TEST_PNF_RESOURCE_INSTANCE_NAME = "PNF_demo_resource";
+    private static String TEST_PNF_CORRELATION_ID = "PNFDemo";
+    private static String TEST_PNF_RESOURCE_BLUEPRINT_NAME = "blueprintOnap";
+    private static String TEST_PNF_RESOURCE_BLUEPRINT_VERSION = "1.0.1";
+    private static String TEST_PNF_RESOURCE_CUSTOMIZATION_UUID = "9acb3a83-8a52-412c-9a45-901764938144";
+    private static String TEST_PNF_UUID = "5df8b6de-2083-11e7-93ae-92361f002671";
+
+    @Before
+    public void setUp() {
+        delegateExecution.setVariable(MODEL_UUID, TEST_MODEL_UUID);
+        delegateExecution.setVariable(SERVICE_INSTANCE_ID, TEST_SERVICE_INSTANCE_ID);
+        delegateExecution.setVariable(MSO_REQUEST_ID, TEST_MSO_REQUEST_ID);
+        delegateExecution.setVariable("testProcessKey", TEST_PROCESS_KEY);
+
+        grpcNettyServer.cleanMessage();
+    }
+
+    @Test
+    public void testExecution_cdsConfigAssign_actionExecuted() {
+
+        configureCdsConfigAssign();
+
+        controllerExecutionDE.execute(delegateExecution);
+        List<ExecutionServiceInput> detailedMessages = grpcNettyServer.getDetailedMessages();
+        assertThat(detailedMessages).hasSize(1);
+        try {
+            checkConfigAssign(detailedMessages.get(0));
+        } catch (Exception e) {
+            e.printStackTrace();
+            fail("ConfigAssign request exception", e);
+        }
+    }
+
+    private void configureCdsConfigAssign() {
+        delegateExecution.setVariable("actor", "cds");
+        delegateExecution.setVariable("action", TEST_CDS_ACTION);
+        delegateExecution.setVariable("scope", "pnf");
+
+        delegateExecution.setVariable(PNF_CORRELATION_ID, TEST_PNF_CORRELATION_ID);
+        delegateExecution.setVariable(PNF_UUID, TEST_PNF_UUID);
+        delegateExecution.setVariable(PRC_INSTANCE_NAME, TEST_PNF_RESOURCE_INSTANCE_NAME);
+        delegateExecution.setVariable(PRC_CUSTOMIZATION_UUID, TEST_PNF_RESOURCE_CUSTOMIZATION_UUID);
+        delegateExecution.setVariable(PRC_BLUEPRINT_NAME, TEST_PNF_RESOURCE_BLUEPRINT_NAME);
+        delegateExecution.setVariable(PRC_BLUEPRINT_VERSION, TEST_PNF_RESOURCE_BLUEPRINT_VERSION);
+    }
+
+    private void checkConfigAssign(ExecutionServiceInput executionServiceInput) {
+
+        logger.info("Checking the configAssign request");
+        ActionIdentifiers actionIdentifiers = executionServiceInput.getActionIdentifiers();
+
+        /**
+         * the fields of actionIdentifiers should match the one in the
+         * response/createVcpeResCustServiceSimplifiedTest_catalogdb.json.
+         */
+        assertThat(actionIdentifiers.getBlueprintName()).isEqualTo(TEST_PNF_RESOURCE_BLUEPRINT_NAME);
+        assertThat(actionIdentifiers.getBlueprintVersion()).isEqualTo(TEST_PNF_RESOURCE_BLUEPRINT_VERSION);
+        assertThat(actionIdentifiers.getActionName()).isEqualTo(TEST_CDS_ACTION);
+        assertThat(actionIdentifiers.getMode()).isEqualTo("sync");
+
+        CommonHeader commonHeader = executionServiceInput.getCommonHeader();
+        assertThat(commonHeader.getOriginatorId()).isEqualTo("SO");
+        assertThat(commonHeader.getRequestId()).isEqualTo(TEST_MSO_REQUEST_ID);
+
+        Struct payload = executionServiceInput.getPayload();
+        Struct requeststruct = payload.getFieldsOrThrow("config-assign-request").getStructValue();
+
+        assertThat(requeststruct.getFieldsOrThrow("resolution-key").getStringValue())
+                .isEqualTo(TEST_PNF_CORRELATION_ID);
+        Struct propertiesStruct = requeststruct.getFieldsOrThrow("config-assign-properties").getStructValue();
+
+        assertThat(propertiesStruct.getFieldsOrThrow("pnf-name").getStringValue()).isEqualTo(TEST_PNF_CORRELATION_ID);
+        assertThat(propertiesStruct.getFieldsOrThrow("service-model-uuid").getStringValue()).isEqualTo(TEST_MODEL_UUID);
+        assertThat(propertiesStruct.getFieldsOrThrow("pnf-customization-uuid").getStringValue())
+                .isEqualTo(TEST_PNF_RESOURCE_CUSTOMIZATION_UUID);
+    }
+
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/MockControllerDE.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/MockControllerDE.java
new file mode 100644
index 0000000..c66fefd
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/MockControllerDE.java
@@ -0,0 +1,55 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda;
+
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerRunnable;
+import org.springframework.stereotype.Component;
+
+@Component
+public class MockControllerDE implements ControllerRunnable<DelegateExecution> {
+
+    public static final String TEST_ACTOR = "test-controller";
+    public static final String TEST_ACTION = "configuration";
+
+    @Override
+    public Boolean understand(ControllerContext<DelegateExecution> context) {
+        return context.getControllerAction().equalsIgnoreCase(TEST_ACTION)
+                && context.getControllerActor().equalsIgnoreCase(TEST_ACTOR);
+    }
+
+    @Override
+    public Boolean ready(ControllerContext<DelegateExecution> context) {
+        context.getExecution().setVariable("ready", true);
+        return true;
+    }
+
+    @Override
+    public void prepare(ControllerContext<DelegateExecution> context) {
+        context.getExecution().setVariable("prepare", true);
+    }
+
+    @Override
+    public void run(ControllerContext<DelegateExecution> context) {
+        context.getExecution().setVariable("run", true);
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/appc/AppcControllerDETest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/appc/AppcControllerDETest.java
new file mode 100644
index 0000000..3b7a863
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/appc/AppcControllerDETest.java
@@ -0,0 +1,69 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.appc;
+
+import static junit.framework.TestCase.assertTrue;
+import static org.junit.Assert.assertFalse;
+import static org.mockito.Mockito.when;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {AppcControllerDE.class, ExceptionBuilder.class})
+public class AppcControllerDETest {
+
+    @Autowired
+    private AppcControllerDE appcControllerDE;
+
+    @MockBean
+    private ControllerContext controllerContext;
+
+    @MockBean
+    private ControllerPreparable<DelegateExecution> preparable;
+
+    @MockBean
+    protected ApplicationControllerAction client;
+
+    @Before
+    public void setUp() {
+        when(controllerContext.getControllerActor()).thenReturn("appc");
+    }
+
+    @Test
+    public void testUnderstand_validContext_TrueReturned() {
+        assertTrue(appcControllerDE.understand(controllerContext));
+    }
+
+    @Test
+    public void testUnderstand_invalidContext_FalseReturned() {
+        when(controllerContext.getControllerActor()).thenReturn("sdnc");
+        assertFalse(appcControllerDE.understand(controllerContext));
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/CdsControllerDETest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/CdsControllerDETest.java
new file mode 100644
index 0000000..79bce8a
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/cds/CdsControllerDETest.java
@@ -0,0 +1,66 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.cds;
+
+import static junit.framework.TestCase.assertTrue;
+import static org.junit.Assert.assertFalse;
+import static org.mockito.Mockito.when;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {CdsControllerDE.class, ExceptionBuilder.class})
+public class CdsControllerDETest {
+
+    @Autowired
+    private CdsControllerDE cdsControllerDE;
+
+    @MockBean
+    private ControllerContext controllerContext;
+
+    @MockBean
+    private ControllerPreparable<DelegateExecution> preparable;
+
+    @Before
+    public void setUp() {
+        when(controllerContext.getControllerActor()).thenReturn("cds");
+    }
+
+    @Test
+    public void testUnderstand_validContext_TrueReturned() {
+        assertTrue(cdsControllerDE.understand(controllerContext));
+    }
+
+    @Test
+    public void testUnderstand_invalidContext_FalseReturned() {
+        when(controllerContext.getControllerActor()).thenReturn("appc");
+        assertFalse(cdsControllerDE.understand(controllerContext));
+    }
+
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/sdnc/SdncControllerDETest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/sdnc/SdncControllerDETest.java
new file mode 100644
index 0000000..6741676
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/decisionpoint/impl/camunda/controller/sdnc/SdncControllerDETest.java
@@ -0,0 +1,69 @@
+/*-
+ * ============LICENSE_START=======================================================
+ *  Copyright (C) 2019 Nordix
+ *  ================================================================================
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *
+ *  SPDX-License-Identifier: Apache-2.0
+ *  ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.decisionpoint.impl.camunda.controller.sdnc;
+
+import static junit.framework.TestCase.assertTrue;
+import static org.junit.Assert.assertFalse;
+import static org.mockito.Mockito.when;
+import org.camunda.bpm.engine.delegate.DelegateExecution;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.ControllerContext;
+import org.onap.so.bpmn.infrastructure.decisionpoint.api.controller.ControllerPreparable;
+import org.onap.so.client.appc.ApplicationControllerAction;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.mock.mockito.MockBean;
+import org.springframework.test.context.ContextConfiguration;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+
+@RunWith(SpringJUnit4ClassRunner.class)
+@ContextConfiguration(classes = {SdncControllerDE.class, ExceptionBuilder.class})
+public class SdncControllerDETest {
+
+    @Autowired
+    private SdncControllerDE sdncControllerDE;
+
+    @MockBean
+    private ControllerContext controllerContext;
+
+    @MockBean
+    private ControllerPreparable<DelegateExecution> preparable;
+
+    @MockBean
+    protected ApplicationControllerAction client;
+
+    @Before
+    public void setUp() {
+        when(controllerContext.getControllerActor()).thenReturn("sdnc");
+    }
+
+    @Test
+    public void testUnderstand_validContext_TrueReturned() {
+        assertTrue(sdncControllerDE.understand(controllerContext));
+    }
+
+    @Test
+    public void testUnderstand_invalidContext_FalseReturned() {
+        when(controllerContext.getControllerActor()).thenReturn("cds");
+        assertFalse(sdncControllerDE.understand(controllerContext));
+    }
+}
diff --git a/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml b/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml
index fed2aa6..199274e 100644
--- a/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml
+++ b/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml
@@ -215,3 +215,9 @@
     metrics:
       enabled: false
       db-reporter-activate: false
+# CDSProcessingClient
+cds:
+  endpoint: localhost
+  port: 11012
+  auth: Basic Y2NzZGthcHBzOmNjc2RrYXBwcw==
+  timeout: 60
