neutron/neutron/tests/unit/extensions
Doug Wiegley f9cbd939b9
Fix performance regression adding rules to security groups
Sometime between liberty and pike, adding rules to SG's got
slow, and slower with every rule. Streamline the rule create path,
and get close to the old performance back.

Two performance fixes:
1. Get rid of an n^2 duplicate check, using a hash table instead,
on bulk creates. This is more memory intensive than the previous loop,
but usable far past where the other becomes too slow to be useful.
2. Use an object existence check in a few places where we do not
want to load all of the child rules.

Also squashed in:
Restore tenant_id check on security group rule adds to previous semantic

We switched from swapping the tenant_id in the context to explicitly
checking the db column. Switch back, and a test that checks for
not breaking this rather odd behavior. At least, until we decide
to fix it as a bug.

Co-Authored-By: William Hager <whager@salesforce.com>
Change-Id: I34e41a128f28211f2e7ab814a2611ce22620fcf3
Closes-bug: 1810563
(cherry picked from commit 2eb31f84c9)
(squashed patch from commit bd4c291cdf)
2019-02-01 21:10:21 -07:00
..
__init__.py Empty files should not contain copyright or license 2014-10-20 00:50:32 +00:00
base.py ExtensionTestCase: register correct core plugin 2017-03-28 02:46:45 +00:00
extendedattribute.py Use ExtensionDescriptor from neutron-lib 2016-12-02 14:16:06 -05:00
extensionattribute.py Use ExtensionDescriptor from neutron-lib 2016-12-02 14:16:06 -05:00
foxinsocks.py Consume ServicePluginBase from neutron-lib 2017-03-17 12:06:57 -06:00
test_address_scope.py use neutron-lib callbacks 2017-04-26 12:12:53 -06:00
test_agent.py Spin off context module 2017-03-06 16:25:29 +00:00
test_availability_zone.py Spin off context module 2017-03-06 16:25:29 +00:00
test_data_plane_status.py use core resource attribute constants from neutron-lib 2017-06-30 06:25:36 -06:00
test_default_subnetpools.py Fix call a method of extension class 2017-03-30 16:37:23 +09:00
test_dns.py Fix call a method of extension class 2017-03-30 16:37:23 +09:00
test_external_net.py use service type constants from neutron_lib plugins 2017-06-27 15:16:05 -06:00
test_extra_dhcp_opt.py use extra_dhcp_opt api-def from neutron-lib 2017-05-31 15:06:35 +00:00
test_extraroute.py Spin off context module 2017-03-06 16:25:29 +00:00
test_flavors.py Use flake8-import-order plugin 2017-07-05 03:15:27 +00:00
test_l3.py Disallow router interface out of subnet IP range 2018-07-20 23:26:01 +02:00
test_l3_ext_gw_mode.py Integration of IPAllocation 2017-06-21 17:33:41 +09:00
test_network_ip_availability.py Fix incorrect comments in ip availability test 2017-06-08 09:16:22 +08:00
test_portsecurity.py use neutron-lib port security api-def 2017-05-01 11:45:42 -06:00
test_providernet.py use service type constants from neutron_lib plugins 2017-06-27 15:16:05 -06:00
test_quotasv2.py Decouple tests from default quota size option values 2017-03-07 19:35:51 +00:00
test_quotasv2_detail.py Allow unprivileged users to get their quota usage 2017-08-12 18:21:20 +00:00
test_router_availability_zone.py use service type constants from neutron_lib plugins 2017-06-27 15:16:05 -06:00
test_securitygroup.py Fix performance regression adding rules to security groups 2019-02-01 21:10:21 -07:00
test_segment.py Move segment deletion back to PRECOMMIT_DELETE 2017-12-06 15:46:04 +00:00
test_servicetype.py Spin off context module 2017-03-06 16:25:29 +00:00
test_subnet_service_types.py Always pass device_owner to _ipam_get_subnets() 2018-02-17 18:32:02 +00:00
test_tag.py Tag mechanism supports resources with standard attribute 2017-07-25 08:14:04 +09:00
test_timestamp.py Use flake8-import-order plugin 2017-07-05 03:15:27 +00:00
test_vlantransparent.py Replace six.iteritems with dict.items(Part-1) 2017-04-17 14:08:47 +08:00
v2attributes.py Use ExtensionDescriptor from neutron-lib 2016-12-02 14:16:06 -05:00