From 51e051e86f9f5d10c9439e9e5e57d1e9ee8f8e06 Mon Sep 17 00:00:00 2001 From: ojasdubey Date: Thu, 22 Feb 2018 14:32:06 +0530 Subject: VLAN tagging - Pattern 1A, 1C1 1. Implementation for supporting VLAN tagging in Pattern 1A and 1C1 heats 2. Updated code for switch case refactor with command design pattern 3. Added unit tests and bug fixes Change-Id: I54938ffd6673f865b4506a890ec8e7b9c54597b1 Issue-ID: SDC-1036 Signed-off-by: ojasdubey --- .../GlobalSubstitutionTypesServiceTemplate.yaml | 698 +++++++++++++++++++++ 1 file changed, 698 insertions(+) create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/fulltest/subinterface/vlantagging/pattern1c1/regularNestedSubInterface/out/GlobalSubstitutionTypesServiceTemplate.yaml (limited to 'openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/fulltest/subinterface/vlantagging/pattern1c1/regularNestedSubInterface/out/GlobalSubstitutionTypesServiceTemplate.yaml') diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/fulltest/subinterface/vlantagging/pattern1c1/regularNestedSubInterface/out/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/fulltest/subinterface/vlantagging/pattern1c1/regularNestedSubInterface/out/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..46ad8840c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/fulltest/subinterface/vlantagging/pattern1c1/regularNestedSubInterface/out/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,698 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: +- openecomp_heat_index: + file: openecomp-heat/_index.yml +node_types: + org.openecomp.resource.abstract.nodes.vdbe: + derived_from: org.openecomp.resource.abstract.nodes.VFC + properties: + port_vdbe_untr_port_network_role_tag: + type: string + required: true + status: SUPPORTED + subinterface_nested_parent_interface: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_aap_address_mode: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_vlan_tag_list: + type: list + required: true + status: SUPPORTED + entry_schema: + type: json + port_vdbe_untr_port_subnetpoolid: + type: string + required: true + status: SUPPORTED + compute_vdbe_availability_zone: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_aap_untrusted_v6_ip_prefix_len: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + vm_flavor_name: + type: string + required: true + status: SUPPORTED + port_vdbe_untr_port_order: + type: integer + required: true + status: SUPPORTED + subinterface_nested_aap_untrusted_ip_prefix: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + vm_image_name: + type: string + required: true + status: SUPPORTED + port_vdbe_untr_port_exCP_naming: + type: org.openecomp.datatypes.Naming + required: true + status: SUPPORTED + subinterface_nested_aap_sec_untrusted_ip_prefix_len: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_aap_sec_untrusted_ip_prefix: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_aap_untrusted_v6_ip_prefix: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + compute_vdbe_metadata: + type: list + required: true + status: SUPPORTED + entry_schema: + type: json + subinterface_nested_mac_address: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + port_vdbe_untr_port_virtual_machine_interface_allowed_address_pairs: + type: org.openecomp.datatypes.heat.contrailV2.virtual.machine.subInterface.AddressPairs + required: true + status: SUPPORTED + subinterface_nested_ip_address: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + port_vdbe_untr_port_virtual_network_refs: + type: list + required: true + status: SUPPORTED + entry_schema: + type: json + subinterface_nested_ip_v6_address: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + port_vdbe_untr_port_mac_requirements: + type: org.openecomp.datatypes.network.MacRequirements + required: true + status: SUPPORTED + index_value: + type: integer + description: Index value of this substitution service template runtime instance + required: false + default: 0 + status: SUPPORTED + constraints: + - greater_or_equal: 0 + subinterface_nested_vmac_address: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_vn_network_list: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + port_vdbe_untr_port_name: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + port_vdbe_untr_port_vlan_requirements: + type: list + required: true + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.network.VlanRequirements + port_vdbe_untr_port_network_role: + type: string + required: true + status: SUPPORTED + port_vdbe_untr_port_virtual_machine_interface_mac_addresses: + type: list + required: true + status: SUPPORTED + entry_schema: + type: json + subinterface_nested_aap_untrusted_ip_prefix_len: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_counter: + type: list + required: true + status: SUPPORTED + entry_schema: + type: float + subinterface_nested_subinterfaces_name_prefix: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + compute_vdbe_name: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_optional_property_1: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + subinterface_nested_optional_property_2: + type: list + required: true + status: SUPPORTED + entry_schema: + type: string + port_vdbe_untr_port_ip_requirements: + type: list + required: true + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.network.IpRequirements + requirements: + - dependency_vdbe: + capability: tosca.capabilities.Node + node: tosca.nodes.Root + relationship: tosca.relationships.DependsOn + occurrences: + - 0 + - UNBOUNDED + - local_storage_vdbe: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - dependency_vdbe_vdbe_untr_port: + capability: tosca.capabilities.Node + node: tosca.nodes.Root + relationship: tosca.relationships.DependsOn + occurrences: + - 0 + - UNBOUNDED + - link_vdbe_vdbe_untr_port: + capability: tosca.capabilities.network.Linkable + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - dependency_vdbe_vdbe_untr_port_nested: + capability: tosca.capabilities.Node + node: tosca.nodes.Root + relationship: tosca.relationships.DependsOn + occurrences: + - 0 + - UNBOUNDED + - dependency_vdbe_untr_x_vlan1-Network-Role_vmi_subport_vdbe_vdbe_untr_port_nested: + capability: tosca.capabilities.Node + node: tosca.nodes.Root + relationship: tosca.relationships.DependsOn + occurrences: + - 0 + - UNBOUNDED + - link_vdbe_untr_x_vlan1-Network-Role_vmi_subport_vdbe_vdbe_untr_port_nested: + capability: tosca.capabilities.network.Linkable + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + network.outgoing.packets.rate_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.outgoing.bytes_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + feature_vdbe: + type: tosca.capabilities.Node + occurrences: + - 1 + - UNBOUNDED + feature_vdbe_vdbe_untr_port: + type: tosca.capabilities.Node + occurrences: + - 1 + - UNBOUNDED + disk.device.iops_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + endpoint_vdbe: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + disk.ephemeral.size_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + cpu_util_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + vcpus_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.write.requests_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.latency_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.write.requests.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.write.bytes.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.incoming.packets_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + scalable_vdbe: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + disk.iops_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.write.requests_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.capacity_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.allocation_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.usage_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + memory.usage_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.outpoing.packets_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.outgoing.bytes.rate_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.read.requests_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + forwarder_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.Forwarder + occurrences: + - 1 + - UNBOUNDED + feature_vdbe_untr_x_vlan1-Network-Role_vmi_subport_vdbe_vdbe_untr_port_nested: + type: tosca.capabilities.Node + occurrences: + - 1 + - UNBOUNDED + binding_vdbe_vdbe_untr_port: + type: tosca.capabilities.network.Bindable + valid_source_types: + - org.openecomp.resource.cp.nodes.heat.network.contrailV2.VLANSubInterface + occurrences: + - 0 + - UNBOUNDED + instance_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.incoming.bytes.rate_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + cpu.delta_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.read.bytes.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.write.bytes.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + memory.resident_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + feature_vdbe_vdbe_untr_port_nested: + type: tosca.capabilities.Node + occurrences: + - 1 + - UNBOUNDED + disk.write.requests.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + cpu_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.write.bytes_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.usage_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.read.bytes_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.latency_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.incoming.bytes_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.capacity_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + host_vdbe: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + disk.allocation_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.read.bytes.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + os_vdbe: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + disk.device.read.requests_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.root.size_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + memory_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + binding_vdbe: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + disk.device.write.bytes_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.device.read.requests.rate_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + disk.read.bytes_vdbe: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + network.incoming.packets.rate_vdbe_vdbe_untr_port: + type: org.openecomp.capabilities.metric.Ceilometer + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.subinterface.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + aap_untrusted_ip_prefix: + type: string + description: ip prefix for primary vDBE VM on the VAN untrusted network + required: true + status: SUPPORTED + aap_sec_untrusted_ip_prefix: + type: string + description: ip prefix for secondary vDBE VM aap on the VAN untrusted network + required: true + status: SUPPORTED + ip_v6_address: + type: string + description: IPv6 address associated with subinterfaces + required: true + status: SUPPORTED + counter: + type: float + description: Index of instance among multiple instances. Use to retrieve correct parameter for this instance when passed all parameters for all instances. + required: true + status: SUPPORTED + subinterfaces_name_prefix: + type: string + description: Combined with subinterface_instance_index, this is used as the name of the subinterface resource + required: true + status: SUPPORTED + ip_address: + type: string + description: IPv4 address associated with subinterfaces + required: true + status: SUPPORTED + aap_address_mode: + type: string + description: Address mode for the vDBE cluster IP + required: true + status: SUPPORTED + aap_untrusted_v6_ip_prefix: + type: string + description: ipv6 prefix for the primary vDBE VM on the VAN untrusted network + required: true + status: SUPPORTED + parent_interface: + type: string + description: Parent Contrail interface + required: true + status: SUPPORTED + vn_network_list: + type: string + description: List of Contrail VLAN networks to use for the subinterfaces. The order and number of these must match the VLAN ID list + required: true + status: SUPPORTED + optional_property_1: + type: string + description: Optional property + required: true + status: SUPPORTED + optional_property_2: + type: string + description: Optional property + required: true + status: SUPPORTED + mac_address: + type: string + description: HW MAC address to use for subinterface + required: true + status: SUPPORTED + vlan_tag_list: + type: list + description: List of VLAN IDs to use for subinterfaces + required: true + status: SUPPORTED + entry_schema: + type: string + aap_sec_untrusted_ip_prefix_len: + type: string + description: ip prefix length for the secondary DBE VM aap on the VAN untrusted network + required: true + status: SUPPORTED + vmac_address: + type: string + description: virtual MAC address to use for subinterface + required: true + status: SUPPORTED + aap_untrusted_v6_ip_prefix_len: + type: string + description: ipv6 prefix length for the primary vDBE VM on the VAN untrusted network + required: true + status: SUPPORTED + aap_untrusted_ip_prefix_len: + type: string + description: ip prefix length for the primary vDBE VM on the VAN untrusted network + required: true + status: SUPPORTED + requirements: + - dependency_vdbe_untr_x_vlan1-Network-Role_vmi_subport: + capability: tosca.capabilities.Node + node: tosca.nodes.Root + relationship: tosca.relationships.DependsOn + occurrences: + - 0 + - UNBOUNDED + - link_vdbe_untr_x_vlan1-Network-Role_vmi_subport: + capability: tosca.capabilities.network.Linkable + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - binding_vdbe_untr_x_vlan1-Network-Role_vmi_subport: + capability: tosca.capabilities.network.Bindable + node: org.openecomp.resource.cp.nodes.network.Port + relationship: tosca.relationships.network.BindsTo + occurrences: + - 1 + - 1 + capabilities: + feature_vdbe_untr_x_vlan1-Network-Role_vmi_subport: + type: tosca.capabilities.Node + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file -- cgit 1.2.3-korg