Question 1:  Does the current SO Openstack adapter convert this Yaml  
“template” string to JSON at some point before it gets sent?  If it does, I 
haven’t been able to spot where that happens yet.
Nope

The second (related) issue is the “environment” attribute is also a string 
containing the contents of the heat env file.  I understand that multicloud 
would like to see this json attributes in the “parameters” list.
We would have to code that.

Question 2: Again, does the current SO Openstack adapter do any conversion on 
the “environment” attribute, or does it get sent ‘as is’?
Sent as is, best I can recall.

Questioin 3:  To summarize – is there current code in SO to do what I’m trying 
to do?  Or, does the current SO Openstack adapter just send the heat template 
and environment to Openstack as strings?
 I know we the intel folks are working on building in a multi-cloud plugin to 
the adapter.  Please reach out ot them, it looks like we will support it soon.


Thanks

-Steve


From: "Multanen, Eric W" <eric.w.multa...@intel.com>
Date: Friday, October 12, 2018 at 3:54 PM
To: "SMOKOWSKI, STEVEN" <ss8...@att.com>, "onap-discuss@lists.onap.org" 
<onap-discuss@lists.onap.org>
Subject: [SO] Heat template from yaml string to json for SO multicloud adapter

Hi SO experts,

For the Openstack multicloud adapter we’re working on in SO, a CreateStackParam 
object is
created from the inputs and included in the “template_data” part of the 
multicloud infra request body to create a vfModule.

That looks something like this:

               “template_data” : {
                              “template”: “ <contents of the yaml heat template 
file as a long string – from catalog db> “,
                              “stack_name”: “vfw”,
                              “parameters”: {
                                             “vnf_id”: “<vnf id>”
                              },
                              “environment”: “ <contents of the heat env file> 
“,
               etc.

The issue right now is that the multicloud side would like to get the 
“template” attributes in JSON format – instead of as a Yaml string.
               E.g. something like:
"template": {
"heat_template_version": "2015-10-15",
“description": "Simple template to test heat commands",
"parameters": {
<etc.>
}
               Instead of:
"template": 
"##########################################################################\n#\n#==================LICENSE_START==========================================\n#\n#\n#
 Copyright < rest of the heat template file > “,

Question 1:  Does the current SO Openstack adapter convert this Yaml  
“template” string to JSON at some point before it gets sent?  If it does, I 
haven’t been able to spot where that happens yet.

The second (related) issue is the “environment” attribute is also a string 
containing the contents of the heat env file.  I understand that multicloud 
would like to see this json attributes in the “parameters” list.

Question 2: Again, does the current SO Openstack adapter do any conversion on 
the “environment” attribute, or does it get sent ‘as is’?

Questioin 3:  To summarize – is there current code in SO to do what I’m trying 
to do?  Or, does the current SO Openstack adapter just send the heat template 
and environment to Openstack as strings?


Thanks,
Eric




-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#12992): https://lists.onap.org/g/onap-discuss/message/12992
Mute This Topic: https://lists.onap.org/mt/27276320/21656
Group Owner: onap-discuss+ow...@lists.onap.org
Unsubscribe: https://lists.onap.org/g/onap-discuss/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to