]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Not creating HA router when not enough l3 agents
authorXu Han Peng <xuhanp@cn.ibm.com>
Thu, 9 Apr 2015 05:46:36 +0000 (01:46 -0400)
committerHong Hui Xiao <xiaohhui@cn.ibm.com>
Mon, 27 Apr 2015 05:09:32 +0000 (01:09 -0400)
commitc27310638bff452f54086cf027c442ad2a62e65f
tree6dcf0db772d207e578427fbdbd996524f824152d
parentc5188d8bf8493e4b075689f64251f85231e696a2
Not creating HA router when not enough l3 agents

Currently a HA router can be successfully created even when
there is not enough active l3 agent. Current code only checks
existing l3 agents but does not check if the agent is already
down.

This patch fixes this problem by checking only active l3 agents
when getting the number of agents for scheduling HA router.

Closes-Bug: 1420117

Change-Id: I6c1d108db1a7c93b61c0dd0b1ffee319a411b17a
neutron/db/l3_hamode_db.py
neutron/tests/unit/db/test_l3_hamode_db.py
neutron/tests/unit/scheduler/test_l3_agent_scheduler.py