-
Notifications
You must be signed in to change notification settings - Fork 7
feat(neutron): dynamic lookup network nodeId #1377
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
0a15219 to
e72d9aa
Compare
e72d9aa to
cfbcc73
Compare
cardoe
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Honestly the big O on this is gonna be costly. I would change this around to not get all trunks and walk them and call Ironic over and over again. You can call Ironic once for the gateway node to get its ID then get the ports owned by that ID. Then get the trunks owned by those ports. Now you've got a much smaller list to iterate over.
In the current code if we have 1000 trunk ports (which isn't even the possible max for a site) you would make 1000 calls to Ironic inside of a function that's expected to complete in 20 seconds or less.
637d1ea to
2d5f218
Compare
98e232d to
3813b60
Compare
|
|
||
| # Get all ports and filter by binding_host_id | ||
| # Note: Port.get_objects doesn't support filtering by binding_host_id directly | ||
| all_ports = port_obj.Port.get_objects(context) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is going to be insanely expensive as well as things scale as well. I'll have to look through what a better filter is going to be.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
now querying PortBinding objects for each host
8b2d497 to
36b0d96
Compare
36b0d96 to
6597cbb
Compare
Previously, the network node trunk ID had to be manually configured in ml2 config. This had operational overhead and made the system less flexible when underling nodes used to deploy neutron is changed.
6597cbb to
5119646
Compare
Dynamic Network Node Trunk Discovery
Implements automatic discovery of the network node trunk ID via OVN Gateway agent, eliminating the need for manual configuration.
Problem
Previously, the network node trunk ID had to be hardcoded.
Solution
Added
fetch_network_node_trunk_id()function that dynamically discovers the trunk by:host_uuid=port binding_host_id)Equivalent openstack cli commands network_trunk_id.sh