]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Don't call add_ha_port inside a transaction
authorKevin Benton <blak111@gmail.com>
Thu, 24 Dec 2015 09:37:10 +0000 (01:37 -0800)
committerKevin Benton <blak111@gmail.com>
Thu, 24 Dec 2015 17:55:06 +0000 (09:55 -0800)
commita8c715ab0fae82563252e815a12ddeb37ee5cc23
treebc057e2532c35023e7a20145aa221a7cc965db74
parent1a0cbdff7800e2ecb030a69da1b8e7c9d85d4ad8
Don't call add_ha_port inside a transaction

Calling add_ha_port inside a transaction will break the delete_port
error recovery logic. This patch prevents the scheduler from doing
that. It also adds a note to add_ha_port and a runtime check to
prevent the function from working with an active transaction.

Change-Id: I39e2bb70527a8ff4a47668f44abb81d0fede3786
Closes-Bug: #1529037
neutron/db/l3_agentschedulers_db.py
neutron/db/l3_hamode_db.py
neutron/scheduler/l3_agent_scheduler.py
neutron/tests/unit/db/test_l3_hamode_db.py