[OVN] Use the MySQL backend for the `TestOvnNbSync
` tests
The ``TestOvnNbSync`` test cases perform intensive operations on both
the Neutron database and the OVN databases. These test are frequently
hitting an issue with the Neutron database, that in the functional test
is, by default, SQLite.
When a port is being deleted, the database raises an exception with the
following message:
DELETE failed.: oslo_db.exception.DBReferenceError:
(sqlite3.IntegrityError) FOREIGN KEY constraint failed
[SQL: DELETE FROM ports WHERE ports.id = ?]
[parameters: ('64720ac5-72a0-4e88-8193-fd54a97ccef3',)]
This resource (port) and the one referring to it (floating IP), have
been created and updated in previous API calls, thus the transactions
to the database should be commited and finished.
This patch is changing the database backend to MySQL, that should
provide better transaction isolation.
Closes-Bug: #2088423
Change-Id: If1da6c5992aa4635da5a4b5c6eaa06db56d693b4
(cherry picked from commit abb527d1e4
)
This commit is contained in:
parent
703ec0d487
commit
c6cd5c6e87
@ -42,9 +42,11 @@ from neutron.tests.functional import base
|
|||||||
from neutron.tests.unit.api import test_extensions
|
from neutron.tests.unit.api import test_extensions
|
||||||
from neutron.tests.unit.extensions import test_extraroute
|
from neutron.tests.unit.extensions import test_extraroute
|
||||||
from neutron.tests.unit.extensions import test_securitygroup
|
from neutron.tests.unit.extensions import test_securitygroup
|
||||||
|
from neutron.tests.unit import testlib_api
|
||||||
|
|
||||||
|
|
||||||
class TestOvnNbSync(base.TestOVNFunctionalBase):
|
class TestOvnNbSync(base.TestOVNFunctionalBase,
|
||||||
|
testlib_api.MySQLTestCaseMixin):
|
||||||
|
|
||||||
_extension_drivers = ['port_security', 'dns', 'qos', 'revision_plugin']
|
_extension_drivers = ['port_security', 'dns', 'qos', 'revision_plugin']
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user