OpenStack Networking (Neutron)
Go to file
Bence Romsics 10191fd817 Retry trunk status updates failing with StaleDataError
This is an approximate partial fix to #1828375.

update_trunk_status and update_subport_bindings rpc messages are
processed concurrently and possibly out of order on the server side.
Therefore they may race with each other.

The status update race combined with
1) the versioning feature of sqlalchemy used in the standardattributes
   table and
2) the less than serializable isolation level of some DB backends (like
   MySQL InnoDB)
does raise StaleDataErrors and by that leaves some trunk subports in
DOWN status.

This change retries the trunk status update (to BUILD) blindly when
StaleDataError was caught. In my local testbed this practically
fixes #1828375.

However theoretically the retry may cover up other real errors (when the
cause of the StaleDataError was a different status not just a different
revision count).

To the best of my understanding a proper fix would entail guaranteeing
the in order processing of the above rpc messages - which likely won't
ever happen.

I'm not sure at all if this change is worth merging - let me know what
you think.

Conflicts:
    neutron/services/trunk/rpc/server.py
    neutron/tests/unit/services/trunk/rpc/test_server.py

Change-Id: Ie581809f24f9547b55a87423dac7db933862d66a
Partial-Bug: #1828375
(cherry picked from commit 618e24e241)
(cherry picked from commit d090fb9a3c)
2019-07-31 07:24:46 +00:00
api-ref Fix some typos 2016-06-28 22:46:19 +02:00
bin Use os-xenapi for neutron when XenServer as hypervisor 2017-03-30 18:33:37 +00:00
devstack DevStack: OVS: Only install kernel-* packages when needed 2018-11-23 10:23:12 +00:00
doc neutron.conf needs lock_path set for router to operate 2019-04-16 14:27:33 +00:00
etc Fix creating policy rules from subattributes. 2019-05-10 13:38:05 +00:00
neutron Retry trunk status updates failing with StaleDataError 2019-07-31 07:24:46 +00:00
playbooks/legacy OpenDev Migration Patch 2019-04-19 19:38:53 +00:00
rally-jobs Switch rally job from q-* to neutron-* service names 2018-01-09 12:12:48 -08:00
releasenotes Add custom ethertype processing 2019-07-01 11:01:56 +00:00
tools Disable IPv6 forwarding by default on HA routers 2018-06-03 19:10:40 +00:00
.coveragerc Cleanup coverage configuration 2016-10-17 17:06:19 +05:30
.gitignore Added zuulv3 jobs for testing neutron tempest plugin 2017-11-13 09:30:36 +05:30
.gitreview OpenDev Migration Patch 2019-04-19 19:38:53 +00:00
.mailmap Add mailmap entry 2014-05-16 13:40:04 -04:00
.pylintrc Update pylint disable list to pass pylint 1.7.1 checks 2017-06-08 09:49:46 +00:00
.stestr.conf Fix post gate hook to accommodate for new os-testr 2017-09-12 14:20:12 -06:00
.testr.conf Allow more time for DB migration tests 2016-09-21 20:54:41 -04:00
.zuul.yaml OpenDev Migration Patch 2019-04-19 19:38:53 +00:00
CONTRIBUTING.rst Update link for contribution 2017-08-31 16:44:51 +02:00
HACKING.rst Update the documentation link for doc migration 2017-07-22 18:46:13 +09:00
LICENSE Adding Apache Version 2.0 license file. This is the official license agreement under which Quantum code is available to 2011-08-08 12:31:04 -07:00
README.rst Correct tag link in README 2017-08-03 09:47:25 +08:00
TESTING.rst Compile ovs for ovsfw to avoid ovs-vswitchd core dumps 2018-02-13 14:59:58 +00:00
babel.cfg Use babel to generate translation file 2013-01-24 00:20:32 +08:00
bindep.txt Add libffi-dev to bindep.txt 2017-06-13 19:26:49 +00:00
requirements.txt metadata: use requests for comms with nova api 2019-06-14 08:16:35 +01:00
setup.cfg Add enforcer logic for neutron policy 2019-04-08 16:31:37 +00:00
setup.py Updated from global requirements 2017-03-04 11:19:58 +00:00
test-requirements.txt cap bandit in test-requirements.txt 2018-08-25 23:04:56 +02:00
tox.ini Fix pep8 errors 2018-04-12 01:31:55 +09:00

README.rst

Team and repository tags

image

Welcome!

To learn more about neutron:

Get in touch via email. Use [Neutron] in your subject.

To learn how to contribute:

CONTRIBUTING.rst