From 6885833e20ecf8183fad94dcd0d0973c8ae1a837 Mon Sep 17 00:00:00 2001 From: Salvatore Orlando Date: Mon, 25 Feb 2013 11:37:34 +0100 Subject: [PATCH] Remove network type validation from provider networks extension Bug 1133064 As the set of valid network types for the provider networks extension depends on the particular plugin, validation should be performed there. Change-Id: I3ce5762458bc553625a458ace80072bd804e31f0 --- quantum/extensions/providernet.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/quantum/extensions/providernet.py b/quantum/extensions/providernet.py index 1422fbad46..b37436c25f 100644 --- a/quantum/extensions/providernet.py +++ b/quantum/extensions/providernet.py @@ -18,19 +18,14 @@ from quantum.api import extensions from quantum.api.v2 import attributes - NETWORK_TYPE = 'provider:network_type' PHYSICAL_NETWORK = 'provider:physical_network' SEGMENTATION_ID = 'provider:segmentation_id' -# TODO(salvatore-orlando): Devise a solution for allowing plugins -# to alter the set of allowed values -NETWORK_TYPE_VALUES = ['flat', 'gre', 'local', 'vlan', 'stt'] - EXTENDED_ATTRIBUTES_2_0 = { 'networks': { NETWORK_TYPE: {'allow_post': True, 'allow_put': True, - 'validate': {'type:values': NETWORK_TYPE_VALUES}, + 'validate': {'type:string': None}, 'default': attributes.ATTR_NOT_SPECIFIED, 'is_visible': True}, PHYSICAL_NETWORK: {'allow_post': True, 'allow_put': True,