Remove passing infra and mgmt driver from client
This patch removes passing infra and mgmt driver as part of VNFD body from client and API. Change-Id: I4684e69b8993e6c35503317503dd73e2c13f44dd Partial-Bug: #1630936
This commit is contained in:
parent
d26d358145
commit
1e613792fd
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- Remove passing mgmt and infra driver from client.
|
|
@ -32,7 +32,7 @@ class ListVNFD(tackerV10.ListCommand):
|
||||||
"""List VNFD that belong to a given tenant."""
|
"""List VNFD that belong to a given tenant."""
|
||||||
|
|
||||||
resource = _VNFD
|
resource = _VNFD
|
||||||
list_columns = ['id', 'name', 'description', 'infra_driver', 'mgmt_driver']
|
list_columns = ['id', 'name', 'description']
|
||||||
|
|
||||||
|
|
||||||
class ShowVNFD(tackerV10.ShowCommand):
|
class ShowVNFD(tackerV10.ShowCommand):
|
||||||
|
|
|
@ -33,16 +33,14 @@ class CLITestV10VmVNFDJSON(test_cli10.CLITestV10Base):
|
||||||
test_cli10.MyApp(sys.stdout), None)
|
test_cli10.MyApp(sys.stdout), None)
|
||||||
my_id = 'my-id'
|
my_id = 'my-id'
|
||||||
name = 'my-name'
|
name = 'my-name'
|
||||||
mgmt_driver = 'noop'
|
|
||||||
infra_driver = 'heat'
|
|
||||||
attr_key = 'vnfd'
|
attr_key = 'vnfd'
|
||||||
attr_val = 'vnfd'
|
attr_val = 'vnfd'
|
||||||
args = [
|
args = [
|
||||||
name,
|
name,
|
||||||
'--vnfd', 'vnfd'
|
'--vnfd', 'vnfd'
|
||||||
]
|
]
|
||||||
position_names = ['name', 'mgmt_driver', 'infra_driver']
|
position_names = ['name']
|
||||||
position_values = [name, mgmt_driver, infra_driver]
|
position_values = [name]
|
||||||
extra_body = {
|
extra_body = {
|
||||||
'service_types': [{'service_type': 'vnfd'}],
|
'service_types': [{'service_type': 'vnfd'}],
|
||||||
'attributes': {attr_key: attr_val},
|
'attributes': {attr_key: attr_val},
|
||||||
|
@ -56,11 +54,9 @@ class CLITestV10VmVNFDJSON(test_cli10.CLITestV10Base):
|
||||||
test_cli10.MyApp(sys.stdout), None)
|
test_cli10.MyApp(sys.stdout), None)
|
||||||
name = 'my_name'
|
name = 'my_name'
|
||||||
my_id = 'my-id'
|
my_id = 'my-id'
|
||||||
mgmt_driver = 'noop'
|
|
||||||
infra_driver = 'heat'
|
|
||||||
args = [name, '--vnfd', 'vnfd', ]
|
args = [name, '--vnfd', 'vnfd', ]
|
||||||
position_names = ['name', 'mgmt_driver', 'infra_driver']
|
position_names = ['name']
|
||||||
position_values = [name, mgmt_driver, infra_driver]
|
position_values = [name]
|
||||||
extra_body = {
|
extra_body = {
|
||||||
'service_types': [{'service_type': 'vnfd'}],
|
'service_types': [{'service_type': 'vnfd'}],
|
||||||
'attributes': {'vnfd': 'vnfd'}
|
'attributes': {'vnfd': 'vnfd'}
|
||||||
|
|
|
@ -402,13 +402,6 @@ class Client(ClientBase):
|
||||||
_logger.warning("VNFD legacy templates are deprecated. Please "
|
_logger.warning("VNFD legacy templates are deprecated. Please "
|
||||||
"use NFV TOSCA templates.")
|
"use NFV TOSCA templates.")
|
||||||
body[self._VNFD]['service_types'] = [{'service_type': 'vnfd'}]
|
body[self._VNFD]['service_types'] = [{'service_type': 'vnfd'}]
|
||||||
_logger.warning(
|
|
||||||
"Passing infra_driver and mgmt_driver in the VNFD"
|
|
||||||
" API is deprecated. infra_driver will be automatically"
|
|
||||||
" derived from target vim type. mgmt_driver will be"
|
|
||||||
" derived from TOSCA template values.")
|
|
||||||
body[self._VNFD]['infra_driver'] = 'heat'
|
|
||||||
body[self._VNFD]['mgmt_driver'] = 'noop'
|
|
||||||
return self.post(self.vnfds_path, body)
|
return self.post(self.vnfds_path, body)
|
||||||
|
|
||||||
@APIParamsCall
|
@APIParamsCall
|
||||||
|
|
Loading…
Reference in New Issue