From cbbe0eac48b8df6e616f56a8ef51fbc7c955d171 Mon Sep 17 00:00:00 2001 From: "Muthuramalingam, Brinda Santh(bs2796)" Date: Tue, 13 Nov 2018 16:47:33 -0500 Subject: Blueprints Processor Microservice Implement basic blueprint service logic workflow execution engine. Change-Id: Ifbbad70f2bdc4ba879b07d972083a411c7cc02f1 Issue-ID: CCSDK-672 Signed-off-by: Muthuramalingam, Brinda Santh(bs2796) --- .../modules/commons/adaptors/pom.xml | 34 --------------- .../core/api/data/BlueprintProcessorData.kt | 4 +- .../core/api/data/BlueprintProcessorException.kt | 48 ---------------------- .../core/factory/ComponentNodeFactory.kt | 2 - .../factory/ResourceAssignmentProcessorFactory.kt | 4 +- ms/blueprintsprocessor/modules/commons/pom.xml | 1 - 6 files changed, 4 insertions(+), 89 deletions(-) delete mode 100644 ms/blueprintsprocessor/modules/commons/adaptors/pom.xml delete mode 100644 ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorException.kt (limited to 'ms/blueprintsprocessor/modules/commons') diff --git a/ms/blueprintsprocessor/modules/commons/adaptors/pom.xml b/ms/blueprintsprocessor/modules/commons/adaptors/pom.xml deleted file mode 100644 index 410111b45..000000000 --- a/ms/blueprintsprocessor/modules/commons/adaptors/pom.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - 4.0.0 - - org.onap.ccsdk.apps.blueprintsprocessor - commons - 0.4.0-SNAPSHOT - - - adaptors - pom - Blueprints Processor Adaptors POM - Blueprints Processor Adaptors - - - - - diff --git a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorData.kt b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorData.kt index dc93825e9..45f684f10 100644 --- a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorData.kt +++ b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorData.kt @@ -67,7 +67,7 @@ open class ExecutionServiceOutput { @get:ApiModelProperty(required = true) lateinit var actionIdentifiers: ActionIdentifiers @get:ApiModelProperty(required = true) - lateinit var status: Status + var status: Status = Status() @get:ApiModelProperty(required = true) lateinit var payload: ObjectNode var metadata: MutableMap = hashMapOf() @@ -110,7 +110,7 @@ open class Status { @get:ApiModelProperty(required = false) var errorMessage: String? = null @get:ApiModelProperty(required = true) - lateinit var message: String + var message: String = "success" } diff --git a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorException.kt b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorException.kt deleted file mode 100644 index df4d67038..000000000 --- a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/api/data/BlueprintProcessorException.kt +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright © 2017-2018 AT&T Intellectual Property. - * - * 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. - */ - -package org.onap.ccsdk.apps.blueprintsprocessor.core.api.data - -/** - * BlueprintProcessorException - * @author Brinda Santh - * DATE : 8/15/2018 - */ -open class BlueprintProcessorException : Exception { - var code: Int = 100 - - constructor(cause: Throwable) : super(cause) - constructor(message: String) : super(message) - constructor(message: String, cause: Throwable) : super(message, cause) - constructor(cause: Throwable, message: String, vararg args: Any?) : super(String.format(message, *args), cause) - - constructor(code: Int, cause: Throwable) : super(cause) { - this.code = code - } - - constructor(code: Int, message: String) : super(message) { - this.code = code - } - - constructor(code: Int, message: String, cause: Throwable) : super(message, cause) { - this.code = code - } - - constructor(code: Int, cause: Throwable, message: String, vararg args: Any?) - : super(String.format(message, *args), cause) { - this.code = code - } -} \ No newline at end of file diff --git a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ComponentNodeFactory.kt b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ComponentNodeFactory.kt index feacbcab7..66643ee0f 100644 --- a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ComponentNodeFactory.kt +++ b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ComponentNodeFactory.kt @@ -21,7 +21,6 @@ import com.att.eelf.configuration.EELFManager import org.onap.ccsdk.apps.controllerblueprints.core.BluePrintProcessorException import org.springframework.context.ApplicationContext import org.springframework.context.ApplicationContextAware -import org.springframework.stereotype.Service /** * ComponentNode @@ -48,7 +47,6 @@ interface ComponentNode { * * @author Brinda Santh */ -@Service open class ComponentNodeFactory : ApplicationContextAware { private val log = EELFManager.getInstance().getLogger(ComponentNodeFactory::class.java) diff --git a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ResourceAssignmentProcessorFactory.kt b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ResourceAssignmentProcessorFactory.kt index 01a110d59..80ad0e677 100644 --- a/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ResourceAssignmentProcessorFactory.kt +++ b/ms/blueprintsprocessor/modules/commons/core/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/core/factory/ResourceAssignmentProcessorFactory.kt @@ -21,14 +21,14 @@ import com.att.eelf.configuration.EELFManager import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceAssignmentProcessor import org.springframework.context.ApplicationContext import org.springframework.context.ApplicationContextAware -import org.springframework.stereotype.Service +import org.springframework.context.annotation.Configuration /** * ResourceAssignmentProcessorFactory * * @author Brinda Santh */ -@Service +@Configuration open class ResourceAssignmentProcessorFactory : ApplicationContextAware { private val log = EELFManager.getInstance().getLogger(ResourceAssignmentProcessorFactory::class.java) diff --git a/ms/blueprintsprocessor/modules/commons/pom.xml b/ms/blueprintsprocessor/modules/commons/pom.xml index 299a87d6d..c080f817c 100644 --- a/ms/blueprintsprocessor/modules/commons/pom.xml +++ b/ms/blueprintsprocessor/modules/commons/pom.xml @@ -31,7 +31,6 @@ db-lib rest-lib - adaptors core -- cgit 1.2.3-korg