Uploaded image for project: 'Service Design and Creation'
  1. Service Design and Creation
  2. SDC-3920

Default value for inputs of complex type (in a instance interface operation) not being saved as JSON string

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Medium Medium
    • Jakarta Release
    • Istanbul Release, Jakarta Release
    • SDC
    • None

      The default value, in inputs of complex type that belongs to a node instance interface operation, are not being saved as JSON string. 

      To reproduce:

      dsl_stability_profile: standard1
      central_splitter: false
      service_restoration_sla: Standard1
      battery_backup: false
      partner_priorty_assist: false
      

      It is possible to see in a backend call, which loads the node instances in the composition screen, that the input toscaDefaultValue value comes as an incorrect stringfied JSON representation: 

      {dsl_stability_profile=standard1, central_splitter=false, service_restoration_sla=Standard1, battery_backup=false, partner_priorty_assist=false}
      

      This seems to be a common Java toString representation.

      it should come as:

      {"dsl_stability_profile": "standard1", "central_splitter": false, "service_restoration_sla": "Standard1", "battery_backup": false, "partner_priorty_assist": false}
      

      Not sure were the problem lies, but it is probably during the instance creation, when the node is added to the composition (org.openecomp.sdc.be.servlets.ComponentInstanceServlet#createComponentInstance).

            andre.schmid andre.schmid
            andre.schmid andre.schmid
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: