From fd8845d494fa0f054e00012d3eb13a28d733ba59 Mon Sep 17 00:00:00 2001 From: Alexis de Talhouët Date: Fri, 29 Mar 2019 09:08:45 -0400 Subject: Update golden blueprint MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Ib80de8dfed834b0ed062adafd1b029eb715be3e5 Issue-ID: CCSDK-1149 Signed-off-by: Alexis de Talhouët --- .../golden/Definitions/activation-blueprint.json | 333 --------------------- .../golden/Definitions/data_types.json | 156 +++++----- .../golden/Definitions/golden-blueprint.json | 326 ++++++++++++++++++++ .../Definitions/resources_definition_types.json | 2 +- 4 files changed, 397 insertions(+), 420 deletions(-) delete mode 100644 components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/activation-blueprint.json create mode 100644 components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/golden-blueprint.json (limited to 'components/model-catalog/blueprint-model/test-blueprint/golden/Definitions') diff --git a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/activation-blueprint.json b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/activation-blueprint.json deleted file mode 100644 index b6464f3c8..000000000 --- a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/activation-blueprint.json +++ /dev/null @@ -1,333 +0,0 @@ -{ - "tosca_definitions_version" : "controller_blueprint_1_0_0", - "metadata" : { - "template_author" : "Alexis de Talhouët", - "author-email" : "adetalhouet89@gmail.com", - "user-groups" : "ADMIN, OPERATION", - "template_name" : "test", - "template_version" : "1.0.0", - "template_tags" : "test" - }, - "imports" : [ { - "file" : "Definitions/data_types.json" - }, { - "file" : "Definitions/relationship_types.json" - }, { - "file" : "Definitions/artifact_types.json" - }, { - "file" : "Definitions/node_types.json" - }, { - "file" : "Definitions/policy_types.json" - } ], - "dsl_definitions" : { - "ipam-1" : { - "type" : "token-auth", - "url" : "http://localhost:32778", - "token" : "Token 0123456789abcdef0123456789abcdef01234567" - }, - "config-deploy-properties" : { - "resolution-key" : { - "get_input" : "resolution-key" - } - } - }, - "topology_template" : { - "workflows" : { - "resource-assignment" : { - "steps" : { - "resource-assignment-process" : { - "description" : "Resource Assign Workflow", - "target" : "resource-assignment-process", - "activities" : [ { - "call_operation" : "" - } ] - } - }, - "inputs" : { - "artifact-name" : { - "required" : true, - "type" : "list", - "entry_schema" : { - "type" : "string" - } - }, - "store-result" : { - "required" : true, - "type" : "boolean" - }, - "resolution-key" : { - "required" : true, - "type" : "string" - }, - "resource-assignment-properties" : { - "description" : "Dynamic PropertyDefinition for workflow(resource-assignment).", - "required" : true, - "type" : "dt-resource-assignment-properties" - } - } - }, - "config-deploy" : { - "steps" : { - "config-deploy" : { - "description" : "Resource Assign and Python Netconf Activation Workflow", - "target" : "config-deploy-process", - "activities" : [ { - "call_operation" : "" - } ] - } - }, - "inputs" : { - "resolution-key" : { - "required" : false, - "type" : "string" - }, - "password" : { - "required" : true, - "type" : "string" - }, - "username" : { - "required" : true, - "type" : "string" - }, - "ip" : { - "required" : true, - "type" : "string" - }, - "config-deploy-properties" : { - "description" : "Dynamic PropertyDefinition for workflow(config-deploy).", - "required" : true, - "type" : "dt-config-deploy-properties" - } - } - }, - "rollback" : { - "steps" : { - "rollback" : { - "description" : "Roolback Workflow", - "target" : "rollback-process", - "activities" : [ { - "call_operation" : "" - } ] - } - }, - "inputs" : { - "resolution-key" : { - "required" : false, - "type" : "string" - }, - "password" : { - "required" : true, - "type" : "string" - }, - "username" : { - "required" : true, - "type" : "string" - }, - "ip" : { - "required" : true, - "type" : "string" - }, - "config-deploy-properties" : { - "description" : "Dynamic PropertyDefinition for workflow(config-deploy).", - "required" : true, - "type" : "dt-config-deploy-properties" - }, - "rollback-properties" : { - "description" : "Dynamic PropertyDefinition for workflow(rollback).", - "required" : true, - "type" : "dt-rollback-properties" - } - } - } - }, - "node_templates" : { - "resource-assignment-process" : { - "type" : "dg-generic", - "properties" : { - "content" : { - "get_artifact" : [ "SELF", "dg-resource-assignment-process" ] - }, - "dependency-node-templates" : [ "resource-assignment" ] - }, - "artifacts" : { - "dg-resource-assignment-process" : { - "type" : "artifact-directed-graph", - "file" : "Plans/ResourceAssignment.xml" - } - } - }, - "resource-assignment" : { - "type" : "component-resource-resolution", - "interfaces" : { - "ResourceResolutionComponent" : { - "operations" : { - "process" : { - "inputs" : { - "resolution-key" : { - "get_input" : "resolution-key" - }, - "store-result" : { - "get_input" : "store-result" - }, - "artifact-prefix-names" : { - "get_input" : "artifact-name" - } - }, - "outputs" : { - "resource-assignment-params" : { - "get_attribute" : [ "SELF", "assignment-params" ] - }, - "status" : "success" - } - } - } - } - }, - "artifacts" : { - "hostname-template" : { - "type" : "artifact-template-velocity", - "file" : "Templates/hostname-template.vtl" - }, - "hostname-mapping" : { - "type" : "artifact-mapping-resource", - "file" : "Templates/hostname-mapping.json" - }, - "vf-module-1-template" : { - "type" : "artifact-template-velocity", - "file" : "Templates/vf-module-1-template.vtl" - }, - "vf-module-1-mapping" : { - "type" : "artifact-mapping-resource", - "file" : "Templates/vf-module-1-mapping.json" - } - } - }, - "config-deploy-process" : { - "type" : "dg-generic", - "properties" : { - "content" : { - "get_artifact" : [ "SELF", "dg-config-deploy-process" ] - }, - "dependency-node-templates" : [ "config-deploy" ] - }, - "artifacts" : { - "dg-config-deploy-process" : { - "type" : "artifact-directed-graph", - "file" : "Plans/ConfigDeploy.xml" - } - } - }, - "config-deploy" : { - "type" : "component-netconf-executor", - "requirements" : { - "netconf-connection" : { - "capability" : "netconf", - "node" : "netconf-device", - "relationship" : "tosca.relationships.ConnectsTo" - } - }, - "interfaces" : { - "ComponentNetconfExecutor" : { - "operations" : { - "process" : { - "inputs" : { - "script-type" : "jython", - "script-class-reference" : "Scripts/python/NetconfRpcExample.py", - "instance-dependencies" : [ ], - "dynamic-properties" : "*config-deploy-properties" - }, - "outputs" : { - "response-data" : "", - "status" : "SUCCESS" - } - } - } - } - }, - "artifacts" : { - "vfw-interface-template" : { - "type" : "artifact-template-velocity", - "file" : "Templates/vfw-interface-template.vtl" - }, - "vfw-interface-mapping" : { - "type" : "artifact-mapping-resource", - "file" : "Templates/vfw-interface-mapping.json" - } - } - }, - "rollback-process" : { - "type" : "dg-generic", - "properties" : { - "content" : { - "get_artifact" : [ "SELF", "dg-rollback-process" ] - }, - "dependency-node-templates" : [ "config-deploy" ] - }, - "artifacts" : { - "dg-rollback-process" : { - "type" : "artifact-directed-graph", - "file" : "Plans/Rollback.xml" - } - } - }, - "rollback" : { - "type" : "component-netconf-executor", - "requirements" : { - "netconf-connection" : { - "capability" : "netconf", - "node" : "netconf-device", - "relationship" : "tosca.relationships.ConnectsTo" - } - }, - "interfaces" : { - "ComponentNetconfExecutor" : { - "operations" : { - "process" : { - "inputs" : { - "script-type" : "jython", - "script-class-reference" : "Scripts/python/Rollback.py", - "instance-dependencies" : [ ], - "dynamic-properties" : "*config-deploy-properties" - }, - "outputs" : { - "response-data" : "", - "status" : "SUCCESS" - } - } - } - } - }, - "artifacts" : { - "junos-rollback-RPC-template" : { - "type" : "artifact-template-velocity", - "file" : "Templates/junos-rollback-RPC-template.vtl" - }, - "junos-rollback-RPC-mapping" : { - "type" : "artifact-mapping-resource", - "file" : "Templates/junos-rollback-RPC-mapping.json" - } - } - }, - "netconf-device" : { - "type" : "vnf-netconf-device", - "capabilities" : { - "netconf" : { - "properties" : { - "login-key" : { - "get_input" : "password" - }, - "login-account" : { - "get_input" : "username" - }, - "target-ip-address" : { - "get_input" : "ip" - }, - "port-number" : 830, - "connection-time-out" : 5 - } - } - } - } - } - } -} \ No newline at end of file diff --git a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/data_types.json b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/data_types.json index d60e6f00c..8f3b9b4c5 100644 --- a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/data_types.json +++ b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/data_types.json @@ -1,106 +1,90 @@ { - "data_types" : { - "dt-config-deploy-properties" : { - "description" : "Dynamic DataType definition for workflow(config-deploy).", - "version" : "1.0.0", - "properties" : { - "vfw_interface_ip" : { - "type" : "dt-netbox-ip" - }, - "interface-name" : { - "type" : "string" - }, - "interface-description" : { - "type" : "string" - }, - "unit-number" : { - "type" : "string" - }, - "prefix-id" : { - "type" : "string", - "default" : "11" - }, - "vf-module-type" : { - "type" : "string" - }, - "vf-module-number" : { - "type" : "string", - "default" : "3" + "data_types": { + "dt-resource-assignment-properties": { + "description": "Dynamic DataType definition for workflow(resource-assignment).", + "version": "1.0.0", + "properties": { + "vfw_interface_ip": { + "type": "dt-netbox-ip" + }, + "interface-description": { + "type": "string" + }, + "vf-module-type": { + "type": "string" + }, + "vf-module-number": { + "type": "string", + "default": "3" + }, + "prefix-id": { + "type": "integer", + "default": 11 } }, - "derived_from" : "tosca.datatypes.Dynamic" + "derived_from": "tosca.datatypes.Dynamic" }, - "dt-netbox-ip" : { - "description" : "This is Netbox IP Data Type", - "version" : "1.0.0", - "properties" : { - "address" : { - "required" : true, - "type" : "string" - }, - "id" : { - "required" : true, - "type" : "integer" + "dt-config-assign-properties": { + "description": "Dynamic DataType definition for workflow(config-assign).", + "version": "1.0.0", + "properties": { + "hostname": { + "type": "string" } }, - "derived_from" : "tosca.datatypes.Root" + "derived_from": "tosca.datatypes.Dynamic" }, - "dt-resource-assignment-properties" : { - "description" : "Dynamic DataType definition for workflow(resource-assignment).", - "version" : "1.0.0", - "properties" : { - "hostname" : { - "type" : "string" + "dt-config-deploy-properties": { + "description": "Dynamic DataType definition for workflow(config-deploy).", + "version": "1.0.0", + "properties": { + "vfw_interface_ip": { + "type": "dt-netbox-ip" + }, + "interface-name": { + "type": "string" }, - "vfw_interface_ip" : { - "type" : "dt-netbox-ip" + "interface-description": { + "type": "string" }, - "interface-description" : { - "type" : "string" + "unit-number": { + "type": "string" }, - "vf-module-type" : { - "type" : "string" + "prefix-id": { + "type": "string", + "default": "11" }, - "vf-module-number" : { - "type" : "string", - "default" : "3" + "vf-module-type": { + "type": "string" }, - "prefix-id" : { - "type" : "integer", - "default" : 11 + "vf-module-number": { + "type": "string", + "default": "3" } }, - "derived_from" : "tosca.datatypes.Dynamic" + "derived_from": "tosca.datatypes.Dynamic" }, - "dt-rollback-properties" : { - "description" : "Dynamic DataType definition for workflow(rollback).", - "version" : "1.0.0", - "properties" : { - "vfw_interface_ip" : { - "type" : "dt-netbox-ip" - }, - "interface-name" : { - "type" : "string" - }, - "interface-description" : { - "type" : "string" - }, - "unit-number" : { - "type" : "string" - }, - "prefix-id" : { - "type" : "string", - "default" : "11" - }, - "vf-module-type" : { - "type" : "string" - }, - "vf-module-number" : { - "type" : "string", - "default" : "3" + "dt-rollback-properties": { + "description": "Dynamic DataType definition for workflow(rollback).", + "version": "1.0.0", + "properties": { + }, + "derived_from": "tosca.datatypes.Dynamic" + }, + "dt-netbox-ip": { + "description": "This is Netbox IP Data Type", + "version": "1.0.0", + "properties": { + "address": { + "required": true, + "type": "string" + }, + "id": { + "required": true, + "type": "integer" } }, - "derived_from" : "tosca.datatypes.Dynamic" + "derived_from": "tosca.datatypes.Root" } } } \ No newline at end of file diff --git a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/golden-blueprint.json b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/golden-blueprint.json new file mode 100644 index 000000000..6a9df9b58 --- /dev/null +++ b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/golden-blueprint.json @@ -0,0 +1,326 @@ +{ + "metadata": { + "template_author": "Alexis de Talhouët", + "author-email": "adetalhouet89@gmail.com", + "user-groups": "ADMIN, OPERATION", + "template_name": "test", + "template_version": "1.0.0", + "template_tags": "test" + }, + "imports": [ + { + "file": "Definitions/data_types.json" + }, + { + "file": "Definitions/relationship_types.json" + }, + { + "file": "Definitions/artifact_types.json" + }, + { + "file": "Definitions/node_types.json" + }, + { + "file": "Definitions/policy_types.json" + } + ], + "dsl_definitions": { + "ipam-1": { + "type": "token-auth", + "url": "http://localhost:32768", + "token": "Token 0123456789abcdef0123456789abcdef01234567" + }, + "config-deploy-properties": { + "resolution-key": { + "get_input": "resolution-key" + } + } + }, + "topology_template": { + "workflows": { + "resource-assignment": { + "steps": { + "resource-assignment": { + "description": "Resource Assign Workflow", + "target": "resource-assignment", + "activities": [ + { + "call_operation": "" + } + ] + } + }, + "inputs": { + "resource-assignment-properties": { + "description": "Dynamic PropertyDefinition for workflow(resource-assignment).", + "required": true, + "type": "dt-resource-assignment-properties" + } + }, + "outputs": { + "meshed-template": { + "type": "json", + "value": { + "get_attribute": [ + "resource-assignment", + "assignment-params" + ] + } + } + } + }, + "config-assign": { + "steps": { + "config-assign": { + "description": "Config Assign Workflow", + "target": "config-assign", + "activities": [ + { + "call_operation": "" + } + ] + } + }, + "inputs": { + "resolution-key": { + "required": true, + "type": "string" + }, + "config-assign-properties": { + "description": "Dynamic PropertyDefinition for workflow(config-assign).", + "required": true, + "type": "dt-config-assign-properties" + } + }, + "outputs": { + "dry-run": { + "type": "json", + "value": { + "get_attribute": [ + "config-assign", + "assignment-params" + ] + } + } + } + }, + "config-deploy": { + "steps": { + "config-deploy": { + "description": "Resource Assign and Python Netconf Activation Workflow", + "target": "config-deploy", + "activities": [ + { + "call_operation": "" + } + ] + } + }, + "inputs": { + "resolution-key": { + "required": false, + "type": "string" + }, + "password": { + "required": true, + "type": "string" + }, + "username": { + "required": true, + "type": "string" + }, + "ip": { + "required": true, + "type": "string" + }, + "config-deploy-properties": { + "description": "Dynamic PropertyDefinition for workflow(config-deploy).", + "required": true, + "type": "dt-config-deploy-properties" + } + } + }, + "rollback": { + "steps": { + "rollback": { + "description": "Rollback Workflow", + "target": "rollback", + "activities": [ + { + "call_operation": "" + } + ] + } + }, + "inputs": { + "resolution-key": { + "required": false, + "type": "string" + }, + "password": { + "required": true, + "type": "string" + }, + "username": { + "required": true, + "type": "string" + }, + "ip": { + "required": true, + "type": "string" + }, + "rollback-properties": { + "description": "Dynamic PropertyDefinition for workflow(rollback).", + "required": true, + "type": "dt-rollback-properties" + } + } + } + }, + "node_templates": { + "resource-assignment": { + "type": "component-resource-resolution", + "interfaces": { + "ResourceResolutionComponent": { + "operations": { + "process": { + "inputs": { + "artifact-prefix-names": [ + "vf-module-1" + ] + } + } + } + } + }, + "artifacts": { + "vf-module-1-template": { + "type": "artifact-template-velocity", + "file": "Templates/vf-module-1-template.vtl" + }, + "vf-module-1-mapping": { + "type": "artifact-mapping-resource", + "file": "Templates/vf-module-1-mapping.json" + } + } + }, + "config-assign": { + "type": "component-resource-resolution", + "interfaces": { + "ResourceResolutionComponent": { + "operations": { + "process": { + "inputs": { + "resolution-key": { + "get_input": "resolution-key" + }, + "store-result": true, + "artifact-prefix-names": [ + "hostname" + ] + } + } + } + } + }, + "artifacts": { + "hostname-template": { + "type": "artifact-template-velocity", + "file": "Templates/hostname-template.vtl" + }, + "hostname-mapping": { + "type": "artifact-mapping-resource", + "file": "Templates/hostname-mapping.json" + } + } + }, + "config-deploy": { + "type": "component-netconf-executor", + "requirements": { + "netconf-connection": { + "capability": "netconf", + "node": "netconf-device", + "relationship": "tosca.relationships.ConnectsTo" + } + }, + "interfaces": { + "ComponentNetconfExecutor": { + "operations": { + "process": { + "inputs": { + "script-type": "jython", + "script-class-reference": "Scripts/python/ConfigDeploy.py", + "instance-dependencies": [], + "dynamic-properties": "*config-deploy-properties" + } + } + } + } + }, + "artifacts": { + "vfw-interface-template": { + "type": "artifact-template-velocity", + "file": "Templates/vfw-interface-template.vtl" + }, + "vfw-interface-mapping": { + "type": "artifact-mapping-resource", + "file": "Templates/vfw-interface-mapping.json" + } + } + }, + "rollback": { + "type": "component-netconf-executor", + "requirements": { + "netconf-connection": { + "capability": "netconf", + "node": "netconf-device", + "relationship": "tosca.relationships.ConnectsTo" + } + }, + "interfaces": { + "ComponentNetconfExecutor": { + "operations": { + "process": { + "inputs": { + "script-type": "jython", + "script-class-reference": "Scripts/python/Rollback.py", + "instance-dependencies": [] + } + } + } + } + }, + "artifacts": { + "junos-rollback-RPC-template": { + "type": "artifact-template-velocity", + "file": "Templates/junos-rollback-RPC-template.vtl" + }, + "junos-rollback-RPC-mapping": { + "type": "artifact-mapping-resource", + "file": "Templates/junos-rollback-RPC-mapping.json" + } + } + }, + "netconf-device": { + "type": "vnf-netconf-device", + "capabilities": { + "netconf": { + "properties": { + "login-key": { + "get_input": "password" + }, + "login-account": { + "get_input": "username" + }, + "target-ip-address": { + "get_input": "ip" + }, + "port-number": 830, + "connection-time-out": 5 + } + } + } + } + } + } +} \ No newline at end of file diff --git a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/resources_definition_types.json b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/resources_definition_types.json index 15f02a1ce..1169a8d58 100644 --- a/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/resources_definition_types.json +++ b/components/model-catalog/blueprint-model/test-blueprint/golden/Definitions/resources_definition_types.json @@ -55,7 +55,7 @@ "type" : "source-capability", "properties" : { "script-type" : "jython", - "script-class-reference" : "DescriptionExample", + "script-class-reference" : "Scripts/python/DescriptionExample.py", "instance-dependencies" : [ ] } } -- cgit 1.2.3-korg