Not able to make topology in Tacker

asked 2016-05-08 23:04:52 -0600

Devesh gravatar image

Hi , I am trying to make topology in Tacker using TOSCA language. But I am getting some unusual error.


2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat
tpl.validate(self) 2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat
File "/usr/local/lib/python2.7/dist-packages/toscaparser/nodetemplate.py", line 180, in validate 2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat
self._validate_requirements() 2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat
File "/usr/local/lib/python2.7/dist-packages/toscaparser/nodetemplate.py", line 206, in _validate_requirements 2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat
for r1, value in req.items(): 2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat AttributeError: 'str' object has no attribute 'items' 2016-05-06 16:54:42.514 TRACE tacker.vm.infra_drivers.heat.heat 2016-05-06 16:54:42.515 INFO tacker.api.v1.resource [req-26d7957a-96d2-43ea-9269-c6cd05deb02a demo c3d3e96b967940b09b09615bedd2a68b] create failed (client error): tosca-parser failed: - 'str' object has no attribute 'items' 2016-05-06 16:54:42.516 INFO tacker.wsgi [req-26d7957a-96d2-43ea-9269-c6cd05deb02a demo c3d3e96b967940b09b09615bedd2a68b] 172.19.58.245 - - [06/May/2016 16:54:42] "POST /v1.0/vnfds.json HTTP/1.1" 400 358 0.130972


My TOSCA file is


tosca_definitions_version: tosca_simple_profile_for_nfv_1_0_0

description: Template for deploying a single server with predefined properties.

metadata: template_name: TOSCA NFV Sample Template

imports: - tosca_base_type_definition.yaml

topology_template: node_templates: VNF1: type: tosca.nodes.nfv.VNF.VNF1 properties: id: vnf1 vendor: Tacker #version: 1.0 Scaling_methodology: Flavour_ID: Threshold: Auto-scale policy value: Constraints: requirements: virtualLink1: VL1
virtualLink2: VL2
virtualLink3: VL3
capabilities: forwarder1
forwarder2
forwarder3
VDU1: type: tosca.nodes.nfv.VDU properties: image: cirros-0.3.4-x86_64-uec flavor: m1.tiny availability_zone: nova mgmt_driver: noop config: | param0: key1 param1: key2

VNF2:
  type: tosca.nodes.nfv.VNF.VNF2
  properties:
    id: vnf2
    vendor: Tacker
    #version: 1.0
    Scaling_methodology:
    Flavour_ID:
    Threshold:
    Auto-scale policy value:
    Constraints:
  requirements:
            virtualLink1: VL2
  capabilities:
    forwarder1
VDU2:
  type: tosca.nodes.nfv.VDU
  properties:
    image: cirros-0.3.4-x86_64-uec
    flavor: m1.tiny
    availability_zone: nova
    mgmt_driver: noop
    config: |
      param0: key1
      param1: key2

VNF3:
  type: tosca.nodes.nfv.VNF.VNF3
  properties:
    id: vnf3
    vendor: Tacker
    #version: 1.0
    Scaling_methodology:
    Flavour_ID:
    Threshold:
    Auto-scale policy value:
    Constraints:
  requirements:
            virtualLink1: VL2
            virtualLink2: VL3
            virtualLink3: VL4
  capabilities:
    forwarder1
    forwarder2
    forwarder3
VDU3:
  type: tosca.nodes.nfv.VDU
  properties:
    image: cirros-0.3.4-x86_64-uec
    flavor: m1.tiny
    availability_zone: nova
    mgmt_driver: noop
    config: |
      param0: key1
      param1: key2


CP01:
  type: tosca.nodes.nfv.CP
  properties:
  requirements:
    - virtualLink:VL1

CP02:
  type: tosca.nodes.nfv.CP
  properties:
  requirements:
    - virtualLink:VL4

VL1:
  type: tosca.nodes.nfv.VL.ELAN
  properties:
  capabilities:
    virtual_linkable:
      occurrences: 2

VL2:
  type: tosca.nodes.nfv.VL.ELAN
  properties:
  capabilities:
    virtual_linkable:
      occurrences: 5

VL3:
  type: tosca.nodes.nfv.VL.ELAN
  properties:
  capabilities:
    virtual_linkable:
      occurrences: 2

VL4:
  type: tosca.nodes.nfv.VL.ELAN
  properties:
  capabilities:
    virtual_linkable:
      occurrences: 2



  Forwardingpath1:
        type: tosca.nodes.nfv.FP
        properties:
           policy:
        requirements:
           -forwarder: CP01
           -forwarder: VNF1
             capability:forwarder1         #CP11
           -forwarder: VNF1
             capability:forwarder3         #CP13
           -forwarder: VNF2
             capability:forwarder1         #CP21
           -forwarder: VNF3
             capability:forwarder1         #CP31
           -forwarder: VNF3
             capability:forwarder3         #CP33
           -forwarder: CP02  

  Forwardingpath2:
        type: tosca.nodes.nfv ...
(more)
edit retag flag offensive close merge delete