Use plain routes list for user_data instead of stevedore
This patch adds user_data related routes by a plain list, instead of using stevedore. After all the Nova API endpoints moves to the plain routes list, the usage of stevedore for API loading will be removed from Nova. Partial-implement-blueprint api-no-more-extensions-pike Change-Id: Ie0f806b1231da7676b1929de1eaece7435afe58a
This commit is contained in:
committed by
Stephen Finucane
parent
d6b2dd9c16
commit
7626b8c6aa
@@ -13,27 +13,11 @@
|
||||
# under the License.
|
||||
|
||||
from nova.api.openstack.compute.schemas import user_data as schema_user_data
|
||||
from nova.api.openstack import extensions
|
||||
|
||||
|
||||
ALIAS = "os-user-data"
|
||||
ATTRIBUTE_NAME = 'user_data'
|
||||
|
||||
|
||||
class UserData(extensions.V21APIExtensionBase):
|
||||
"""Add user_data to the Create Server API."""
|
||||
|
||||
name = "UserData"
|
||||
alias = ALIAS
|
||||
version = 1
|
||||
|
||||
def get_controller_extensions(self):
|
||||
return []
|
||||
|
||||
def get_resources(self):
|
||||
return []
|
||||
|
||||
|
||||
# NOTE(gmann): This function is not supposed to use 'body_deprecated_param'
|
||||
# parameter as this is placed to handle scheduler_hint extension for V2.1.
|
||||
def server_create(server_dict, create_kwargs, body_deprecated_param):
|
||||
|
||||
@@ -88,7 +88,6 @@ nova.api.v21.extensions =
|
||||
security_groups = nova.api.openstack.compute.security_groups:SecurityGroups
|
||||
server_groups = nova.api.openstack.compute.server_groups:ServerGroups
|
||||
tenant_networks = nova.api.openstack.compute.tenant_networks:TenantNetworks
|
||||
user_data = nova.api.openstack.compute.user_data:UserData
|
||||
versions = nova.api.openstack.compute.versionsV21:Versions
|
||||
volumes = nova.api.openstack.compute.volumes:Volumes
|
||||
|
||||
|
||||
Reference in New Issue
Block a user