neutron/neutron
Kevin Benton 96c67e22f9 Only ensure admin state on ports that exist
The linux bridge agent was calling ensure_port_admin state
unconditionally on ports in treat_devices_added_or_updated.
This would cause it to throw an error on interfaces that
didn't exist so it would restart the entire processing loop.

If another port was being updated in the same loop before this
one, that port would experience a port status life-cycle of
DOWN->BUILD->ACTIVE->BUILD->ACTIVE
                   ^ <--- Exception in unrelated port causes cycle
                          to start over again.

This causes the bug below because the first active transition will
cause Nova to boot the VM. At this point tempest tests expect the
ports that belong to the VM to be in the ACTIVE state so it filters
Neutron port list calls with "status=ACTIVE". Therefore tempest would
not get any ports back and assume there was some kind of error with
the port and bail.

This patch just makes sure the admin state call is skipped if the port
doesn't exist and it includes a basic unit test to prevent a regression.

Closes-Bug: #1523638
Change-Id: I5330c6111cbb20bf45aec9ade7e30d34e8dd16ca
2016-02-04 14:07:03 -08:00
..
agent Merge "Set default value for dnsmasq_local_resolv to False" 2016-02-03 04:11:00 +00:00
api Merge "Fail if required extensions are missing" 2016-01-30 17:21:25 +00:00
callbacks Add L3 Notifications To Enable BGP Dynamic Routing 2016-01-20 16:37:49 +00:00
cmd Don't decide web_framework before config parse 2016-01-22 17:44:35 -08:00
common Merge "Fix module's import order" 2016-01-23 07:46:22 +00:00
core_extensions Forbid attaching rules if policy isn't accessible 2015-08-12 09:52:33 +00:00
db Merge "Fix remove_router_from_l3_agent for 'dvr' mode agent" 2016-02-04 19:16:31 +00:00
debug Make neutron-debug command follow cliff command convention 2016-01-09 03:38:19 +09:00
extensions Merge "Fix remove_router_from_l3_agent for 'dvr' mode agent" 2016-02-04 19:16:31 +00:00
hacking Unify using assertIsInstance 2016-01-15 00:06:03 +08:00
ipam Fix module's import order 2016-01-22 06:38:42 -08:00
locale Imported Translations from Zanata 2016-01-19 06:21:49 +00:00
notifiers Add option for nova endpoint type 2015-12-10 08:40:36 +00:00
objects db_api: handle db objects that don't have 'id' as primary key 2016-01-21 19:23:14 +00:00
openstack Fix module's import order 2016-01-22 06:38:42 -08:00
pecan_wsgi Pecan: remove deprecated warning 2016-01-22 18:23:20 -08:00
plugins Only ensure admin state on ports that exist 2016-02-04 14:07:03 -08:00
quota ML2: Add tests to validate quota usage tracking 2015-12-09 15:17:23 -08:00
scheduler Remove bindings of DVR routers to L3 agents on compute nodes 2016-02-01 17:06:50 -07:00
server Merge "Support api_workers option when using pecan" 2016-02-04 18:49:44 +00:00
services External DNS driver reference implementation 2016-01-21 21:55:08 +00:00
tests Only ensure admin state on ports that exist 2016-02-04 14:07:03 -08:00
__init__.py Deprecate _ builtin translation function 2015-12-06 19:39:20 +09:00
_i18n.py Move i18n to _i18n, as per oslo_i18n guidelines 2015-12-01 19:29:10 -07:00
auth.py Consume ConfigurableMiddleware from oslo_middleware 2015-10-08 17:59:43 +00:00
context.py Trival: Remove unused logging import 2015-12-26 12:49:56 +08:00
i18n.py Move i18n to _i18n, as per oslo_i18n guidelines 2015-12-01 19:29:10 -07:00
manager.py Pecan controller loads service plugins 2016-01-12 12:28:54 -08:00
neutron_plugin_base_v2.py Fix module's import order 2016-01-22 06:38:42 -08:00
opts.py lb: ml2-agt: Separate AgentLoop from LinuxBridge specific impl 2016-01-28 11:00:43 +01:00
policy.py Raise RetryRequest on policy parent not found 2016-01-27 05:23:38 -08:00
service.py Support api_workers option when using pecan 2016-01-26 13:13:46 -08:00
version.py
worker.py Some minor misspellings in comment block. 2015-11-24 00:01:21 -06:00
wsgi.py Use _ from neutron._i18n 2015-12-06 19:39:04 +09:00