neutron/neutron/db/migration
John Schwarz b1ec8d523d Add binding_index to RouterL3AgentBinding
The patch proposes adding a new binding_index to the
RouterL3AgentBinding table, with an additional Unique Constraint that
enforces a single <router_id, binding_id> per router. This goes a long
way into fixing 2 issues:

1. When scheduling a non-HA router, we only use binding_index=1. This
   means that only a single row containing that router_id can be
   committed into the database. This in fact prevents over-scheduling of
   non-HA routers. Note that for the HA router case, the binding_index
   is simply copied from the L3HARouterAgentPortBinding (since they are
   always created together they should always match).

2. This sets the ground-work for a refactor of the l3 scheduler - by
   using this binding and db-based limitation, we can schedule a router
   to agents using the RouterL3AgentBinding, while postponing the
   creation of L3HARouterAgentPortBinding objects for the agents until
   they ask for it (using sync_routers). This will be a major
   improvement over todays "everything can create
   L3HARouterAgentPortBinding" way of things).

Closes-Bug: #1535557
Change-Id: I3447ea5bcb7c57365c6f50efe12a1671e86588b3
2016-09-02 11:17:47 +00:00
..
alembic_migrations Add binding_index to RouterL3AgentBinding 2016-09-02 11:17:47 +00:00
models Switch to neutron-lib for model_base 2016-08-31 11:12:18 -04:00
README Support for independent alembic branches in sub-projects 2015-08-12 23:50:58 -04:00
__init__.py Add function to remove constraints from database 2016-07-12 07:26:18 +00:00
alembic.ini Ease debugging alembic by passing proper scripts path in alembic.ini 2015-06-22 15:44:55 +02:00
autogen.py Revert "Support unique labels for alembic branches" 2016-07-06 16:51:04 +00:00
cli.py Revert "Support unique labels for alembic branches" 2016-07-06 16:51:04 +00:00
connection.py neutron-db-manage: add has_offline_migrations command 2016-01-22 13:55:40 +00:00

README

See doc/source/devref/alembic_migrations.rst

Rendered at
http://docs.openstack.org/developer/neutron/devref/alembic_migrations.html