Two frequently called functions were querying the routerport table
and the corresponding ports just to get the port ID. Then they were
calling get_ports again with those port IDs, resulting in two queries
to the port table when there should have only been one.
This eliminates the second call to get_ports since all of the necessary
data hase been retrieved from the port table.
Change-Id: I806e9c380b7de048fe084b2baf4b6f92ab0edf6b
Partial-Bug: #1445412
(cherry picked from commit 3310c3c3d4c05c0d13f32f08f978ba4813e2a39a)
Reviewed: https:/ /review. openstack. org/175591 /git.openstack. org/cgit/ openstack/ neutron/ commit/ ?id=4a69a64c8a5 c89970c5216c060 ad3e6c79e3cdcc
Committed: https:/
Submitter: Jenkins
Branch: stable/juno
commit 4a69a64c8a5c899 70c5216c060ad3e 6c79e3cdcc
Author: Kevin Benton <email address hidden>
Date: Fri Apr 17 04:28:58 2015 -0700
Remove double queries in l3 DB get methods
Two frequently called functions were querying the routerport table
and the corresponding ports just to get the port ID. Then they were
calling get_ports again with those port IDs, resulting in two queries
to the port table when there should have only been one.
This eliminates the second call to get_ports since all of the necessary
data hase been retrieved from the port table.
Change-Id: I806e9c380b7de0 48fe084b2baf4b6 f92ab0edf6b d13f32f08f978ba 4813e2a39a)
Partial-Bug: #1445412
(cherry picked from commit 3310c3c3d4c05c0