From 7c0570cbdcaae985c4cabec3d0fee17194a614b8 Mon Sep 17 00:00:00 2001 From: "Muthuramalingam, Brinda Santh" Date: Fri, 15 Mar 2019 12:04:07 -0400 Subject: Improve scripting component. Change-Id: I1e0c319e4117553695fa9161e7ffcd91f605be05 Issue-ID: CCSDK-1137 Signed-off-by: Muthuramalingam, Brinda Santh --- .../functions/restconf/executor/ComponentRestconfExecutor.kt | 9 --------- .../functions/restconf/executor/RestconfComponentFunction.kt | 9 ++------- 2 files changed, 2 insertions(+), 16 deletions(-) (limited to 'ms/blueprintsprocessor/functions/restconf-executor/src') diff --git a/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/ComponentRestconfExecutor.kt b/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/ComponentRestconfExecutor.kt index 742fef4b1..7166ec279 100644 --- a/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/ComponentRestconfExecutor.kt +++ b/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/ComponentRestconfExecutor.kt @@ -64,15 +64,6 @@ open class ComponentRestconfExecutor(private var componentFunctionScriptingServi checkNotNull(scriptComponent) { "failed to get restconf script component" } - scriptComponent.bluePrintRuntimeService = bluePrintRuntimeService - scriptComponent.processId = processId - scriptComponent.workflowName = workflowName - scriptComponent.stepName = stepName - scriptComponent.interfaceName = interfaceName - scriptComponent.operationName = operationName - scriptComponent.nodeTemplateName = nodeTemplateName - scriptComponent.operationInputs = operationInputs - scriptComponent.process(executionServiceInput) } diff --git a/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt b/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt index c3f2253af..1914616e8 100644 --- a/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt +++ b/ms/blueprintsprocessor/functions/restconf-executor/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/restconf/executor/RestconfComponentFunction.kt @@ -17,16 +17,15 @@ package org.onap.ccsdk.apps.blueprintsprocessor.functions.restconf.executor -import com.fasterxml.jackson.databind.JsonNode import org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.ResourceResolutionConstants import org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.ResourceResolutionService import org.onap.ccsdk.apps.blueprintsprocessor.rest.RestLibConstants import org.onap.ccsdk.apps.blueprintsprocessor.rest.service.BluePrintRestLibPropertyService import org.onap.ccsdk.apps.blueprintsprocessor.rest.service.BlueprintWebClientService -import org.onap.ccsdk.apps.blueprintsprocessor.services.execution.AbstractComponentFunction +import org.onap.ccsdk.apps.blueprintsprocessor.services.execution.AbstractScriptComponentFunction -abstract class RestconfComponentFunction : AbstractComponentFunction() { +abstract class RestconfComponentFunction : AbstractScriptComponentFunction() { open fun bluePrintRestLibPropertyService(): BluePrintRestLibPropertyService = functionDependencyInstanceAsType(RestLibConstants.SERVICE_BLUEPRINT_REST_LIB_PROPERTY) @@ -39,10 +38,6 @@ abstract class RestconfComponentFunction : AbstractComponentFunction() { return bluePrintRestLibPropertyService().blueprintWebClientService(selector) } - fun getDynamicProperties(key: String): JsonNode { - return operationInputs["dynamic-properties"]!!.get(key) - } - fun resolveFromDatabase(resolutionKey: String, artifactName: String): String { return resourceResolutionService().resolveFromDatabase(bluePrintRuntimeService, artifactName, resolutionKey) } -- cgit 1.2.3-korg