Skip to content

Commit 1295347

Browse files
Support CMCC Kilo
1 parent 2a194ce commit 1295347

5 files changed

Lines changed: 12 additions & 11 deletions

File tree

f5lbaasdriver/v2/bigip/disconnected_service.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
# limitations under the License.
1414
#
1515

16-
from neutron.db import segments_db
1716
from neutron.plugins.ml2 import db
1817
from neutron.plugins.ml2 import models
1918

@@ -52,8 +51,8 @@ def get_network_segment(self, context, agent_configuration, network):
5251
agent_configuration.get('tunnel_types', [])
5352
]
5453
# look up segment details in the ml2_network_segments table
55-
segments = segments_db.get_network_segments(context, network['id'],
56-
filter_dynamic=None)
54+
segments = db.get_network_segments(context, network['id'],
55+
filter_dynamic=None)
5756

5857
for segment in segments:
5958
LOG.debug("F5 disconnected service check segment: %s" % segment)

f5lbaasdriver/v2/bigip/driver_v2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@
2525
from neutron.callbacks import events
2626
from neutron.callbacks import registry
2727
from neutron.callbacks import resources
28+
from neutron.common import constants as q_const
2829
from neutron.extensions import portbindings
2930
from neutron.plugins.common import constants as plugin_constants
30-
from neutron_lib import constants as q_const
3131

3232
from neutron_lbaas.db.loadbalancer import models
3333
from neutron_lbaas.extensions import lbaas_agentschedulerv2

f5lbaasdriver/v2/bigip/exceptions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
from neutron_lib import exceptions as q_exc
17+
from neutron.common import exceptions as q_exc
1818

1919

2020
class F5LBaaSv2DriverException(q_exc.NeutronException):

f5lbaasdriver/v2/bigip/neutron_client.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@
1717

1818
from neutron.extensions import portbindings
1919

20-
from neutron_lib import constants as neutron_const
20+
from neutron.api.v2 import attributes as attrs
21+
from neutron.common import constants as neutron_const
2122

2223
from oslo_log import helpers as log_helpers
2324
from oslo_log import log as logging
@@ -38,7 +39,7 @@ def create_port_on_subnet(self, context, subnet_id=None,
3839
port = None
3940

4041
if not mac_address:
41-
mac_address = neutron_const.ATTR_NOT_SPECIFIED
42+
mac_address = attrs.ATTR_NOT_SPECIFIED
4243

4344
if subnet_id:
4445
try:

f5lbaasdriver/v2/bigip/plugin_rpc.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@
2525
from neutron_lbaas.db.loadbalancer import models
2626
from neutron_lbaas.services.loadbalancer import constants as nlb_constant
2727

28-
from neutron_lib import constants as neutron_const
28+
from neutron.api.v2 import attributes as attrs
29+
from neutron.common import constants as neutron_const
2930

3031
from oslo_log import helpers as log_helpers
3132
from oslo_log import log as logging
@@ -512,7 +513,7 @@ def create_port_on_subnet(self, context, subnet_id=None,
512513
subnet_id
513514
)
514515
if not mac_address:
515-
mac_address = neutron_const.ATTR_NOT_SPECIFIED
516+
mac_address = attrs.ATTR_NOT_SPECIFIED
516517
fixed_ip = {'subnet_id': subnet['id']}
517518
if fixed_address_count > 1:
518519
fixed_ips = []
@@ -680,7 +681,7 @@ def create_port_on_network(self, context, network_id=None,
680681
)
681682

682683
if not mac_address:
683-
mac_address = neutron_const.ATTR_NOT_SPECIFIED
684+
mac_address = attrs.ATTR_NOT_SPECIFIED
684685
if not host:
685686
host = ''
686687
if not name:
@@ -694,7 +695,7 @@ def create_port_on_network(self, context, network_id=None,
694695
'admin_state_up': True,
695696
'device_owner': 'network:f5lbaasv2',
696697
'status': neutron_const.PORT_STATUS_ACTIVE,
697-
'fixed_ips': neutron_const.ATTR_NOT_SPECIFIED
698+
'fixed_ips': attrs.ATTR_NOT_SPECIFIED
698699
}
699700
if device_id:
700701
port_data['device_id'] = device_id

0 commit comments

Comments
 (0)