diff options
Diffstat (limited to 'ms/controllerblueprints/modules/blueprint-validation/src/main')
2 files changed, 6 insertions, 3 deletions
diff --git a/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintNodeTemplateValidatorImpl.kt b/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintNodeTemplateValidatorImpl.kt index ded1f384c..601ba4f5c 100644 --- a/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintNodeTemplateValidatorImpl.kt +++ b/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintNodeTemplateValidatorImpl.kt @@ -247,6 +247,8 @@ open class BluePrintNodeTemplateValidatorImpl(private val bluePrintTypeValidator if (BluePrintTypes.validPrimitiveTypes().contains(propertyType)) { isValid = JacksonUtils.checkJsonNodeValueOfPrimitiveType(propertyType, propertyAssignment) + } else if (BluePrintTypes.validComplexTypes().contains(propertyType)) { + isValid = true } else if (BluePrintTypes.validCollectionTypes().contains(propertyType)) { val entrySchemaType = propertyDefinition.entrySchema?.type diff --git a/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintWorkflowValidatorImpl.kt b/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintWorkflowValidatorImpl.kt index 851a7c603..519358b10 100644 --- a/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintWorkflowValidatorImpl.kt +++ b/ms/controllerblueprints/modules/blueprint-validation/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/validation/BluePrintWorkflowValidatorImpl.kt @@ -58,9 +58,10 @@ open class BluePrintWorkflowValidatorImpl(private val bluePrintTypeValidatorServ val nodeTypeDerivedFrom = bluePrintRuntimeService.bluePrintContext().nodeTemplateNodeType(it).derivedFrom - check(nodeTypeDerivedFrom == BluePrintConstants.MODEL_TYPE_NODE_DG) { - "NodeType(${nodeTemplate.type}) derived from is '$nodeTypeDerivedFrom', Expected is " + - "'${BluePrintConstants.MODEL_TYPE_NODE_DG}'" + check(nodeTypeDerivedFrom == BluePrintConstants.MODEL_TYPE_NODE_DG + || nodeTypeDerivedFrom == BluePrintConstants.MODEL_TYPE_NODE_COMPONENT) { + "NodeType(${nodeTemplate.type}) derived from is '$nodeTypeDerivedFrom', Expected " + + "'${BluePrintConstants.MODEL_TYPE_NODE_DG}' or '${BluePrintConstants.MODEL_TYPE_NODE_COMPONENT}'" } } catch (e: Exception) { bluePrintRuntimeService.getBluePrintError() |