This patch is covering an edge case that could happen when the number
of DHCP agents ("dhcp_agents_per_network") or L3 agents
("max_l3_agents_per_router") has been reduced and there are more agents
assigned than the current number. If the user removes any agent
assignation from a L3 router or a DHCP agent, it is possible to remove
first the lower binding assigned registers.
Now the method ``get_vacant_binding_index`` calculates the number of
agents bound and the number required. If a new one is needed, the
method returns first the lower binding indexes not used.
Closes-Bug: #2006496
Conflicts: neutron/common/_constants.py
Change-Id: I25145c088ffdca47acfcb7add02b1a4a615e4612
(cherry picked from commit 5250598c804a38c55ff78cfb457b73d1b3cd7e07)
Reviewed: https:/ /review. opendev. org/c/openstack /neutron/ +/873619 /opendev. org/openstack/ neutron/ commit/ 0920f17f476ce8b 398deea3e54e9f9 0b5251cfc9
Committed: https:/
Submitter: "Zuul (22348)"
Branch: stable/zed
commit 0920f17f476ce8b 398deea3e54e9f9 0b5251cfc9
Author: Rodolfo Alonso Hernandez <email address hidden>
Date: Wed Feb 8 13:14:19 2023 +0100
Improve scheduling L3/DHCP agents, missing lower binding indexes
This patch is covering an edge case that could happen when the number agents_ per_network" ) or L3 agents l3_agents_ per_router" ) has been reduced and there are more agents
of DHCP agents ("dhcp_
("max_
assigned than the current number. If the user removes any agent
assignation from a L3 router or a DHCP agent, it is possible to remove
first the lower binding assigned registers.
Now the method ``get_vacant_ binding_ index`` calculates the number of
agents bound and the number required. If a new one is needed, the
method returns first the lower binding indexes not used.
Closes-Bug: #2006496
Conflicts:
neutron/ common/ _constants. py
Change-Id: I25145c088ffdca 47acfcb7add02b1 a4a615e4612 55ff78cfb457b73 d1b3cd7e07)
(cherry picked from commit 5250598c804a38c