In https://review.opendev.org/#/c/613709/ octavia was
changed to use octavia-lib for a lot of API driver-related
code and deprecation warnings put in place. Now that
we're in Victoria remove all the deprecation shims and
use octavia-lib exclusively.
Change-Id: If92988150479a7daf465af5f8df22818664a0fce
E741 ambiguous variable name 'l'
Change 'l' to another variable in affected code.
Also had to set the latex_engine to 'xelatex' in doc/source/conf.py
in order to get past an openstackdocstheme change the broke the pdf
doc build.
Change-Id: Idd176e40ccf2a79832a5c99140bd30e5e1f9c0d8
* Make sure the user has access to the subnet in the request for
creating or updating pool member.
* Make sure the user has access to port or subnet or network for
creating load balancer
Story: 2007531
Task: 39339
Change-Id: I479019a911b5a1acfc1951d1cbbc2a351089cb4d
healthcheck middleware adds a /healthcheck url that allows
unauthenticated access to provide a simple check when running
octavia-api behind a load balancer
https://docs.openstack.org/oslo.middleware/latest/reference/healthcheck_plugins.html
Co-authored-by: Michael Johnson <johnsomor@gmail.com>
Change-Id: I10db6226750f7b7c703067d2ab82eea3a9875112
If the list of changes was empty, the worker would fail to fetch the
pool because it was retrieved implicitly from one of the changed
members. Pass it explicitly instead, and also short-circuit on NOOPs.
Story: 2006719
Task: 37090
Depends-On: https://review.opendev.org/#/c/688546/
Change-Id: I161a522abad4a2aa521ea46cb1065c5b05a2cd2e
If `additive_only` is set, don't do a complete delta -- skip delete and
only update and create members (making the call additive rather than a
full replacement). This will allow for adding members in batches without
wiping out existing members.
Change-Id: I5e47d64243667cfaa10430e12229099b508de40e
The current member API does not properly handle clearing/reseting
values on update. Some integer only fields, such as weight,
will accept null, but will store the value as "None". These will
will cause failures updating the amphora configuration.
This patch corrects this to appropriately handle None/null updates
to the member parameters.
Change-Id: I41038b1d8d882efa19d991c07dca47f06dcbb5ca
Story: 2005374
Task: 33523
In order to support Python 3.7, pylint has to be updated to 2.0.0
minimum. Newer versions of Pylint enforce additional checkers which can
be addressed with some code refactoring rather than silently ignoring
them in pylintrc; except useless-object-inheritance which is required to
be silented so that we stay compatible with Python 2.x.
Story: 2004073
Task: 27434
Change-Id: I52301d763797d619f195bd8a1c32bc47f1e68420
In some edge cases, when a request comes in to update a child
resource (member, HM, or l7rule), the API would not always make
sure the parent object (pool or l7policy) was in a mutable status.
This patch fixes this by checking the parent provisioning_status
before allowing a muttable change on a child object.
It also resolves two cases where a parent object status was not being
reset on a reverted flow.
Change-Id: I86f76bebce0993215fd34ccd33251ba1e6c325a9
Story: 2005249
Task: 30043
This patch fixes the Octavia v2 API "list" performance regression.
It also corrects some database model forward reference issues.
Co-Authored-By: Adam Harwell <flux.adam@gmail.com>
Change-Id: Ic110e0e73938743c1aba01aa28f393bae7141cbd
Story: 2002933
Task: 22920
We added the configuration option for reserved IP addresses that cannot
be used for load balancer member addresses, but the validation for
batch update members is missing.
This patch should also be backported to stable branches.
Change-Id: Ibd3145cfd8b92a494f7cceff10414d6e153136e9
Story: 2003413
When batch update members request only contains existing members
update, octavia-api raises exception because 'pool_id' is missing.
This patch should backport to stable branches.
Change-Id: I43a9af83a6615d3bffb7ec9c69f8d0b66c03fc97
Story: 2003608
Task: 24940
This patch adds a configuration option for reserved IP addresses that
cannot be used for load balancer member addresses. By default, this will
include the nova metadata service address 169.254.169.254.
Change-Id: I25de5ed5f6f35afc55dd1154c3e02934fddb100a
Story: 2003413
Task: 24555
The provider driver model changes the way updates are committed
to the database. This patch updates the amphora driver to work with
the new update model for provider drivers. Specificially that the
objects the amphora driver are using will already be updated.
This patch also corrects a bug in the batch member update that would
not update members correctly for provider drivers.
Change-Id: I03ba4d7755bbb0c034c75f29f4a59b1b708daac5
Commit Ide4beaf73bb99be5c3b4c71c12fecef3499f45d9 updated the drivers api spec.
This patch implements the new api for the update callbacks which needs the
original objet as well.
Change-Id: I530ec49acdc249a1f29e3e366eee70e29627a047
Commit Ide4beaf73bb99be5c3b4c71c12fecef3499f45d9 updated the drivers api spec.
This patch implements the new api for the delete callbacks.
Change-Id: Icbabe8b01864175112000b2b5aa769f750a9708b
The WSME package is not validating null/None fields correctly,
especially for Enum fields.
This patch strengthens the API validaton for health monitors.
It also removes an un-used status update method in the API
controllers.
Change-Id: I892dd81b166e9ab1a26bb80e8b0da1cb2e5c7482
This patch aligns all of Octavia to use oslo_log instead of the built
in python logging. This should provide consistent log formats.
It adds a hacking check to make sure "logging" doesn't come back into
the code.
Change-Id: I9b76c2bb5a5c396faf85df4606f2ca00f23de913
This patch adds provider driver support to the Octavia v2
Member API.
This patch also creates a provider driver for Octavia, fully
implementing the member methods.
Story: 1655768
Task: 5165
Depends-On: https://review.openstack.org/566199
Change-Id: I9101b06414a0106f898fb65da6da1ae6489d85ba
The LBaaSv2-API spec had this, and tempest seems to test for it.
We missed adding it when we implemented the v2 API in Pike.
Change-Id: I16c04b6f12fe4db9f1a2a0dc1d2b6fb54d24fd38
Backport-Candidate: Queens Pike
The exposed definition was incorrect due to a copy/paste error during
the original creation of these controllers, causing the field filter
list to be read as a single value. A side-effect of this was that the
filtering code still worked, but did an 'in' operation on one string
instead of a list.
This caused two bugs:
1) Multiple field filters were ignored, and only the first would be
returned.
2) The field matching would match inside of the field names, so
filtering for `id` would match `id`, `project_id`, etc. and return
extra fields.
Change-Id: Ibb509c1e487876b957ad02cd66cebebc178bef4d
Backport-Candidate: Queens Pike
Fixes the v2 API returning "DELETED" records until the amphora_expiry_age
timeout expired. The API will now immediately return a 404 HTTP status
code when deleted objects are requested. The API version has been raised
to v2.1 to reflect this change.
Change-Id: Iaf150240b0de32f75ba8cfe605293e3af086cc78
Story: 2001557
Task: 6501
This patch fixes the API to return a 204 for object delete calls on objects
already in the "DELETED" provisioning_status.
It also enables a few API tests that were marked for "skip" but are now valid.
Change-Id: Id11e059321b6c76a21b652037905cecba5721003
Story: 2001537
Task: 6344
Under certain conditions if an error occurred during an API request the
lock session could be left open. This patch corrects that by extending the
try block to include all calls with the lock open.
The test case was creating a second pool on a listener, which results in
a 409 conflict error, but the lock was left open.
Change-Id: I81e08775c515602f315aa8da32ff342f96c4a676
Also fix an incorrect exposure of /healthmonitors on /pools and a badly
ordered flow for member updates.
Change-Id: Id256ea94293519b75983f7a44945ac9bbbf25cd1
Implements: blueprint member-put-list
This patch implements API filtering based off of
query parameters passed to the Octavia API. Additonally
this patch implements field selection for the Octavia
API.
Change-Id: I9fe26abe37f464d9c028b8c476485007143d3b5c
Use glance sorting and pagination from inside the SQLAlchemy query
to handle the sorting and pagination for octavia.
Change-Id: I5489c5c89691b8871e32caf3f85ab1978bc3618c
Co-Authored-By: Adam Harwell <flux.adam@gmail.com>
Co-Authored-By: Lubosz "diltram" Kosnik <lubosz.kosnik@intel.com>
Closes-Bug: #1596628
Closes-Bug: #1596625
Still need to fix the entry-points for each individual type, but that
wasn't even in the original spec. Not sure if we even want that.
I think this may not do things EXACTLY how the old one did it, we'll
need to look into whether it matters, as we never published docs for it
and I don't think it ever actually worked properly in neutron-lbaas.
Also closing a few bugs that are only peripherally related, because we
(possibly me) forgot to tag them on the individual CRs, but I'm
considering them closed as of this patch. See below for my reasoning on
each individual bug, and feel free to post counter-arguments.
For #1673546 (single-call create): This is the obvious one!
For #1673499 (lb return pool object): Rolled into this patch as a matter
of course, abandoned the original fix as it is no longer relevant.
For #1544214 (root tags): All existing resources now have root tags. Any
new ones will also need root tags, but I would consider this bug closed.
For #1596636 (tenant facing API): Every object is now creatable via the
v2 API, so I would consider this to be complete. Quotas and some
additional work is being finished, but it's not necessary for this IMO.
For #1665446 (hm id): This was resolved in the HM patch, I just forgot
to close it, and including it here will ensure it is release-tracked.
For #1685789 (listener quota): Just shoving it in here as I do the
single-create quotas.
For #1685827 (hm quota): Same as listener quota.
Closes-Bug: #1673546
Closes-Bug: #1673499
Closes-Bug: #1544214
Closes-Bug: #1596636
Closes-Bug: #1665446
Closes-Bug: #1685789
Closes-Bug: #1685827
Depends-On: I3d86482a2999197a60a81d42afc5ef7a6e71e313
Change-Id: I4ff03593e1cfd8dca00a13c0550d6cf95b93d746
The endpoint are as follows:
- /v2.0/lbaas/l7policies/
- /v2.0/l7policies/
GET all - /<policy-id>/l7rules/
GET one - /<policy-id>/l7rules/<rule-id>
POST - /<policy-id>/l7rules/ {<body>}
PUT - /<policy-id>/l7rules/<rule-id> {<body>}
DELETE - /<policy-id>/l7rules/<rule-id>
Partially Closes-Bug: #1616701
Co-Authored-By: Shashank Kumar Shankar <shashank.kumar.shankar@intel.com>
Co-Authored-By: Adam Harwell <flux.adam@gmail.com>
Change-Id: I247988a2ea19a92f827756504a0ee46679bbc53b
This patch aligns Octavia v2 API for members with
lbaasv2.
GET all - /v2.0/lbaas/pools/<pool-id>/members
GET one - /v2.0/lbaas/pools/<pool-id>/members/<member-id>
POST - /v2.0/lbaas/pools/<pool-id>/members {<body>}
PUT - /v2.0/lbaas/pools/<pool-id>/members/<member-id> {<body>}
DELETE - /v2.0/lbaas/pools/<pool-id>/members/<member-id>
Also fixes a few bugs from previous API commits and refactors
some test code / adds missing tests.
Note: This changes the default operating_status of Members from OFFLINE
to NO_MONITOR in the *v1* API, if the pool has no Health Monitor.
I see this as a bug fix.
Co-Authored-By: Nakul Dahiwade <nakul.dahiwade@intel.com>
Co-Authored-By: Adam Harwell <flux.adam@gmail.com>
Partially-Implements: #1616642
Closes-Bug: #1678330
Closes-Bug: #1678336
Closes-Bug: #1678337
Change-Id: I0e15ab70afd5bbbc8b94db0dc9e64f13146003e8