From 751d1ca08b92109fba50ec8d85b2cb9a1c23f286 Mon Sep 17 00:00:00 2001 From: Pulkit vajpayee Date: Tue, 13 Jun 2023 16:08:42 +0000 Subject: [PATCH] Remove Monkey patch Change-Id: Ic89dc4ccc174effe923e4e4db1d484990afb8141 --- .../neutron/plugins/ml2plus/patch_neutron.py | 20 ------------------- requirements.txt | 1 + 2 files changed, 1 insertion(+), 20 deletions(-) diff --git a/gbpservice/neutron/plugins/ml2plus/patch_neutron.py b/gbpservice/neutron/plugins/ml2plus/patch_neutron.py index a8c5143cc..f817ecec2 100644 --- a/gbpservice/neutron/plugins/ml2plus/patch_neutron.py +++ b/gbpservice/neutron/plugins/ml2plus/patch_neutron.py @@ -57,23 +57,3 @@ from oslo_db.sqlalchemy import exc_filters exc_filters.LOG.exception = exc_filters.LOG.debug - - -from neutron.db import db_base_plugin_v2 as db_v2 - - -patched_create_network_db = db_v2.NeutronDbPluginV2.create_network_db - - -# REVISIT: this is a monkey patch of the upstream DB layer call. -# https://review.opendev.org/#/c/679399/ set the default value -# for the network's MTU to the constant defined in neutron-lib, if -# one wasn't specified. This modifies that behavior by explicitly -# setting it to 0, if not set already, avoiding this behavior. -def create_network_db(self, context, network): - n = network['network'] - n.update({'mtu': n.get('mtu', 0)}) - return patched_create_network_db(self, context, network) - - -db_v2.NeutronDbPluginV2.create_network_db = create_network_db diff --git a/requirements.txt b/requirements.txt index 4eed8a1d7..98732ad15 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,6 @@ # The order of packages is significant, because pip processes them in the order # of appearance. Changing the order has an impact on the overall integration # process, which may cause wedges in the gate later. +neutron>=20.3.1 pbr>=4.0.0 # Apache-2.0 pyOpenSSL>=16.2.0