neutron-lbaas performance hit due to unnecessary lazy sql calls

Bug #1706466 reported by Erik Olof Gunnar Andersson
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
octavia
Fix Released
Medium
Jude Cross

Bug Description

In neutron-lbaas many ORM relationships are configured to be lazy joined. This is causing slow api calls.

The problem is that a call to get a load balancer or a list of load balancers, will recursively get all listeners, pools and members belonging to those load balancer(s). If lazy wasn't used, the initial sql query would instantly retrieve all objects belonging to that load balancer, but as lazy joined is used, it will initially only get the load balancer data, and later have to do additional sql calls to get the remaining objects.

It's worth mentioning that even if cli calls only show limited data on a load balancer, internally the same call would return data containing listeners, pools and members. Pretty much negating any improvements lazy joined queries brings to the table.

Changed in octavia:
status: New → Triaged
importance: Undecided → Medium
Changed in octavia:
assignee: nobody → Erik Olof Gunnar Andersson (eandersson)
status: Triaged → In Progress
Changed in octavia:
assignee: Erik Olof Gunnar Andersson (eandersson) → Jude Cross (problem-v)
Changed in octavia:
assignee: Jude Cross (problem-v) → Erik Olof Gunnar Andersson (eandersson)
Changed in octavia:
assignee: Erik Olof Gunnar Andersson (eandersson) → Jude Cross (problem-v)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-lbaas (master)

Reviewed: https://review.openstack.org/477698
Committed: https://git.openstack.org/cgit/openstack/neutron-lbaas/commit/?id=7e35b183f925ad744cfcff5f405df131ad1d5f66
Submitter: Zuul
Branch: master

commit 7e35b183f925ad744cfcff5f405df131ad1d5f66
Author: Erik Olof Gunnar Andersson <email address hidden>
Date: Mon Jun 26 15:31:23 2017 -0700

    Remove unnecessary lazy-loaded queries

    This patch removes lazy-load queries to speed up database
    operations when using neutron-lbaas.

    Change-Id: I9d67f0966561baaefb50ae97b943ff6593e194eb
    Closes-Bug: #1706466

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

This issue was fixed in the openstack/neutron-lbaas 12.0.0.0b3 development milestone.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron-lbaas (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/545796

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-lbaas (stable/pike)

Reviewed: https://review.openstack.org/545796
Committed: https://git.openstack.org/cgit/openstack/neutron-lbaas/commit/?id=606ec87a44162629ebfce4d279535124433b08fc
Submitter: Zuul
Branch: stable/pike

commit 606ec87a44162629ebfce4d279535124433b08fc
Author: Erik Olof Gunnar Andersson <email address hidden>
Date: Mon Jun 26 15:31:23 2017 -0700

    Remove unnecessary lazy-loaded queries

    This patch removes lazy-load queries to speed up database
    operations when using neutron-lbaas.

    Change-Id: I9d67f0966561baaefb50ae97b943ff6593e194eb
    Closes-Bug: #1706466
    (cherry picked from commit 7e35b183f925ad744cfcff5f405df131ad1d5f66)

tags: added: in-stable-pike
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron-lbaas 11.0.3

This issue was fixed in the openstack/neutron-lbaas 11.0.3 release.

Revision history for this message
Jan Zerebecki (jan-zerebecki) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron-lbaas (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/624158

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron-lbaas (stable/ocata)

Change abandoned by "Elod Illes <email address hidden>" on branch: stable/ocata
Review: https://review.opendev.org/c/openstack/neutron-lbaas/+/624158
Reason: neutron-lbaas's stable/ocata branch is tagged as End of Life (ocata-eol). To be able to delete the branch, every open patch need to be abandoned.

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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