Octavia API needs sorting support

Bug #1596628 reported by Michael Johnson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
octavia
Fix Released
High
Adam Harwell

Bug Description

As part of the "OpenStack LBaaS" (aka Neutron-LBaaS / Octavia merge) project we need to enable result sorting in the Octavia API server.
This is required for many reasons, among those:
1. It is needed to have feature parity with the existing neutron-lbaas API hosted through the neutron API server (Though not bug parity).
2. It is a part of the OpenStack API standard. https://specs.openstack.org/openstack/api-wg/guidelines/pagination_filter_sort.html

Changed in octavia:
assignee: nobody → Carlos Garza (carlos-garza)
Revision history for this message
Carlos Garza (carlos-garza) wrote :

I'm mimicking the code in neutron/api/api_common to try to get sorting to work. Hopefully we can use this for the filtering and pagination code as well.

Revision history for this message
Elena Ezhova (eezhova) wrote :

BTW, there is an API WG spec with guidelines on sorting and filtering [1], and also a table with current status of different components [2]. According to the latter doc, Neutron doesn't fully comply the rule "The caller may (but is not required to) specify a sort direction for each key. If a sort direction is not specified for a key, then a default is set by the server."

[1] https://specs.openstack.org/openstack/api-wg/guidelines/pagination_filter_sort.html#sorting
[2] https://wiki.openstack.org/wiki/API_Working_Group/Current_Design/Sorting

Revision history for this message
Carlos Garza (carlos-garza) wrote :

it appears that [2] recomments deprecating the design of the sort query parameters of [2]. I'll just mark that in this bug so that I don't forget that [2] implements a different sort query param format.

Revision history for this message
Michael Johnson (johnsom) wrote :

I would like to see us implement sorting in the current OpenStack standard way and not pull forward any neutron bugs, etc. So this bug should track the effort to add sorting to the Octavia API in the way specified by the api-wg.

Fixes to neutron/neutron-lbaas would be a different bug and patch.

description: updated
Changed in octavia:
assignee: Carlos Garza (carlos-garza) → Adam Harwell (adam-harwell)
status: New → In Progress
Changed in octavia:
milestone: none → milestone-1
Changed in octavia:
assignee: Adam Harwell (adam-harwell) → Lubosz Kosnik (diltram)
Changed in octavia:
assignee: Lubosz Kosnik (diltram) → Adam Harwell (adam-harwell)
Changed in octavia:
assignee: Adam Harwell (adam-harwell) → Michael Johnson (johnsom)
Changed in octavia:
assignee: Michael Johnson (johnsom) → Adam Harwell (adam-harwell)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to octavia (master)

Reviewed: https://review.openstack.org/382147
Committed: https://git.openstack.org/cgit/openstack/octavia/commit/?id=9bfa58af9f14e7830a737cdcc2f62e3061b7cbfd
Submitter: Jenkins
Branch: master

commit 9bfa58af9f14e7830a737cdcc2f62e3061b7cbfd
Author: Carlos D. Garza <email address hidden>
Date: Tue Oct 4 20:58:01 2016 -0500

    Implement sorting and pagination for octavia

    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 <email address hidden>
    Co-Authored-By: Lubosz "diltram" Kosnik <email address hidden>
    Closes-Bug: #1596628
    Closes-Bug: #1596625

Changed in octavia:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/octavia 1.0.0.0b2

This issue was fixed in the openstack/octavia 1.0.0.0b2 development milestone.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.