Now that we are python3 only, we should move to using the built
in version of mock that supports all of our testing needs and
remove the dependency on the "mock" package.
Also see commit: Ifcaf1c21bea0ec3c35278e49cecc90a101a82113
Change-Id: I58da980351fe14357c210c02eb167a6c0af9d09e
This patch bumps the hacking, bandit and flake8 requirements to match
suit with similar work (ex [1]). It also updates the code to fix a few
new pep8 errors as well as adds a local tox target for
requirements-check-dev.
[1] https://review.opendev.org/#/c/658245/
Change-Id: I6caeb52dc1a5842338ec989a742ae5989608e0da
The get_updatable_fields function is now in neutron-lib. This patch
uses it rather than neutron's version of the function.
Change-Id: I155711e8b5fbd00833d8b59abf963a37dfb82b34
No need to patch neutron.objects.rbac_db.RbacNeutronDbObjectMixin
directly as the QoSPolicy OVO can be patched instead to remove the
dependency on neutron for the said. This patch does just that.
Change-Id: I530694c2fbb6d8394394bb6c889484b086ef7e04
This patch switches some of the direct reference that use
neutron.object.* modules over to use neutron-libs object registry
mechanism. The remaining reference to neutron objects will be addressed
after some additional work is done in neutron/neutron-lib to prep them.
Change-Id: Ie54b3d89d7029ab58498fd212736ed50977ccfc1
The neutron.common.rpc and exceptions were rehomed into neutron-lib and
are currently shimmed in neutron [1]
This patch consumes those modules from neutron-lib by using lib's
modules rather than neutrons.
[1] https://review.openstack.org/#/c/586525/
Change-Id: I18a697f1f2d8ddbd203f4435b4aab92a8b045a44
The NSX plugin does not support minimum BW rules.
This patch fails validation to prevent the creation of such rules.
Change-Id: I293dd5b6c659855bb939912370d72cdfd228a338
To access neutron objects we're moving to a dynamic plugin approach as
shown in the depends on and related patches.
This patch removes the imports of neutron.objects and uses neutron-lib
to load them instead. The remaining base object import will be addressed
later.
Depends-On: https://review.openstack.org/#/c/570060/
Change-Id: If1b140d95c039833ed4c144fb5f22328345dcd19
Commit Ia13568879c2b6f80fb190ccafe7e19ca05b0c6a8 added the ingress direction
BW rules.
This patch adds this support for the nSX-V3 QoS driver.
Depends-on: I34ae54b7c4b5810694e4ea05265421c8e4c903d8
Change-Id: I886896c4f9cc6b6456d72c3bec05ee76e18fea3b
Commit I44dd7e049eab054363063021f07ade81ef2d1a90 introduced the qos driver
precommit callbacks.
The NSX-V3 uses this callback to validate the BW rule limit and raise an exception
if the values are not supported by the backend.
Change-Id: Ie47c147cb5bb5ece01d8c272544994eacd295c52
Commit If5ff2b00fa828f93aa089e275ddbd1ff542b79d4 broke our unittests.
This patch fixes one of the tests that was previously changed to
avoid failing.
Change-Id: I3acc65cdeeb04db24f94c578dd0c8542637dddab
1. Use new enginefacade + l3_db breakage
Use reader and writer for db operations.
Partially-Implements blueprint: enginefacade-switch
2. Fix the callback pass for _prevent_l3_port_delete_callback
which was changed in commit Ia8ac4f510c003667cac95f76dea0e9ae55159878
3. QoS driver integration
Commit I5f747635be3fd66b70326d9f94c85a6736286bd2 removes the qos
notification driver.
Fixing the nsx-v and nsx-v3 to work only with the regular driver
4. _get_extra_routes_dict_by_router_id was removed by
Ia815d6c597730bd5cb49455e7409ca747a4cc22c
5. Floating IP association without subnet gateway IP
not supported by our plugins.
Added in commit If212c36d918ed57400a53f4b5fa1925b3d1fa6fd
Co-Authored-by: Adit Sarfaty <asarfaty@vmware.com>
Change-Id: I277ec5c38c5895337011019f71d586b254bfafde
The QoS implementation will stop using the RPC notifications in Pike.
See commit I2f166a43f0b980ad22617f8a3f7b4cc7f4786c48
This patch still supports it for backwards compatibility,
as well as a new driver to replace the RPC notifications.
Change-Id: I1f863bf91f712d4b12db753b13cc6b842b6918a4
Commit ab90bcab41655b2e210aea0e7581eb00b94ce5e5 broke the qos
unit tests.
This patch fix the tests.
But until the nsxlib fix If4782a11b74d72bcfda520fc1bd8eaddf464f5ec
will be in the used version, we have to skip the v3 update test.
Change-Id: I0efda11a887c8aea7d0c574226bc7bf9c1224a2c
When translating kbps->Mbps, or multiplying BW values by the
qos_peak_bw_multiplier, the result should be round in order to make
it more reasonable.
Change-Id: I69e9a6b6ea8bf5400308552f63713db5192209d9
1. new config class was added to allow all the classes to use the same object
2. removing dependencies of the neutron project in nsxlib code & tests
Change-Id: I15ace2ab60c1e4307d7076426c48ecc7a242e792
Separating the nsxlib apis into sub classed like
firewall, nsgroup, logical router, in order to make the api simpler
Change-Id: If67fae83515bd9e72aba116a78bb6afce1fe1ab9
- separate nsxlib/v3 constants and utils from the common ones
- separate the nsxlib/v3 tests
- update the nsxlib tests to cover create_firewall_rules
- remove all of the DB calls from the nsxlib/v3
- merge security & dfw_api classes
To be done in future patches:
- Avoid using the nsx configuration values directly
- Improve nsxlib interface (as Aaron suggested in If2fe1e014b78703ff0a9cdff1e4e8d45f3a4a16d)
Change-Id: I43257f557ce1e98b4f64b8157d723cc84ea58c2b
Commit 10ada71486db33c6cb69f35811d0ca3dc547eff0 broke the plugin
Commit 3aa89f4d818ab6705c56287b58a268e9fd5113c8 also broke the MH
Change-Id: Ib684536f6f61237ead8dbb46e40c722bb997d009
This patch refactors the current codebase to be more modular
and testable. The main changes are:
- pull out all of the profile setup logic from the __init__
method to it's own method _init_nsx_profiles method to make
testing the code easier.
- refactors the nsxlib.v3 code to break out all neutron related
exceptions and cleans up the interface so we can make nsxlib.v3
it's own standalone library eventually.
To improve:
- Currently we have nsxlib.v3.dfw_api and nsxlib.v3.firewall,
we should refactor this code and merge them into one file.
- refactor nsxlib to section of each api component to it's own
subclass. For example, nsxlib().port.create() rather than
nsxlib().create_port(). I think this would be most useful
for the security group/firewall integration as there are many
methods there that are needed to interface with nsx as the security
group feature is requires the most orchestration with nsx.
Breaking them into a sub class will make things more easy to understand.
Change-Id: If2fe1e014b78703ff0a9cdff1e4e8d45f3a4a16d
The NSX backend supports configuration of Peak Bandwidth, but if it is the same
as the average bandwidth, bursts are not allowed.
To fix this, we added a new configuration multiplier that will be used to
calculate the peak bw out of the neutron max bw.
Change-Id: I38ca66dfccdf09aca2ea31015174f0615cf83656
Adding support for the QoS DSCP marking rules for ports & networks,
and updating the backend QoS switching profile
Change-Id: I852ad20965c78c2d6011d350ca4f226f462d03fd
The backed does not allow max bandwidth < 1M.
Since the switch update is done from a notification callback,
we cannot fail the user action.
Instead, we log a warning, and use the minimal possible value.
Change-Id: Ic5aa7f933d7faf959bafd7f3f589fe29d6ded06d
Add support for the qos service in NSX|V3, including:
- Attach/Detach qos policy to a new or updated port
- Allow qos configuration on ports with internal networks only
- Update the switch profile with the BW limitations and tags
through the qos notification driver
- Add a new mapping db table to link the policy id and the
nsx-v3 switch profile id
For this to work, the following configuration should appear under the 'qos' section in the neutron.conf:
notification_drivers = vmware_nsxv3_message_queue
Change-Id: I4016de756cebe0032e61d3c2a5250527e44b49e4