That syncs the Neutron code with the latest neutron-lib version
released (3.8.0).
This patch also adds the "network.ha" definition extension to
the tests core plugin.
NOTE: both LP bugs must be fixed in one patch to fix the unit
tests CI job.
Closes-Bug: #2033493
Closes-Bug: #2033508
Change-Id: Ie22d9bcb943205e20380b92dc33d48f398a86470
Since [1] (release 1.11.0), the Alembic operations "now enforce
keyword-only arguments as passed as keyword and not positionally"
(from the commit message).
This change is compatible with the previous versions (as confirmed
in the CI).
[1]df75e85489
Closes-Bug: #2019948
Change-Id: I71f59da65edc163aa5891cf0b0d9768d2538b7a7
neutron recently merged a commit enabling secure rbacs by default [1].
However this commit breaks the unittests of neutron-dynamic-routing.
To fix this we run multiple calls as admin, to allow them to succeed.
[1]: 670cc383e0
Closes-Bug: 2019097
Change-Id: Iadc9b819ce4aaf6029e77f53ce0616aa70119c70
Fix in the iteration to obtain address_scope linked to a subnet.
A network can be linked to more than one subnet (ipv4 and ipv6),
but if one of them does not have an address_scope, a null object
element access failure occurs.
Closes-bug: #1998104
Change-Id: Ic6d48a86043aaf4b458bb2230883a355fc841ee9
This fixes one query still being executed without context decorator,
which is causing the warning messages.
Related-Bug: #1980671
Closes-Bug: #1984238
Change-Id: I3eba9c919e153dd253988fee31a7cebaf3cad773
We want bindings to be fully static when using the StaticScheduler, so
do not run the periodic actions in that scenario.
Signed-off-by: Dr. Jens Harbott <harbott@osism.tech>
Change-Id: I2d874ce7170cdf3d81940dbe64960247b244fe87
Some more queries were being executed without context decorator,
leading to warning messages in the log.
Signed-off-by: Dr. Jens Harbott <harbott@osism.tech>
Change-Id: Ia66bcd0c90f0013d8bd7b2792759e3a6474bb5e0
Seems the original approach was too simple, it is causing some
tracebacks due to missing functions.
Closes-Bug: 1980235
Change-Id: I15ef7ec34eeccf4dfcce94b3bca2c853c4c4a609
One query was being executed without context decorator, leading to
warning messages in the log.
Closes-Bug: 1980671
Change-Id: Iebdc16e32193a6bc1eea5ea69c16f4aca5bd4526
This patch adds BGP service plugin RPC queue to RPC workers, like it is
done in other Neutron service plugins (l3-plugin, metering, etc.).
Without it some RPC requests and AMQP heartbeats are not processed in
time, causing AMQP connection dropping, and other unpredictable unwanted
behavior.
Closes-Bug: #1974057
Change-Id: I1b13f01ca47c8390f1361e01d5eb313fe2fc417f
The [1] change modified the behavior Neutron had, which used to
force the default config options to be automatically set.
Neutron-dynamic-routing expects some of the default config options
to be set while initializing some services. If they are not set
the initialization will fail [2].
This change invokes the method that sets such config options to
fix this initialization issue.
[1] https://review.opendev.org/c/openstack/neutron/+/837392
[2] https://paste.opendev.org/show/b8DReLeBPl9xTGooN8wu/
Releated-Bug: #1968606
Change-Id: Ib3bdf9b19feb68647460814cc973699622d0a6e8
* Updated callback functions port_callback,
floatingip_update_callback to include payload
* Fixed unit test cases
Change-Id: I84956d86ea45039a8841b2b1f4f02bf373efcef5
Signed-off-by: Manu B <manu.b@est.tech>
floating_ip_address may be a netaddr.IPAddress, and using '+'
to append the /32 suffix raises a TypeError. Explicitly convert to
string before appending the suffix.
Additionally, introduce a unit test case for floatingip_update_callback
to test that the error does not re-appear.
Closes-Bug: #1924237
Signed-off-by: Aggelos Kolaitis <akolaitis@admin.grnet.gr>
Change-Id: I98d266fb986649f1d14969c968baa2f93b469f73
With the removal of Python 2.x we can remove the unittest2 compat
wrappers and switch to assertCountEqual instead of assertItemsEqual
We have been able to use them since then, because
testtools required unittest2, which still included it. With testtools
removing Python 2.7 support [3][4], we will lose support for
assertItemsEqual, so we should switch to use assertCountEqual.
[1] - https://bugs.python.org/issue17866
[2] - https://hg.python.org/cpython/rev/d9921cb6e3cd
[3] - testing-cabal/testtools#286
[4] - testing-cabal/testtools#277
Change-Id: If5dc6ebffc7b4f031b0350a4fe77a660a1e7becf
This was added as a workaround until neutron gets a new release in [0].
We can switch to the new code now.
[0] I5661e8689d8e3ea861fdd0393e6f25c42cd324c3
Change-Id: Ie5b3d5c5b978494abf8d58f3f0a92cb95209fb56
With python3.x, classes can use 'metaclass=' instead of
'six.add_metaclass', 'six.integer_type' can be replaced
by 'int', 'six.string_type' and 'six.text_type' are just
'str'.
Change-Id: I40a020aa4a8e69a8dd7e800352dc54a9e694d500
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.
Change-Id: Ic767e59531bc2515cc1c20675792fe88300e3f30
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
Monkey patch the original current_thread to use the up-to-date _active
global variable. This solution is based on that documented at:
https://github.com/eventlet/eventlet/issues/592
Change-Id: I8e8a9ce5085b7915994317af5ea903cf8a39e809
Closes-Bug: #1863021
This patch switches from legacy job to a Zuul v3 job inheriting from
neutron-functional job definition.
Also cleaning up relevant files for legacy job
Change-Id: I419c98d58637d57c3a2436630dd787b17f9027d5
This patch removes all tempest tests from neutron-dynamic-routing
repository as all of them are now moved to neutron-tempest-plugin repo.
It also removes all tempest job definitions which are now replaced by
job neutron-tempest-plugin-dynamic-routing defined in
neutron-tempest-plugin repo directly.
Change-Id: I94a443c92fe2317ba2591ae3a227ec8df82ec294
This happened in [0], we need to add a partial workaround until a new
neutron release is made.
[0] https://review.opendev.org/288271
Change-Id: I5661e8689d8e3ea861fdd0393e6f25c42cd324c3
This patch switches the code over to the payload style of callbacks [1]
for ROUTER_GATEWAY events for those that are not using them yet.
The unit tests are also updated where needed to account for the
payload style callbacks and publish() method. Finally the patch
normalizes the passing of gateway IPs which are currently referred to
as 'gw_ips' and 'gateway_ips' depending on the event; now all events use
'gateway_ips'.
Depends-On: https://review.opendev.org/#/c/638274/
[1] https://docs.openstack.org/neutron-lib/latest/contributor/callbacks.html
Change-Id: I8f797f31b3413e4879400ad2832539314d6e9cfc
When a server is deleted before its floating IP has been disassociated,
the notification doens't contain a `last_known_router_id` key, which
results in a `KeyError` exception being thrown.
This commit gracefully handles this situation by setting
`last_router_id` to `None` when `last_known_router_id` is missing.
Change-Id: If127a33cec7ce6c4d264a191df37c30decab4daa
Closes-Bug: #1795816
This change ensures all CI jobs run against neutron-dynamic-routing
run with python 3 and all test code is compatible with python 3.
Change-Id: I77f940dca9239d710bb146e8cdf1d6058f2fbdd4
This patch removes all use of common_db_mixin. All methods of that
class are available in some form from neutron-lib and we are removing
the mixing from neutron soon.
Change-Id: I80d17a491d4468a94f4ae184f1b453f41cdf92a2