]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Moves the HA resource creations outside of transaction
authorSylvain Afchain <sylvain.afchain@enovance.com>
Fri, 26 Sep 2014 13:49:43 +0000 (13:49 +0000)
committerSylvain Afchain <sylvain.afchain@enovance.com>
Mon, 20 Oct 2014 08:27:37 +0000 (08:27 +0000)
commitccd650732729451aa8e5ce3401f9570c70c4f066
tree7066ecedbd55e2b9bba275da990fce1daebeecd4
parent1aaa8b34466b0567c6a5ea0b607f1ac324ee5dfa
Moves the HA resource creations outside of transaction

Currently the HA resources are created in the
_create_router_db which includes calls to
the plugin and generates RPC calls. Even if the
resource creations are outside of any transaction
from the _create_router_db point of view, this
method is  called in a transaction from the
create_router method.
This patch moves the resource creations to the
create_router method outside the transaction.
The failures are handled as previously with
a try/expect.

Change-Id: If8fcfd012f8e992175e49bbefb2ae667881a620a
Closes-bug: #1374461
neutron/db/l3_hamode_db.py
neutron/tests/unit/db/test_l3_ha_db.py
neutron/tests/unit/test_l3_schedulers.py