neutron/neutron/tests/unit/agent
Rodolfo Alonso Hernandez 577d5bd977 Improve "get_devices_with_ip" performance
As reported in LP#1896734, there is a limit in the size of information
that can be transmitted in one single message between an application
and the privsep daemon. The read socket buffer is limited in size;
a message exceeding this size will generate an exception.

In order to limit the amount of information to be sent, this patch
improves the performance of "get_devices_with_ip". In the previous
implementation, the whole list of network devices from a namespace
was retrieved. In some environments, the list of devices could be
so big that the list returned by "privileged.get_link_devices" can
exceed the read buffer size (as reported in the LP bug when the
OVS agent tries to retrieve the list of IP addresses in the system).

Now the function calls "privileged.get_ip_addresses", that returns
a much smaller list. This patch is also reducing the number of system
calls to just one; the previous implementation was retrieving first
the devices link information list (that method was returning a much
bigger blob) and then, per device, retrieving the IP address
information.

Change-Id: I97ada62484023b9833ed12afd68eb4c8d337fd1f
Related-Bug: #1896734
(cherry picked from commit a6cdf273c0)
2021-03-01 10:31:10 +00:00
..
common Merge "Improve terminology in the Neutron tree" 2020-08-28 14:06:18 +00:00
dhcp Process DHCP events in order if related 2021-02-07 10:04:58 +00:00
l2 Remove "six" library 2020-07-28 16:55:52 +00:00
l3 Update requirements for recent pip failures 2020-12-14 11:35:53 +01:00
linux Improve "get_devices_with_ip" performance 2021-03-01 10:31:10 +00:00
metadata metadata-ipv6: Accept link local address in X-Forwarded-For 2020-08-31 13:02:49 +02:00
ovn [OVN] Ensure metadata checksum 2021-01-28 11:42:30 +00:00
ovsdb Remove the dependency on the "mock" package 2020-04-28 18:05:37 -04:00
windows Remove "six" library 2020-07-28 16:55:52 +00:00
__init__.py Empty files should not contain copyright or license 2014-10-20 00:50:32 +00:00
test_agent_extensions_manager.py Remove the dependency on the "mock" package 2020-04-28 18:05:37 -04:00
test_resource_cache.py Remove the dependency on the "mock" package 2020-04-28 18:05:37 -04:00
test_rpc.py Remove the dependency on the "mock" package 2020-04-28 18:05:37 -04:00
test_securitygroups_rpc.py Upgrade RPC version of SecurityGroup*Rpc 2020-12-14 13:44:46 +00:00