use project id api def from neutron-lib
The project ID extension's API defintion was rehomed into neutron-lib with commit Ibe69134a35d2f2927b194c8353c26b41c55c6954 This patch consumes the API definition by removing the rehomed code and using APIExtensionDescriptor for the extensions parent class. NeutronLibImpact Change-Id: Id6806dea66fb0462d3161651ddf6dfeee81368d4
This commit is contained in:
parent
a2569543a7
commit
3033c94d4b
@ -11,44 +11,21 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
from neutron_lib.api.definitions import project_id as apidef
|
||||
from neutron_lib.api import extensions as api_extensions
|
||||
|
||||
from neutron.api import extensions
|
||||
|
||||
|
||||
_ALIAS = 'project-id'
|
||||
|
||||
|
||||
class Project_id(api_extensions.ExtensionDescriptor):
|
||||
class Project_id(api_extensions.APIExtensionDescriptor):
|
||||
"""Extension that indicates that project_id is enabled.
|
||||
|
||||
This extension indicates that the Keystone V3 'project_id' field
|
||||
is supported in the API.
|
||||
"""
|
||||
|
||||
api_definition = apidef
|
||||
|
||||
extensions.register_custom_supported_check(
|
||||
_ALIAS, lambda: True, plugin_agnostic=True
|
||||
apidef.ALIAS, lambda: True, plugin_agnostic=True
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def get_name(cls):
|
||||
return "project_id field enabled"
|
||||
|
||||
@classmethod
|
||||
def get_alias(cls):
|
||||
return _ALIAS
|
||||
|
||||
@classmethod
|
||||
def get_description(cls):
|
||||
return "Extension that indicates that project_id field is enabled."
|
||||
|
||||
@classmethod
|
||||
def get_updated(cls):
|
||||
return "2016-09-09T09:09:09-09:09"
|
||||
|
||||
@classmethod
|
||||
def get_resources(cls):
|
||||
return []
|
||||
|
||||
def get_extended_resources(self, version):
|
||||
return {}
|
||||
|
Loading…
Reference in New Issue
Block a user