summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSingal, Kapil (ks220y) <ks220y@att.com>2019-01-11 13:58:38 -0500
committerKAPIL SINGAL <ks220y@att.com>2019-01-11 20:39:43 +0000
commitd035fe08249fe8b1e5988b79c7355620727e5da0 (patch)
treee71cec98ba6790f5982ac124a6a06700c347e76d
parent5916e79bab772cc79765b0d8fedbc2de38e4ff4b (diff)
Resource Resolution Service : 2
Changes for Primary-DB Resource Resolution Processor Service Change-Id: Iaf6ad6277d36787d87881819ae530de1d7038a2e Issue-ID: CCSDK-942 Signed-off-by: Singal, Kapil (ks220y) <ks220y@att.com>
-rw-r--r--components/core/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/core/BluePrintConstants.kt342
-rw-r--r--components/core/src/test/resources/dictionary/dictionary_schema.json4
-rw-r--r--components/model-catalog/blueprint-model/service-blueprint/vFW/Definitions/vFW_spinup.json82
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/nf-role.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/nfc-naming-code.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/onap_private_net_cidr.json4
-rw-r--r--[-rwxr-xr-x]components/model-catalog/resource-dictionary/starter-dictionary/primary-db-source.json (renamed from components/model-catalog/resource-dictionary/starter-dictionary/db-source.json)6
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/private-prefix-id.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/protected-prefix-id.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/protected_private_net_cidr.json4
-rw-r--r--components/model-catalog/resource-dictionary/starter-dictionary/sample-primary-db-source.json (renamed from components/model-catalog/resource-dictionary/starter-dictionary/sample-db-source.json)6
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/unprotected-prefix-id.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/unprotected_private_net_cidr.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vf-module-label.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vf-module-type.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vf-naming-policy.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vf-nf-code.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vfccustomizationuuid.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vm-type.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-invariant-uuid.json4
-rwxr-xr-xcomponents/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-version.json4
-rw-r--r--components/resource-dict/load/model_type/node_type/source-primary-db.json (renamed from components/resource-dict/load/model_type/node_type/source-db.json)0
-rw-r--r--components/resource-dict/load/resource_dictionary/nf-role.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/nfc-naming-code.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/onap_private_net_cidr.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/primary-db-source.json (renamed from components/resource-dict/load/resource_dictionary/db-source.json)6
-rw-r--r--components/resource-dict/load/resource_dictionary/private-prefix-id.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/protected-prefix-id.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/protected_private_net_cidr.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/unprotected-prefix-id.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/unprotected_private_net_cidr.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vf-module-label.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vf-module-type.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vf-naming-policy.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vf-nf-code.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vfccustomizationuuid.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vm-type.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vnfc-model-invariant-uuid.json4
-rw-r--r--components/resource-dict/load/resource_dictionary/vnfc-model-version.json4
-rw-r--r--components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDictionaryConstants.kt2
-rw-r--r--components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceAssignmentUtils.kt (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/utils/ResourceResolutionUtils.kt)7
-rw-r--r--components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDefinitionTest.java4
-rw-r--r--components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/factory/ResourceSourceMappingFactoryTest.java6
-rw-r--r--components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/service/ResourceDefinitionValidationServiceTest.java4
-rw-r--r--components/resource-dict/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceDictionaryTestUtils.kt (renamed from components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceDictionaryTestUtils.kt)2
-rw-r--r--components/resource-dict/src/test/resources/validation/cyclic.json2
-rw-r--r--components/resource-dict/src/test/resources/validation/duplicate.json2
-rw-r--r--components/resource-dict/src/test/resources/validation/success.json2
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceAssignmentProcessor.kt4
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/InputResourceAssignmentProcessor.kt8
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/PrimaryDataResourceAssignmentProcessor.kt (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/DataBaseResourceAssignmentProcessor.kt)8
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentTest.kt2
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionServiceTest.kt4
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/dt-location.json (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/dt-location.json)0
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-array.json (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-array.json)4
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-complex.json (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-complex.json)2
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-simple.json (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-simple.json)2
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/resource-assignments-simple.json (renamed from ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/resource-assignments-simple.json)2
-rw-r--r--ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml72
-rw-r--r--ms/controllerblueprints/modules/service/src/test/java/org/onap/ccsdk/apps/controllerblueprints/service/repository/ResourceDictionaryReactRepositoryTest.java2
-rwxr-xr-xms/controllerblueprints/modules/service/src/test/resources/application.properties2
-rw-r--r--ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-resource-assignment.json2
-rw-r--r--ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-template.json2
-rw-r--r--ms/controllerblueprints/modules/service/src/test/resources/enhance/enhanced-template.json2
64 files changed, 361 insertions, 362 deletions
diff --git a/components/core/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/core/BluePrintConstants.kt b/components/core/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/core/BluePrintConstants.kt
index 102e2ebd..4c2d6e2f 100644
--- a/components/core/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/core/BluePrintConstants.kt
+++ b/components/core/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/core/BluePrintConstants.kt
@@ -1,172 +1,172 @@
-/*
- * Copyright © 2017-2018 AT&T Intellectual Property.
- * Modifications Copyright © 2018 IBM.
- *
- * 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.controllerblueprints.core
-
-/**
- * BluePrintConstants
- *
- * @author Brinda Santh
- */
-object BluePrintConstants {
-
- const val RESPONSE_HEADER_TRANSACTION_ID: String = "X-ONAP-RequestID"
- const val RESPONSE_HEADER_MINOR_VERSION: String = "X-MinorVersion"
- const val RESPONSE_HEADER_PATCH_VERSION: String = "X-PatchVersion"
- const val RESPONSE_HEADER_LATEST_VERSION: String = "X-LatestVersion"
-
- const val STATUS_SUCCESS: String = "success"
- const val STATUS_FAILURE: String = "failure"
-
- const val TYPE_DEFAULT: String = "default"
-
- const val DATA_TYPE_STRING: String = "string"
- const val DATA_TYPE_INTEGER: String = "integer"
- const val DATA_TYPE_FLOAT: String = "float"
- const val DATA_TYPE_BOOLEAN: String = "boolean"
- const val DATA_TYPE_TIMESTAMP: String = "timestamp"
- const val DATA_TYPE_NULL: String = "null"
- const val DATA_TYPE_LIST: String = "list"
- const val DATA_TYPE_MAP: String = "map"
-
- const val USER_SYSTEM: String = "System"
-
- const val PATH_DIVIDER: String = "/"
- const val PATH_SERVICE_TEMPLATE: String = "service_template"
- const val PATH_TOPOLOGY_TEMPLATE: String = "topology_template"
- const val PATH_METADATA: String = "metadata"
- const val PATH_NODE_TYPES: String = "node_types"
- const val PATH_POLICY_TYPES: String = "policy_types"
- const val PATH_RELATIONSHIP_TYPES: String = "relationship_types"
- const val PATH_ARTIFACT_TYPES: String = "artifact_types"
- const val PATH_DATA_TYPES: String = "data_types"
- const val PATH_INPUTS: String = "inputs"
- const val PATH_NODE_WORKFLOWS: String = "workflows"
- const val PATH_NODE_TEMPLATES: String = "node_templates"
- const val PATH_CAPABILITIES: String = "capabilities"
- const val PATH_REQUIREMENTS: String = "requirements"
- const val PATH_INTERFACES: String = "interfaces"
- const val PATH_OPERATIONS: String = "operations"
- const val PATH_OUTPUTS: String = "outputs"
- const val PATH_PROPERTIES: String = "properties"
- const val PATH_ATTRIBUTES: String = "attributes"
- const val PATH_ARTIFACTS: String = "artifacts"
-
- const val MODEL_DIR_MODEL_TYPE: String = "definition-type"
-
- const val MODEL_DEFINITION_TYPE_NODE_TYPE: String = "node_type"
- const val MODEL_DEFINITION_TYPE_ARTIFACT_TYPE: String = "artifact_type"
- const val MODEL_DEFINITION_TYPE_CAPABILITY_TYPE: String = "capability_type"
- const val MODEL_DEFINITION_TYPE_RELATIONSHIP_TYPE: String = "relationship_type"
- const val MODEL_DEFINITION_TYPE_DATA_TYPE: String = "data_type"
-
- const val MODEL_TYPE_DATATYPES_ROOT: String = "tosca.datatypes.Root"
- const val MODEL_TYPE_NODES_ROOT: String = "tosca.nodes.Root"
- const val MODEL_TYPE_GROUPS_ROOT: String = "tosca.groups.Root"
- const val MODEL_TYPE_RELATIONSHIPS_ROOT: String = "tosca.relationships.Root"
- const val MODEL_TYPE_ARTIFACTS_ROOT: String = "tosca.artifacts.Root"
- const val MODEL_TYPE_CAPABILITIES_ROOT: String = "tosca.capabilities.Root"
- const val MODEL_TYPE_INTERFACES_ROOT: String = "tosca.interfaces.Root"
-
- const val MODEL_TYPE_RELATIONSHIPS_DEPENDS_ON = "tosca.relationships.DependsOn"
- const val MODEL_TYPE_RELATIONSHIPS_HOSTED_ON = "tosca.relationships.HostedOn"
- const val MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO = "tosca.relationships.ConnectsTo"
- const val MODEL_TYPE_RELATIONSHIPS_ATTACH_TO = "tosca.relationships.AttachesTo"
- const val MODEL_TYPE_RELATIONSHIPS_ROUTES_TO = "tosca.relationships.RoutesTo"
-
- const val MODEL_TYPE_NODE_DG = "tosca.nodes.DG"
- const val MODEL_TYPE_NODE_COMPONENT = "tosca.nodes.Component"
- const val MODEL_TYPE_NODE_VNF = "tosca.nodes.Vnf"
- @Deprecated("Artifacts will be attached to Node Template")
- const val MODEL_TYPE_NODE_ARTIFACT = "tosca.nodes.Artifact"
- const val MODEL_TYPE_NODE_RESOURCE_SOURCE = "tosca.nodes.ResourceSource"
-
- const val MODEL_TYPE_NODES_COMPONENT_JAVA: String = "tosca.nodes.component.Java"
- const val MODEL_TYPE_NODES_COMPONENT_BUNDLE: String = "tosca.nodes.component.Bundle"
- const val MODEL_TYPE_NODES_COMPONENT_SCRIPT: String = "tosca.nodes.component.Script"
- const val MODEL_TYPE_NODES_COMPONENT_PYTHON: String = "tosca.nodes.component.Python"
- const val MODEL_TYPE_NODES_COMPONENT_JYTHON: String = "tosca.nodes.component.Jython"
- const val MODEL_TYPE_NODES_COMPONENT_JAVA_SCRIPT: String = "tosca.nodes.component.JavaScript"
-
- const val MODEL_TYPE_ARTIFACT_TYPE_IMPLEMENTATION = "tosca.artifacts.Implementation"
-
- const val MODEL_TYPE_DATA_TYPE_DYNAMIC = "tosca.datatypes.Dynamic"
-
- const val MODEL_TYPE_CAPABILITY_TYPE_NODE = "tosca.capabilities.Node"
- const val MODEL_TYPE_CAPABILITY_TYPE_COMPUTE = "tosca.capabilities.Compute"
- const val MODEL_TYPE_CAPABILITY_TYPE_NETWORK = "tosca.capabilities.Network"
- const val MODEL_TYPE_CAPABILITY_TYPE_STORAGE = "tosca.capabilities.Storage"
- const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT = "tosca.capabilities.Endpoint"
- const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT_PUBLIC = "tosca.capabilities.Endpoint.Public"
- const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT_ADMIN = "tosca.capabilities.Endpoint.Admin"
- const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT_DATABASE = "tosca.capabilities.Endpoint.Database"
- const val MODEL_TYPE_CAPABILITY_TYPE_ATTACHMENT = "tosca.capabilities.Attachment"
- const val MODEL_TYPE_CAPABILITY_TYPE_OPERATION_SYSTEM = "tosca.capabilities.OperatingSystem"
- const val MODEL_TYPE_CAPABILITY_TYPE_BINDABLE = "tosca.capabilities.network.Bindable"
- // Custom capabilities
- const val MODEL_TYPE_CAPABILITY_TYPE_CONTENT = "tosca.capabilities.Content"
- const val MODEL_TYPE_CAPABILITY_TYPE_MAPPING = "tosca.capabilities.Mapping"
- const val MODEL_TYPE_CAPABILITY_TYPE_NETCONF = "tosca.capabilities.Netconf"
- const val MODEL_TYPE_CAPABILITY_TYPE_SSH = "tosca.capabilities.Ssh"
- const val MODEL_TYPE_CAPABILITY_TYPE_SFTP = "tosca.capabilities.Sftp"
-
- const val EXPRESSION_GET_INPUT: String = "get_input"
- const val EXPRESSION_GET_ATTRIBUTE: String = "get_attribute"
- const val EXPRESSION_GET_ARTIFACT: String = "get_artifact"
- const val EXPRESSION_GET_PROPERTY: String = "get_property"
- const val EXPRESSION_GET_OPERATION_OUTPUT: String = "get_operation_output"
- const val EXPRESSION_GET_NODE_OF_TYPE: String = "get_nodes_of_type"
-
- const val PROPERTY_BLUEPRINT_PROCESS_ID: String = "blueprint-process-id"
- const val PROPERTY_BLUEPRINT_BASE_PATH: String = "blueprint-basePath"
- const val PROPERTY_BLUEPRINT_RUNTIME: String = "blueprint-runtime"
- const val PROPERTY_BLUEPRINT_INPUTS_DATA: String = "blueprint-inputs-data"
- const val PROPERTY_BLUEPRINT_CONTEXT: String = "blueprint-context"
- const val PROPERTY_BLUEPRINT_NAME: String = "template_name"
- const val PROPERTY_BLUEPRINT_VERSION: String = "template_version"
-
- const val TOSCA_METADATA_DIR: String = "TOSCA-Metadata"
- const val TOSCA_METADATA_ENTRY_DEFINITION_FILE: String = "TOSCA-Metadata/TOSCA.meta"
- const val TOSCA_DEFINITIONS_DIR: String = "Definitions"
- const val TOSCA_PLANS_DIR: String = "Plans"
- const val TOSCA_SCRIPTS_DIR: String = "Scripts"
- const val TOSCA_MAPPINGS_DIR: String = "Mappings"
- const val TOSCA_TEMPLATES_DIR: String = "Templates"
-
- const val METADATA_USER_GROUPS = "user-groups"
- const val METADATA_TEMPLATE_NAME = "template_name"
- const val METADATA_TEMPLATE_VERSION = "template_version"
- const val METADATA_TEMPLATE_AUTHOR = "template_author"
- const val METADATA_TEMPLATE_TAGS = "template_tags"
- const val METADATA_WORKFLOW_NAME = "workflow_name"
-
- const val PAYLOAD_DATA = "payload-data"
- const val PROPERTY_CURRENT_STEP = "current-step"
- const val PROPERTY_CURRENT_NODE_TEMPLATE = "current-node-template"
- const val PROPERTY_CURRENT_INTERFACE = "current-interface"
- const val PROPERTY_CURRENT_OPERATION = "current-operation"
- const val PROPERTY_CURRENT_IMPLEMENTATION = "current-implementation"
- const val PROPERTY_EXECUTION_REQUEST = "execution-request"
-
- const val OPERATION_PROCESS = "process"
- const val OPERATION_PREPARE = "prepare"
-
- const val BLUEPRINT_RETRIEVE_TYPE_DB = "db"
- const val BLUEPRINT_RETRIEVE_TYPE_FILE = "file"
- const val BLUEPRINT_RETRIEVE_TYPE_REPO = "repo"
-
+/*
+ * Copyright © 2017-2018 AT&T Intellectual Property.
+ * Modifications Copyright © 2018 IBM.
+ *
+ * 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.controllerblueprints.core
+
+/**
+ * BluePrintConstants
+ *
+ * @author Brinda Santh
+ */
+object BluePrintConstants {
+
+ const val RESPONSE_HEADER_TRANSACTION_ID: String = "X-ONAP-RequestID"
+ const val RESPONSE_HEADER_MINOR_VERSION: String = "X-MinorVersion"
+ const val RESPONSE_HEADER_PATCH_VERSION: String = "X-PatchVersion"
+ const val RESPONSE_HEADER_LATEST_VERSION: String = "X-LatestVersion"
+
+ const val STATUS_SUCCESS: String = "success"
+ const val STATUS_FAILURE: String = "failure"
+
+ const val TYPE_DEFAULT: String = "default"
+
+ const val DATA_TYPE_STRING: String = "string"
+ const val DATA_TYPE_INTEGER: String = "integer"
+ const val DATA_TYPE_FLOAT: String = "float"
+ const val DATA_TYPE_BOOLEAN: String = "boolean"
+ const val DATA_TYPE_TIMESTAMP: String = "timestamp"
+ const val DATA_TYPE_NULL: String = "null"
+ const val DATA_TYPE_LIST: String = "list"
+ const val DATA_TYPE_MAP: String = "map"
+
+ const val USER_SYSTEM: String = "System"
+
+ const val PATH_DIVIDER: String = "/"
+ const val PATH_SERVICE_TEMPLATE: String = "service_template"
+ const val PATH_TOPOLOGY_TEMPLATE: String = "topology_template"
+ const val PATH_METADATA: String = "metadata"
+ const val PATH_NODE_TYPES: String = "node_types"
+ const val PATH_POLICY_TYPES: String = "policy_types"
+ const val PATH_RELATIONSHIP_TYPES: String = "relationship_types"
+ const val PATH_ARTIFACT_TYPES: String = "artifact_types"
+ const val PATH_DATA_TYPES: String = "data_types"
+ const val PATH_INPUTS: String = "inputs"
+ const val PATH_NODE_WORKFLOWS: String = "workflows"
+ const val PATH_NODE_TEMPLATES: String = "node_templates"
+ const val PATH_CAPABILITIES: String = "capabilities"
+ const val PATH_REQUIREMENTS: String = "requirements"
+ const val PATH_INTERFACES: String = "interfaces"
+ const val PATH_OPERATIONS: String = "operations"
+ const val PATH_OUTPUTS: String = "outputs"
+ const val PATH_PROPERTIES: String = "properties"
+ const val PATH_ATTRIBUTES: String = "attributes"
+ const val PATH_ARTIFACTS: String = "artifacts"
+
+ const val MODEL_DIR_MODEL_TYPE: String = "definition-type"
+
+ const val MODEL_DEFINITION_TYPE_NODE_TYPE: String = "node_type"
+ const val MODEL_DEFINITION_TYPE_ARTIFACT_TYPE: String = "artifact_type"
+ const val MODEL_DEFINITION_TYPE_CAPABILITY_TYPE: String = "capability_type"
+ const val MODEL_DEFINITION_TYPE_RELATIONSHIP_TYPE: String = "relationship_type"
+ const val MODEL_DEFINITION_TYPE_DATA_TYPE: String = "data_type"
+
+ const val MODEL_TYPE_DATATYPES_ROOT: String = "tosca.datatypes.Root"
+ const val MODEL_TYPE_NODES_ROOT: String = "tosca.nodes.Root"
+ const val MODEL_TYPE_GROUPS_ROOT: String = "tosca.groups.Root"
+ const val MODEL_TYPE_RELATIONSHIPS_ROOT: String = "tosca.relationships.Root"
+ const val MODEL_TYPE_ARTIFACTS_ROOT: String = "tosca.artifacts.Root"
+ const val MODEL_TYPE_CAPABILITIES_ROOT: String = "tosca.capabilities.Root"
+ const val MODEL_TYPE_INTERFACES_ROOT: String = "tosca.interfaces.Root"
+
+ const val MODEL_TYPE_RELATIONSHIPS_DEPENDS_ON = "tosca.relationships.DependsOn"
+ const val MODEL_TYPE_RELATIONSHIPS_HOSTED_ON = "tosca.relationships.HostedOn"
+ const val MODEL_TYPE_RELATIONSHIPS_CONNECTS_TO = "tosca.relationships.ConnectsTo"
+ const val MODEL_TYPE_RELATIONSHIPS_ATTACH_TO = "tosca.relationships.AttachesTo"
+ const val MODEL_TYPE_RELATIONSHIPS_ROUTES_TO = "tosca.relationships.RoutesTo"
+
+ const val MODEL_TYPE_NODE_DG = "tosca.nodes.DG"
+ const val MODEL_TYPE_NODE_COMPONENT = "tosca.nodes.Component"
+ const val MODEL_TYPE_NODE_VNF = "tosca.nodes.Vnf"
+ @Deprecated("Artifacts will be attached to Node Template")
+ const val MODEL_TYPE_NODE_ARTIFACT = "tosca.nodes.Artifact"
+ const val MODEL_TYPE_NODE_RESOURCE_SOURCE = "tosca.nodes.ResourceSource"
+
+ const val MODEL_TYPE_NODES_COMPONENT_JAVA: String = "tosca.nodes.component.Java"
+ const val MODEL_TYPE_NODES_COMPONENT_BUNDLE: String = "tosca.nodes.component.Bundle"
+ const val MODEL_TYPE_NODES_COMPONENT_SCRIPT: String = "tosca.nodes.component.Script"
+ const val MODEL_TYPE_NODES_COMPONENT_PYTHON: String = "tosca.nodes.component.Python"
+ const val MODEL_TYPE_NODES_COMPONENT_JYTHON: String = "tosca.nodes.component.Jython"
+ const val MODEL_TYPE_NODES_COMPONENT_JAVA_SCRIPT: String = "tosca.nodes.component.JavaScript"
+
+ const val MODEL_TYPE_ARTIFACT_TYPE_IMPLEMENTATION = "tosca.artifacts.Implementation"
+
+ const val MODEL_TYPE_DATA_TYPE_DYNAMIC = "tosca.datatypes.Dynamic"
+
+ const val MODEL_TYPE_CAPABILITY_TYPE_NODE = "tosca.capabilities.Node"
+ const val MODEL_TYPE_CAPABILITY_TYPE_COMPUTE = "tosca.capabilities.Compute"
+ const val MODEL_TYPE_CAPABILITY_TYPE_NETWORK = "tosca.capabilities.Network"
+ const val MODEL_TYPE_CAPABILITY_TYPE_STORAGE = "tosca.capabilities.Storage"
+ const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT = "tosca.capabilities.Endpoint"
+ const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT_PUBLIC = "tosca.capabilities.Endpoint.Public"
+ const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT_ADMIN = "tosca.capabilities.Endpoint.Admin"
+ const val MODEL_TYPE_CAPABILITY_TYPE_ENDPOINT_DATABASE = "tosca.capabilities.Endpoint.Database"
+ const val MODEL_TYPE_CAPABILITY_TYPE_ATTACHMENT = "tosca.capabilities.Attachment"
+ const val MODEL_TYPE_CAPABILITY_TYPE_OPERATION_SYSTEM = "tosca.capabilities.OperatingSystem"
+ const val MODEL_TYPE_CAPABILITY_TYPE_BINDABLE = "tosca.capabilities.network.Bindable"
+ // Custom capabilities
+ const val MODEL_TYPE_CAPABILITY_TYPE_CONTENT = "tosca.capabilities.Content"
+ const val MODEL_TYPE_CAPABILITY_TYPE_MAPPING = "tosca.capabilities.Mapping"
+ const val MODEL_TYPE_CAPABILITY_TYPE_NETCONF = "tosca.capabilities.Netconf"
+ const val MODEL_TYPE_CAPABILITY_TYPE_SSH = "tosca.capabilities.Ssh"
+ const val MODEL_TYPE_CAPABILITY_TYPE_SFTP = "tosca.capabilities.Sftp"
+
+ const val EXPRESSION_GET_INPUT: String = "get_input"
+ const val EXPRESSION_GET_ATTRIBUTE: String = "get_attribute"
+ const val EXPRESSION_GET_ARTIFACT: String = "get_artifact"
+ const val EXPRESSION_GET_PROPERTY: String = "get_property"
+ const val EXPRESSION_GET_OPERATION_OUTPUT: String = "get_operation_output"
+ const val EXPRESSION_GET_NODE_OF_TYPE: String = "get_nodes_of_type"
+
+ const val PROPERTY_BLUEPRINT_PROCESS_ID: String = "blueprint-process-id"
+ const val PROPERTY_BLUEPRINT_BASE_PATH: String = "blueprint-basePath"
+ const val PROPERTY_BLUEPRINT_RUNTIME: String = "blueprint-runtime"
+ const val PROPERTY_BLUEPRINT_INPUTS_DATA: String = "blueprint-inputs-data"
+ const val PROPERTY_BLUEPRINT_CONTEXT: String = "blueprint-context"
+ const val PROPERTY_BLUEPRINT_NAME: String = "template_name"
+ const val PROPERTY_BLUEPRINT_VERSION: String = "template_version"
+
+ const val TOSCA_METADATA_DIR: String = "TOSCA-Metadata"
+ const val TOSCA_METADATA_ENTRY_DEFINITION_FILE: String = "TOSCA-Metadata/TOSCA.meta"
+ const val TOSCA_DEFINITIONS_DIR: String = "Definitions"
+ const val TOSCA_PLANS_DIR: String = "Plans"
+ const val TOSCA_SCRIPTS_DIR: String = "Scripts"
+ const val TOSCA_MAPPINGS_DIR: String = "Mappings"
+ const val TOSCA_TEMPLATES_DIR: String = "Templates"
+
+ const val METADATA_USER_GROUPS = "user-groups"
+ const val METADATA_TEMPLATE_NAME = "template_name"
+ const val METADATA_TEMPLATE_VERSION = "template_version"
+ const val METADATA_TEMPLATE_AUTHOR = "template_author"
+ const val METADATA_TEMPLATE_TAGS = "template_tags"
+ const val METADATA_WORKFLOW_NAME = "workflow_name"
+
+ const val PAYLOAD_DATA = "payload-data"
+ const val PROPERTY_CURRENT_STEP = "current-step"
+ const val PROPERTY_CURRENT_NODE_TEMPLATE = "current-node-template"
+ const val PROPERTY_CURRENT_INTERFACE = "current-interface"
+ const val PROPERTY_CURRENT_OPERATION = "current-operation"
+ const val PROPERTY_CURRENT_IMPLEMENTATION = "current-implementation"
+ const val PROPERTY_EXECUTION_REQUEST = "execution-request"
+
+ const val OPERATION_PROCESS = "process"
+ const val OPERATION_PREPARE = "prepare"
+
+ const val BLUEPRINT_RETRIEVE_TYPE_DB = "db"
+ const val BLUEPRINT_RETRIEVE_TYPE_FILE = "file"
+ const val BLUEPRINT_RETRIEVE_TYPE_REPO = "repo"
+
} \ No newline at end of file
diff --git a/components/core/src/test/resources/dictionary/dictionary_schema.json b/components/core/src/test/resources/dictionary/dictionary_schema.json
index d0317005..f9ef9eee 100644
--- a/components/core/src/test/resources/dictionary/dictionary_schema.json
+++ b/components/core/src/test/resources/dictionary/dictionary_schema.json
@@ -104,7 +104,7 @@
}
}
},
- "db": {
+ "primary-db": {
"type": "object",
"properties": {
"query": {
@@ -210,7 +210,7 @@
}
}
},
- "db": {
+ "primary-db": {
"type": "object",
"properties": {
"names": {
diff --git a/components/model-catalog/blueprint-model/service-blueprint/vFW/Definitions/vFW_spinup.json b/components/model-catalog/blueprint-model/service-blueprint/vFW/Definitions/vFW_spinup.json
index 1137c1d5..13847bbb 100644
--- a/components/model-catalog/blueprint-model/service-blueprint/vFW/Definitions/vFW_spinup.json
+++ b/components/model-catalog/blueprint-model/service-blueprint/vFW/Definitions/vFW_spinup.json
@@ -411,7 +411,7 @@
},
"input-param": false,
"dictionary-name": "nf-role",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vnf-model-customization-uuid"
],
@@ -531,7 +531,7 @@
},
"input-param": false,
"dictionary-name": "protected-prefix-id",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -555,7 +555,7 @@
},
"input-param": false,
"dictionary-name": "unprotected-prefix-id",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -579,7 +579,7 @@
},
"input-param": false,
"dictionary-name": "vf-nf-code",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vnf-model-customization-uuid"
],
@@ -740,7 +740,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -788,7 +788,7 @@
},
"input-param": false,
"dictionary-name": "vfccustomizationuuid",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -836,7 +836,7 @@
},
"input-param": false,
"dictionary-name": "vm-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -860,7 +860,7 @@
},
"input-param": false,
"dictionary-name": "vnfc-model-invariant-uuid",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -884,7 +884,7 @@
},
"input-param": false,
"dictionary-name": "vnfc-model-version",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -933,7 +933,7 @@
},
"input-param": false,
"dictionary-name": "nfc-naming-code",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -1107,7 +1107,7 @@
},
"input-param": false,
"dictionary-name": "unprotected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -1131,7 +1131,7 @@
},
"input-param": false,
"dictionary-name": "protected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -1205,7 +1205,7 @@
},
"input-param": false,
"dictionary-name": "onap_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -1302,7 +1302,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-label",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -1326,7 +1326,7 @@
},
"input-param": false,
"dictionary-name": "private-prefix-id",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -1535,7 +1535,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -1583,7 +1583,7 @@
},
"input-param": false,
"dictionary-name": "vfccustomizationuuid",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -1631,7 +1631,7 @@
},
"input-param": false,
"dictionary-name": "vm-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -1655,7 +1655,7 @@
},
"input-param": false,
"dictionary-name": "vnfc-model-invariant-uuid",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -1679,7 +1679,7 @@
},
"input-param": false,
"dictionary-name": "vnfc-model-version",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -1728,7 +1728,7 @@
},
"input-param": false,
"dictionary-name": "nfc-naming-code",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -1902,7 +1902,7 @@
},
"input-param": false,
"dictionary-name": "unprotected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -1926,7 +1926,7 @@
},
"input-param": false,
"dictionary-name": "onap_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -2148,7 +2148,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-label",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -2172,7 +2172,7 @@
},
"input-param": false,
"dictionary-name": "private-prefix-id",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -2357,7 +2357,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -2405,7 +2405,7 @@
},
"input-param": false,
"dictionary-name": "vfccustomizationuuid",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -2453,7 +2453,7 @@
},
"input-param": false,
"dictionary-name": "vm-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -2477,7 +2477,7 @@
},
"input-param": false,
"dictionary-name": "vnfc-model-invariant-uuid",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -2501,7 +2501,7 @@
},
"input-param": false,
"dictionary-name": "vnfc-model-version",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -2550,7 +2550,7 @@
},
"input-param": false,
"dictionary-name": "nfc-naming-code",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vfccustomizationuuid"
],
@@ -2725,7 +2725,7 @@
},
"input-param": false,
"dictionary-name": "unprotected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -2749,7 +2749,7 @@
},
"input-param": false,
"dictionary-name": "protected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -2773,7 +2773,7 @@
},
"input-param": false,
"dictionary-name": "onap_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -2946,7 +2946,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-label",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -2970,7 +2970,7 @@
},
"input-param": false,
"dictionary-name": "private-prefix-id",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -3018,7 +3018,7 @@
},
"input-param": false,
"dictionary-name": "protected-prefix-id",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -3082,7 +3082,7 @@
},
"input-param": false,
"dictionary-name": "vf-module-type",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vf-module-model-customization-uuid"
],
@@ -3226,7 +3226,7 @@
},
"input-param": false,
"dictionary-name": "nf-role",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"vnf-model-customization-uuid"
],
@@ -3275,7 +3275,7 @@
},
"input-param": false,
"dictionary-name": "unprotected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
@@ -3299,7 +3299,7 @@
},
"input-param": false,
"dictionary-name": "protected_private_net_cidr",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
],
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/nf-role.json b/components/model-catalog/resource-dictionary/starter-dictionary/nf-role.json
index 819c7e60..6da5ea22 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/nf-role.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/nf-role.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODEL.nf_role as vf_model_role from sdnctl.VF_MODEL where sdnctl.VF_MODEL.customization_uuid=:vnfmodelcustomizationuuid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/nfc-naming-code.json b/components/model-catalog/resource-dictionary/starter-dictionary/nfc-naming-code.json
index b8279187..4e1ba2b0 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/nfc-naming-code.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/nfc-naming-code.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select nfc_naming_code as nfc_naming_code from sdnctl.VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/onap_private_net_cidr.json b/components/model-catalog/resource-dictionary/starter-dictionary/onap_private_net_cidr.json
index cee06015..42765ee9 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/onap_private_net_cidr.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/onap_private_net_cidr.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix as prefix from sdnctl.IPAM_IP_POOL where description = \"private\"",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/db-source.json b/components/model-catalog/resource-dictionary/starter-dictionary/primary-db-source.json
index de46524c..26e62e85 100755..100644
--- a/components/model-catalog/resource-dictionary/starter-dictionary/db-source.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/primary-db-source.json
@@ -1,5 +1,5 @@
{
- "name": "db-source",
+ "name": "primary-db-source",
"property" :{
"description": "name of the ",
"type": "string"
@@ -7,8 +7,8 @@
"updated-by": "brindasanth@onap.com",
"tags": "bundle-id, brindasanth@onap.com",
"sources": {
- "db": {
- "type": "source-db",
+ "primary-db": {
+ "type": "source-primary-db",
"properties": {
"query": "SELECT db-country, db-state FROM DEVICE_PROFILE WHERE profile_name = :profile_name",
"input-key-mapping": {
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/private-prefix-id.json b/components/model-catalog/resource-dictionary/starter-dictionary/private-prefix-id.json
index 5dea3e31..0685401d 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/private-prefix-id.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/private-prefix-id.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix_id as prefix_id from sdnctl.IPAM_IP_POOL where description = \"private\"",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/protected-prefix-id.json b/components/model-catalog/resource-dictionary/starter-dictionary/protected-prefix-id.json
index fb572741..f6120f3f 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/protected-prefix-id.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/protected-prefix-id.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix_id as prefix_id from sdnctl.IPAM_IP_POOL where description = \"protected\"",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/protected_private_net_cidr.json b/components/model-catalog/resource-dictionary/starter-dictionary/protected_private_net_cidr.json
index 261920fe..bb477dcb 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/protected_private_net_cidr.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/protected_private_net_cidr.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix as prefix from sdnctl.IPAM_IP_POOL where description = \"protected\"",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/sample-db-source.json b/components/model-catalog/resource-dictionary/starter-dictionary/sample-primary-db-source.json
index 90775aee..656841f2 100644
--- a/components/model-catalog/resource-dictionary/starter-dictionary/sample-db-source.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/sample-primary-db-source.json
@@ -5,10 +5,10 @@
"type": "string"
},
"updated-by": "brindasanth@onap.com",
- "tags": "db-source, brindasanth@onap.com",
+ "tags": "primary-db-source, brindasanth@onap.com",
"sources": {
- "db": {
- "type": "source-db",
+ "primary-db": {
+ "type": "source-primary-db",
"properties": {
"query": "SELECT db-country, db-state FROM DEVICE_PROFILE WHERE profile_name = :profile_name",
"input-key-mapping": {
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/unprotected-prefix-id.json b/components/model-catalog/resource-dictionary/starter-dictionary/unprotected-prefix-id.json
index 3cb73205..c1fc541b 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/unprotected-prefix-id.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/unprotected-prefix-id.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix_id as prefix_id from sdnctl.IPAM_IP_POOL where description = \"unprotected\"",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/unprotected_private_net_cidr.json b/components/model-catalog/resource-dictionary/starter-dictionary/unprotected_private_net_cidr.json
index d2a339e7..60487550 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/unprotected_private_net_cidr.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/unprotected_private_net_cidr.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix as prefix from sdnctl.IPAM_IP_POOL where description = \"unprotected\"",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-label.json b/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-label.json
index ac5e21a6..faa7ea49 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-label.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-label.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODULE_MODEL.vf_module_label as vf_module_label from sdnctl.VF_MODULE_MODEL where sdnctl.VF_MODULE_MODEL.customization_uuid=:customizationid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-type.json b/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-type.json
index 147425c3..dbd51bbd 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-type.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vf-module-type.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select vf_module_type as vf_module_type from sdnctl.VF_MODULE_MODEL where customization_uuid=:customizationid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vf-naming-policy.json b/components/model-catalog/resource-dictionary/starter-dictionary/vf-naming-policy.json
index f68cc374..70792f86 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vf-naming-policy.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vf-naming-policy.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODEL.naming_policy as vf_naming_policy from sdnctl.VF_MODEL where sdnctl.VF_MODEL.customization_uuid=:vnf_model_customization_uuid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vf-nf-code.json b/components/model-catalog/resource-dictionary/starter-dictionary/vf-nf-code.json
index 1865d47f..a21982c0 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vf-nf-code.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vf-nf-code.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODEL.nf_code as vf_nf_code from sdnctl.VF_MODEL where sdnctl.VF_MODEL.customization_uuid=:customizationid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vfccustomizationuuid.json b/components/model-catalog/resource-dictionary/starter-dictionary/vfccustomizationuuid.json
index 463f8480..9f3e7cf1 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vfccustomizationuuid.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vfccustomizationuuid.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODULE_TO_VFC_MAPPING.vfc_customization_uuid as vnf_customid from sdnctl.VF_MODULE_TO_VFC_MAPPING where vm_count = 1 and sdnctl.VF_MODULE_TO_VFC_MAPPING.vf_module_customization_uuid=:vfmodulecustomizationuuid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vm-type.json b/components/model-catalog/resource-dictionary/starter-dictionary/vm-type.json
index 0204c64b..9744316c 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vm-type.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vm-type.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select VFC_MODEL.vm_type as vm_type from VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-invariant-uuid.json b/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-invariant-uuid.json
index c894fb53..3d89d9dd 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-invariant-uuid.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-invariant-uuid.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select VFC_MODEL.invariant_uuid as vfc_invariant_uuid from VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-version.json b/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-version.json
index 45eb07f7..d7fb5016 100755
--- a/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-version.json
+++ b/components/model-catalog/resource-dictionary/starter-dictionary/vnfc-model-version.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select VFC_MODEL.version as vnfc_model_version from VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/resource-dict/load/model_type/node_type/source-db.json b/components/resource-dict/load/model_type/node_type/source-primary-db.json
index 661a9503..661a9503 100644
--- a/components/resource-dict/load/model_type/node_type/source-db.json
+++ b/components/resource-dict/load/model_type/node_type/source-primary-db.json
diff --git a/components/resource-dict/load/resource_dictionary/nf-role.json b/components/resource-dict/load/resource_dictionary/nf-role.json
index 0e108c5c..df6b5df4 100644
--- a/components/resource-dict/load/resource_dictionary/nf-role.json
+++ b/components/resource-dict/load/resource_dictionary/nf-role.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODEL.nf_role as vf_model_role from sdnctl.VF_MODEL where sdnctl.VF_MODEL.customization_uuid=:vnfmodelcustomizationuuid",
diff --git a/components/resource-dict/load/resource_dictionary/nfc-naming-code.json b/components/resource-dict/load/resource_dictionary/nfc-naming-code.json
index f0f2b7f0..7c521a7c 100644
--- a/components/resource-dict/load/resource_dictionary/nfc-naming-code.json
+++ b/components/resource-dict/load/resource_dictionary/nfc-naming-code.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select nfc_naming_code as nfc_naming_code from sdnctl.VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/resource-dict/load/resource_dictionary/onap_private_net_cidr.json b/components/resource-dict/load/resource_dictionary/onap_private_net_cidr.json
index 07c5cbc1..f2067a19 100644
--- a/components/resource-dict/load/resource_dictionary/onap_private_net_cidr.json
+++ b/components/resource-dict/load/resource_dictionary/onap_private_net_cidr.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix as prefix from sdnctl.IPAM_IP_POOL where description = private",
diff --git a/components/resource-dict/load/resource_dictionary/db-source.json b/components/resource-dict/load/resource_dictionary/primary-db-source.json
index b96dc63f..dfac66ae 100644
--- a/components/resource-dict/load/resource_dictionary/db-source.json
+++ b/components/resource-dict/load/resource_dictionary/primary-db-source.json
@@ -1,5 +1,5 @@
{
- "name": "db-source",
+ "name": "primary-db-source",
"property" :{
"description": "name of the ",
"type": "string"
@@ -7,8 +7,8 @@
"updated-by": "brindasanth@onap.com",
"tags": "bundle-id, brindasanth@onap.com",
"sources": {
- "db": {
- "type": "source-db",
+ "primary-db": {
+ "type": "source-primary-db",
"properties": {
"query": "SELECT db-country, db-state FROM DEVICE_PROFILE WHERE profile_name = :profile_name",
"input-key-mapping": {
diff --git a/components/resource-dict/load/resource_dictionary/private-prefix-id.json b/components/resource-dict/load/resource_dictionary/private-prefix-id.json
index a95bae30..309647d7 100644
--- a/components/resource-dict/load/resource_dictionary/private-prefix-id.json
+++ b/components/resource-dict/load/resource_dictionary/private-prefix-id.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix_id as prefix_id from sdnctl.IPAM_IP_POOL where description = private",
diff --git a/components/resource-dict/load/resource_dictionary/protected-prefix-id.json b/components/resource-dict/load/resource_dictionary/protected-prefix-id.json
index 56b0d6d2..816405b4 100644
--- a/components/resource-dict/load/resource_dictionary/protected-prefix-id.json
+++ b/components/resource-dict/load/resource_dictionary/protected-prefix-id.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix_id as prefix_id from sdnctl.IPAM_IP_POOL where description = protected",
diff --git a/components/resource-dict/load/resource_dictionary/protected_private_net_cidr.json b/components/resource-dict/load/resource_dictionary/protected_private_net_cidr.json
index db0a43dc..bf46fb3a 100644
--- a/components/resource-dict/load/resource_dictionary/protected_private_net_cidr.json
+++ b/components/resource-dict/load/resource_dictionary/protected_private_net_cidr.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix as prefix from sdnctl.IPAM_IP_POOL where description = protected",
diff --git a/components/resource-dict/load/resource_dictionary/unprotected-prefix-id.json b/components/resource-dict/load/resource_dictionary/unprotected-prefix-id.json
index a0d966a2..8a09b149 100644
--- a/components/resource-dict/load/resource_dictionary/unprotected-prefix-id.json
+++ b/components/resource-dict/load/resource_dictionary/unprotected-prefix-id.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix_id as prefix_id from sdnctl.IPAM_IP_POOL where description = unprotected",
diff --git a/components/resource-dict/load/resource_dictionary/unprotected_private_net_cidr.json b/components/resource-dict/load/resource_dictionary/unprotected_private_net_cidr.json
index 8f9385d8..241147c3 100644
--- a/components/resource-dict/load/resource_dictionary/unprotected_private_net_cidr.json
+++ b/components/resource-dict/load/resource_dictionary/unprotected_private_net_cidr.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.IPAM_IP_POOL.prefix as prefix from sdnctl.IPAM_IP_POOL where description = unprotected",
diff --git a/components/resource-dict/load/resource_dictionary/vf-module-label.json b/components/resource-dict/load/resource_dictionary/vf-module-label.json
index a9543722..01355c20 100644
--- a/components/resource-dict/load/resource_dictionary/vf-module-label.json
+++ b/components/resource-dict/load/resource_dictionary/vf-module-label.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODULE_MODEL.vf_module_label as vf_module_label from sdnctl.VF_MODULE_MODEL where sdnctl.VF_MODULE_MODEL.customization_uuid=:customizationid",
diff --git a/components/resource-dict/load/resource_dictionary/vf-module-type.json b/components/resource-dict/load/resource_dictionary/vf-module-type.json
index 805d834b..ead69d46 100644
--- a/components/resource-dict/load/resource_dictionary/vf-module-type.json
+++ b/components/resource-dict/load/resource_dictionary/vf-module-type.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select vf_module_type as vf_module_type from sdnctl.VF_MODULE_MODEL where customization_uuid=:customizationid",
diff --git a/components/resource-dict/load/resource_dictionary/vf-naming-policy.json b/components/resource-dict/load/resource_dictionary/vf-naming-policy.json
index ceed3186..cde861f8 100644
--- a/components/resource-dict/load/resource_dictionary/vf-naming-policy.json
+++ b/components/resource-dict/load/resource_dictionary/vf-naming-policy.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODEL.naming_policy as vf_naming_policy from sdnctl.VF_MODEL where sdnctl.VF_MODEL.customization_uuid=:vnf_model_customization_uuid",
diff --git a/components/resource-dict/load/resource_dictionary/vf-nf-code.json b/components/resource-dict/load/resource_dictionary/vf-nf-code.json
index 0d25d0e9..adbd22af 100644
--- a/components/resource-dict/load/resource_dictionary/vf-nf-code.json
+++ b/components/resource-dict/load/resource_dictionary/vf-nf-code.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODEL.nf_code as vf_nf_code from sdnctl.VF_MODEL where sdnctl.VF_MODEL.customization_uuid=:customizationid",
diff --git a/components/resource-dict/load/resource_dictionary/vfccustomizationuuid.json b/components/resource-dict/load/resource_dictionary/vfccustomizationuuid.json
index a34a9a78..b3485791 100644
--- a/components/resource-dict/load/resource_dictionary/vfccustomizationuuid.json
+++ b/components/resource-dict/load/resource_dictionary/vfccustomizationuuid.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select sdnctl.VF_MODULE_TO_VFC_MAPPING.vfc_customization_uuid as vnf_customid from sdnctl.VF_MODULE_TO_VFC_MAPPING where vm_count = 1 and sdnctl.VF_MODULE_TO_VFC_MAPPING.vf_module_customization_uuid=:vfmodulecustomizationuuid",
diff --git a/components/resource-dict/load/resource_dictionary/vm-type.json b/components/resource-dict/load/resource_dictionary/vm-type.json
index 7bb5ef1c..e559f9b5 100644
--- a/components/resource-dict/load/resource_dictionary/vm-type.json
+++ b/components/resource-dict/load/resource_dictionary/vm-type.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select vfc_model.vm_type as vm_type from VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/resource-dict/load/resource_dictionary/vnfc-model-invariant-uuid.json b/components/resource-dict/load/resource_dictionary/vnfc-model-invariant-uuid.json
index b2ccd45d..9eb94cff 100644
--- a/components/resource-dict/load/resource_dictionary/vnfc-model-invariant-uuid.json
+++ b/components/resource-dict/load/resource_dictionary/vnfc-model-invariant-uuid.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select vfc_model.invariant_uuid as vfc_invariant_uuid from VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/resource-dict/load/resource_dictionary/vnfc-model-version.json b/components/resource-dict/load/resource_dictionary/vnfc-model-version.json
index fb59eea7..e4e66229 100644
--- a/components/resource-dict/load/resource_dictionary/vnfc-model-version.json
+++ b/components/resource-dict/load/resource_dictionary/vnfc-model-version.json
@@ -7,8 +7,8 @@
"type" : "string"
},
"sources" : {
- "db" : {
- "type" : "source-db",
+ "primary-db" : {
+ "type" : "source-primary-db",
"properties" : {
"type" : "SQL",
"query" : "select vfc_model.version as vnfc_model_version from VFC_MODEL where customization_uuid=:vfccustomizationuuid",
diff --git a/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDictionaryConstants.kt b/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDictionaryConstants.kt
index a39139ed..e4219c13 100644
--- a/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDictionaryConstants.kt
+++ b/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDictionaryConstants.kt
@@ -23,7 +23,7 @@ package org.onap.ccsdk.apps.controllerblueprints.resource.dict
object ResourceDictionaryConstants {
const val SOURCE_INPUT = "input"
const val SOURCE_DEFAULT = "default"
- const val SOURCE_DB = "db"
+ const val SOURCE_DB = "primary-db"
const val MODEL_DIR_RESOURCE_DEFINITION: String = "resource_dictionary"
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/utils/ResourceResolutionUtils.kt b/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceAssignmentUtils.kt
index 7c590883..a234a89e 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/utils/ResourceResolutionUtils.kt
+++ b/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceAssignmentUtils.kt
@@ -14,10 +14,9 @@
* limitations under the License.
*/
-package org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.utils
+package org.onap.ccsdk.apps.controllerblueprints.resource.dict.utils
import java.util.Date
-import org.apache.commons.lang3.StringUtils
import com.att.eelf.configuration.EELFLogger
import com.att.eelf.configuration.EELFManager
import com.fasterxml.jackson.databind.JsonNode
@@ -28,10 +27,10 @@ import org.onap.ccsdk.apps.controllerblueprints.core.*
import org.onap.ccsdk.apps.controllerblueprints.core.utils.JacksonUtils
import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceAssignment
-class ResourceResolutionUtils {
+class ResourceAssignmentUtils {
companion object {
- private val logger: EELFLogger = EELFManager.getInstance().getLogger(ResourceResolutionUtils::class.toString())
+ private val logger: EELFLogger = EELFManager.getInstance().getLogger(ResourceAssignmentUtils::class.toString())
@Synchronized
@Throws(BluePrintProcessorException::class)
diff --git a/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDefinitionTest.java b/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDefinitionTest.java
index cb39200f..1ed306e2 100644
--- a/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDefinitionTest.java
+++ b/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/ResourceDefinitionTest.java
@@ -46,9 +46,9 @@ public class ResourceDefinitionTest {
@Test
public void testDictionaryDefinitionDBSource(){
- String fileName = basePath + "/db-source.json";
+ String fileName = basePath + "/primary-db-source.json";
ResourceDefinition resourceDefinition = JacksonUtils.Companion.readValueFromFile(fileName, ResourceDefinition.class);
- Assert.assertNotNull("Failed to populate dictionaryDefinition for db type", resourceDefinition);
+ Assert.assertNotNull("Failed to populate dictionaryDefinition for primary-db type", resourceDefinition);
}
@Test
diff --git a/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/factory/ResourceSourceMappingFactoryTest.java b/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/factory/ResourceSourceMappingFactoryTest.java
index b67aa799..3f5aef43 100644
--- a/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/factory/ResourceSourceMappingFactoryTest.java
+++ b/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/factory/ResourceSourceMappingFactoryTest.java
@@ -25,13 +25,13 @@ public class ResourceSourceMappingFactoryTest {
@Test
public void testRegisterResourceMapping() {
- ResourceSourceMappingFactory.INSTANCE.registerSourceMapping("db", "source-db");
+ ResourceSourceMappingFactory.INSTANCE.registerSourceMapping("primary-db", "source-primary-db");
ResourceSourceMappingFactory.INSTANCE.registerSourceMapping("input", "source-input");
ResourceSourceMappingFactory.INSTANCE.registerSourceMapping("default", "source-default");
ResourceSourceMappingFactory.INSTANCE.registerSourceMapping("mdsal", "source-rest");
- String nodeTypeName = ResourceSourceMappingFactory.INSTANCE.getRegisterSourceMapping("db");
- Assert.notNull(nodeTypeName, "Failed to get db mapping");
+ String nodeTypeName = ResourceSourceMappingFactory.INSTANCE.getRegisterSourceMapping("primary-db");
+ Assert.notNull(nodeTypeName, "Failed to get primary-db mapping");
ResourceSourceMapping resourceSourceMapping = ResourceSourceMappingFactory.INSTANCE.getRegisterSourceMapping();
Assert.notNull(resourceSourceMapping, "Failed to get resource source mapping");
diff --git a/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/service/ResourceDefinitionValidationServiceTest.java b/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/service/ResourceDefinitionValidationServiceTest.java
index f5c3567f..7f040b2e 100644
--- a/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/service/ResourceDefinitionValidationServiceTest.java
+++ b/components/resource-dict/src/test/java/org/onap/ccsdk/apps/controllerblueprints/resource/dict/service/ResourceDefinitionValidationServiceTest.java
@@ -30,10 +30,10 @@ public class ResourceDefinitionValidationServiceTest {
@Test
public void testValidateSource() throws Exception {
- String inputFileName = dictionaryPath + "/db-source.json";
+ String inputFileName = dictionaryPath + "/input-source.json";
testValidate(inputFileName);
- String dbFileName = dictionaryPath + "/db-source.json";
+ String dbFileName = dictionaryPath + "/primary-db-source.json";
testValidate(dbFileName);
String defaultFileName = dictionaryPath + "/default-source.json";
diff --git a/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceDictionaryTestUtils.kt b/components/resource-dict/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceDictionaryTestUtils.kt
index bebe27d8..50e5c329 100644
--- a/components/resource-dict/src/main/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceDictionaryTestUtils.kt
+++ b/components/resource-dict/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/resource/dict/utils/ResourceDictionaryTestUtils.kt
@@ -22,7 +22,7 @@ object ResourceDictionaryTestUtils {
@JvmStatic
fun setUpResourceSourceMapping() {
- ResourceSourceMappingFactory.registerSourceMapping("db", "source-db")
+ ResourceSourceMappingFactory.registerSourceMapping("primary-db", "source-primary-db")
ResourceSourceMappingFactory.registerSourceMapping("input", "source-input")
ResourceSourceMappingFactory.registerSourceMapping("default", "source-default")
ResourceSourceMappingFactory.registerSourceMapping("mdsal", "source-rest")
diff --git a/components/resource-dict/src/test/resources/validation/cyclic.json b/components/resource-dict/src/test/resources/validation/cyclic.json
index d837dc5d..7e6472f5 100644
--- a/components/resource-dict/src/test/resources/validation/cyclic.json
+++ b/components/resource-dict/src/test/resources/validation/cyclic.json
@@ -102,7 +102,7 @@
"type": "string"
},
"dictionary-name": "loopback-ip",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"bundle-mac",
"managed-ip1"
diff --git a/components/resource-dict/src/test/resources/validation/duplicate.json b/components/resource-dict/src/test/resources/validation/duplicate.json
index 330324cd..28ab71fc 100644
--- a/components/resource-dict/src/test/resources/validation/duplicate.json
+++ b/components/resource-dict/src/test/resources/validation/duplicate.json
@@ -102,7 +102,7 @@
"type": "string"
},
"dictionary-name": "loopback-ip",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"bundle-mac"
]
diff --git a/components/resource-dict/src/test/resources/validation/success.json b/components/resource-dict/src/test/resources/validation/success.json
index 3215d06d..5d0e8980 100644
--- a/components/resource-dict/src/test/resources/validation/success.json
+++ b/components/resource-dict/src/test/resources/validation/success.json
@@ -102,7 +102,7 @@
"type": "string"
},
"dictionary-name": "loopback-ip",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"bundle-mac"
]
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceAssignmentProcessor.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceAssignmentProcessor.kt
index f1de8f7d..a6c8a3f9 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceAssignmentProcessor.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/CapabilityResourceAssignmentProcessor.kt
@@ -17,9 +17,9 @@
package org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.processor
import org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.CapabilityResourceSource
-import org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.utils.ResourceResolutionUtils
import org.onap.ccsdk.apps.controllerblueprints.core.BluePrintProcessorException
import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceAssignment
+import org.onap.ccsdk.apps.controllerblueprints.resource.dict.utils.ResourceAssignmentUtils
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.context.ApplicationContext
import org.springframework.stereotype.Service
@@ -49,7 +49,7 @@ open class CapabilityResourceAssignmentProcessor : ResourceAssignmentProcessor()
checkNotNull(resourceSource.properties) { "failed to get ${executionRequest.dictionarySource} properties" }
- val capabilityResourceSourceProperty = ResourceResolutionUtils.transformResourceSource(resourceSource.properties!!, CapabilityResourceSource::class.java)
+ val capabilityResourceSourceProperty = ResourceAssignmentUtils.transformResourceSource(resourceSource.properties!!, CapabilityResourceSource::class.java)
val instanceType = capabilityResourceSourceProperty.type
val instanceName = capabilityResourceSourceProperty.instanceName
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/InputResourceAssignmentProcessor.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/InputResourceAssignmentProcessor.kt
index ccf3aee1..bd9c188a 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/InputResourceAssignmentProcessor.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/InputResourceAssignmentProcessor.kt
@@ -17,11 +17,11 @@
package org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.processor
-import org.onap.ccsdk.apps.blueprintsprocessor.functions.resource.resolution.utils.ResourceResolutionUtils
import org.onap.ccsdk.apps.controllerblueprints.core.*
import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceAssignment
import org.springframework.stereotype.Service
import com.fasterxml.jackson.databind.node.NullNode
+import org.onap.ccsdk.apps.controllerblueprints.resource.dict.utils.ResourceAssignmentUtils
/**
* InputResourceAssignmentProcessor
@@ -41,13 +41,13 @@ open class InputResourceAssignmentProcessor : ResourceAssignmentProcessor() {
val value = bluePrintRuntimeService!!.getInputValue(executionRequest.name)
// if value is null don't call setResourceDataValue to populate the value
if (value != null && value !is NullNode) {
- ResourceResolutionUtils.setResourceDataValue(executionRequest, value)
+ ResourceAssignmentUtils.setResourceDataValue(executionRequest, value)
}
}
// Check the value has populated for mandatory case
- ResourceResolutionUtils.assertTemplateKeyValueNotNull(executionRequest)
+ ResourceAssignmentUtils.assertTemplateKeyValueNotNull(executionRequest)
} catch (e: Exception) {
- ResourceResolutionUtils.setFailedResourceDataValue(executionRequest, e.message)
+ ResourceAssignmentUtils.setFailedResourceDataValue(executionRequest, e.message)
throw BluePrintProcessorException("Failed in template key ($executionRequest) assignments with : (${e.message})", e)
}
}
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/DataBaseResourceAssignmentProcessor.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/PrimaryDataResourceAssignmentProcessor.kt
index da77c273..ec98d09e 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/DataBaseResourceAssignmentProcessor.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/main/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/processor/PrimaryDataResourceAssignmentProcessor.kt
@@ -21,15 +21,15 @@ import org.onap.ccsdk.apps.controllerblueprints.resource.dict.ResourceAssignment
import org.springframework.stereotype.Service
/**
- * DataBaseResourceAssignmentProcessor
+ * PrimaryDataResourceAssignmentProcessor
*
* @author Brinda Santh
*/
-@Service("resource-assignment-processor-db")
-open class DataBaseResourceAssignmentProcessor : ResourceAssignmentProcessor(){
+@Service("resource-assignment-processor-primary-db")
+open class PrimaryDataResourceAssignmentProcessor : ResourceAssignmentProcessor(){
override fun getName(): String {
- return "resource-assignment-processor-db"
+ return "resource-assignment-processor-primary-db"
}
override fun process(executionRequest: ResourceAssignment) {
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentTest.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentTest.kt
index ef849605..8adde863 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentTest.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionComponentTest.kt
@@ -34,7 +34,7 @@ import org.springframework.test.context.junit4.SpringRunner
@RunWith(SpringRunner::class)
@ContextConfiguration(classes = [ResourceResolutionComponent::class, ResourceResolutionService::class,
InputResourceAssignmentProcessor::class, DefaultResourceAssignmentProcessor::class,
- DataBaseResourceAssignmentProcessor::class, SimpleRestResourceAssignmentProcessor::class,
+ PrimaryDataResourceAssignmentProcessor::class, SimpleRestResourceAssignmentProcessor::class,
CapabilityResourceAssignmentProcessor::class])
class ResourceResolutionComponentTest {
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionServiceTest.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionServiceTest.kt
index 46ccb974..6c686753 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionServiceTest.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/apps/blueprintsprocessor/functions/resource/resolution/ResourceResolutionServiceTest.kt
@@ -39,7 +39,7 @@ import kotlin.test.assertTrue
@RunWith(SpringRunner::class)
@ContextConfiguration(classes = [ResourceResolutionService::class,
InputResourceAssignmentProcessor::class, DefaultResourceAssignmentProcessor::class,
- DataBaseResourceAssignmentProcessor::class, SimpleRestResourceAssignmentProcessor::class,
+ PrimaryDataResourceAssignmentProcessor::class, SimpleRestResourceAssignmentProcessor::class,
CapabilityResourceAssignmentProcessor::class])
class ResourceResolutionServiceTest {
@@ -53,7 +53,7 @@ class ResourceResolutionServiceTest {
fun testRegisteredSource() {
val sources = resourceResolutionService.registeredResourceSources()
assertNotNull(sources, "failed to get registered sources")
- assertTrue(sources.containsAll(arrayListOf("input", "default", "db", "mdsal")), "failed to get registered sources")
+ assertTrue(sources.containsAll(arrayListOf("input", "default", "primary-db", "mdsal")), "failed to get registered sources")
}
@Test
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/dt-location.json b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/dt-location.json
index 52e0a796..52e0a796 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/dt-location.json
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/dt-location.json
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-array.json b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-array.json
index 679b92db..7082a434 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-array.json
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-array.json
@@ -4,7 +4,7 @@
"data-type": "list",
"entry-schema": "dt-location",
"source": {
- "db": {
+ "primary-db": {
"query": "SELECT db-country, db-state FROM DEVICE_PROFILE WHERE profile_name = :profile_name",
"input-key-mapping": {
"profile_name": "profile_name"
@@ -16,7 +16,7 @@
}
},
"candidate-dependency": {
- "db": {
+ "primary-db": {
"names": [
"profile_name"
]
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-complex.json b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-complex.json
index 32d04b69..53e2a11c 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-complex.json
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-complex.json
@@ -3,7 +3,7 @@
"name": "location",
"data-type": "dt-location",
"source": {
- "db": {
+ "primary-db": {
"query": "SELECT db-country, db-state FROM DEVICE_PROFILE WHERE profile_name = :profile_name",
"input-key-mapping": {
"profile_name": "profile_name"
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-simple.json b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-simple.json
index 841404f2..fad08887 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/db-simple.json
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/primary-db-simple.json
@@ -3,7 +3,7 @@
"name": "country",
"data-type": "string",
"source": {
- "db": {
+ "primary-db": {
"query": "SELECT country FROM DEVICE_PROFILE WHERE profile_name = :profile_name",
"input-key-mapping": {
"profile_name": "profile_name"
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/resource-assignments-simple.json b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/resource-assignments-simple.json
index ddcf32ee..bb392d7b 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/db/resource-assignments-simple.json
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/resources/mapping/primary-db/resource-assignments-simple.json
@@ -6,7 +6,7 @@
"type": "string"
},
"dictionary-name": "country",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": ["state"]
},
{
diff --git a/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml b/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml
index dd219084..eae24703 100644
--- a/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml
+++ b/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml
@@ -1,37 +1,37 @@
-version: '3.3'
-
-services:
- db:
- image: mariadb:latest
- container_name: cb-mariadb
- ports:
- - "3306:3306"
- volumes:
- - ~/vm_mysql:/var/lib/mysql
- restart: always
- environment:
- MYSQL_ROOT_PASSWORD: sdnctl
- MYSQL_DATABASE: sdnctl
- MYSQL_USER: sdnctl
- MYSQL_PASSWORD: sdnctl
- controller-blueprints:
- depends_on:
- - db
- image: onap/ccsdk-controllerblueprints:latest
- container_name: cb-rest
- ports:
- - "8080:8080"
- restart: always
- volumes:
- - ~/share/vm_ms/controllerblueprints/config:/opt/app/onap/config
- - ~/share/vm_ms/controllerblueprints/logs:/logs
- environment:
- APPLICATIONNAME : ControllerBluePrints
- BUNDLEVERSION: 1.0.0
- APP_CONFIG_HOME: /opt/app/onap/config
- DB_URL: jdbc:mysql://db:3306/sdnctl
- DB_USER: sdnctl
- DB_PASSWORD: sdnctl
- INIT_DATA_LOAD: "true"
- STICKYSELECTORKEY:
+version: '3.3'
+
+services:
+ db:
+ image: mariadb:latest
+ container_name: cb-mariadb
+ ports:
+ - "3306:3306"
+ volumes:
+ - ~/vm_mysql:/var/lib/mysql
+ restart: always
+ environment:
+ MYSQL_ROOT_PASSWORD: sdnctl
+ MYSQL_DATABASE: sdnctl
+ MYSQL_USER: sdnctl
+ MYSQL_PASSWORD: sdnctl
+ controller-blueprints:
+ depends_on:
+ - db
+ image: onap/ccsdk-controllerblueprints:latest
+ container_name: cb-rest
+ ports:
+ - "8080:8080"
+ restart: always
+ volumes:
+ - ~/share/vm_ms/controllerblueprints/config:/opt/app/onap/config
+ - ~/share/vm_ms/controllerblueprints/logs:/logs
+ environment:
+ APPLICATIONNAME : ControllerBluePrints
+ BUNDLEVERSION: 1.0.0
+ APP_CONFIG_HOME: /opt/app/onap/config
+ DB_URL: jdbc:mysql://db:3306/sdnctl
+ DB_USER: sdnctl
+ DB_PASSWORD: sdnctl
+ INIT_DATA_LOAD: "true"
+ STICKYSELECTORKEY:
ENVCONTEXT: DEV \ No newline at end of file
diff --git a/ms/controllerblueprints/modules/service/src/test/java/org/onap/ccsdk/apps/controllerblueprints/service/repository/ResourceDictionaryReactRepositoryTest.java b/ms/controllerblueprints/modules/service/src/test/java/org/onap/ccsdk/apps/controllerblueprints/service/repository/ResourceDictionaryReactRepositoryTest.java
index fb11c39f..330eaa84 100644
--- a/ms/controllerblueprints/modules/service/src/test/java/org/onap/ccsdk/apps/controllerblueprints/service/repository/ResourceDictionaryReactRepositoryTest.java
+++ b/ms/controllerblueprints/modules/service/src/test/java/org/onap/ccsdk/apps/controllerblueprints/service/repository/ResourceDictionaryReactRepositoryTest.java
@@ -55,7 +55,7 @@ public class ResourceDictionaryReactRepositoryTest {
@Test
@Commit
public void test01Save() {
- ResourceDefinition resourceDefinition = JacksonUtils.Companion.readValueFromFile("./../../../../components/model-catalog/resource-dictionary/starter-dictionary/sample-db-source.json", ResourceDefinition.class);
+ ResourceDefinition resourceDefinition = JacksonUtils.Companion.readValueFromFile("./../../../../components/model-catalog/resource-dictionary/starter-dictionary/sample-primary-db-source.json", ResourceDefinition.class);
Assert.assertNotNull("Failed to get resourceDefinition from content", resourceDefinition);
resourceDefinition.setName(sourceName);
diff --git a/ms/controllerblueprints/modules/service/src/test/resources/application.properties b/ms/controllerblueprints/modules/service/src/test/resources/application.properties
index 29bb2b90..24cb23a1 100755
--- a/ms/controllerblueprints/modules/service/src/test/resources/application.properties
+++ b/ms/controllerblueprints/modules/service/src/test/resources/application.properties
@@ -20,7 +20,7 @@ logging.level.org.springframework.web=INFO
logging.level.org.hibernate.SQL=warn
logging.level.org.hibernate.type.descriptor.sql=debug
# Load Resource Source Mappings
-resourceSourceMappings=db=source-db,input=source-input,default=source-default,mdsal=source-rest,capability=source-capability
+resourceSourceMappings=primary-db=source-primary-db,input=source-input,default=source-default,mdsal=source-rest,capability=source-capability
# Controller Blueprints Core Configuration
controllerblueprints.blueprintDeployPath=./target/blueprints/deploy
controllerblueprints.blueprintArchivePath=./target/blueprints/archive
diff --git a/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-resource-assignment.json b/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-resource-assignment.json
index 3715beca..1c81b74d 100644
--- a/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-resource-assignment.json
+++ b/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-resource-assignment.json
@@ -7,7 +7,7 @@
"required": true
},
"dictionary-name": "sample-db-source",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"input-source"
]
diff --git a/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-template.json b/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-template.json
index b066dad6..42978f84 100644
--- a/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-template.json
+++ b/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhance-template.json
@@ -225,7 +225,7 @@
},
"input-param": false,
"dictionary-name": "sample-db-source",
- "dictionary-source": "db",
+ "dictionary-source": "primary-db",
"dependencies": [
"hostname"
],
diff --git a/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhanced-template.json b/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhanced-template.json
index b13932b7..66f18f89 100644
--- a/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhanced-template.json
+++ b/ms/controllerblueprints/modules/service/src/test/resources/enhance/enhanced-template.json
@@ -227,7 +227,7 @@
},
"input-param" : false,
"dictionary-name" : "sample-db-source",
- "dictionary-source" : "db",
+ "dictionary-source" : "primary-db",
"dependencies" : [ "hostname" ],
"version" : 0
}, {