a4ba0c4fde
When we try to simultaneously attach same volume multiple times (multiattach), there are multiple attachments created, suppose attachA and attachB. If attachA marks the volume "reserved" then attachB can't proceed until the volume is in "in-use" or "available" state. We retry until we reach any of these states for which we use the retrying library. The retrying library defaults to 1 second retry[1] (5 times) which causes the original failure as the volume takes time to transition between "reserved" -> "in-use" state. This patch corrects it by adding an exponential retry time and max exponential retry i.e. 1: 2 ** 1 = 2 seconds 2: 2 ** 2 = 4 seconds 3: 2 ** 3 = 8 seconds 4: 2 ** 4 = 16 seconds (but max wait time is 10 seconds) 5: 2 ** 5 = 32 seconds (but max wait time is 10 seconds) [1] https://github.com/rholder/retrying/blob/master/retrying.py#L84 Closes-Bug: #1969373 Change-Id: I0094b044085d7f92b07ea86236de3b6efd7d67ea (cherry picked from commit |
||
---|---|---|
doc | ||
etc/glance | ||
glance_store | ||
releasenotes | ||
tools | ||
.gitignore | ||
.gitreview | ||
.stestr.conf | ||
.zuul.yaml | ||
LICENSE | ||
README.rst | ||
requirements.txt | ||
run_tests.sh | ||
setup.cfg | ||
setup.py | ||
test-requirements.txt | ||
tox.ini |
README.rst
Team and repository tags
Glance Store Library
Glance's stores library
This library has been extracted from the Glance source code for the specific use of the Glance and Glare projects.
The API it exposes is not stable, has some shortcomings, and is not a general purpose interface. We would eventually like to change this, but for now using this library outside of Glance or Glare will not be supported by the core team.
- License: Apache License, Version 2.0
- Documentation: https://docs.openstack.org/glance_store/latest/
- Source: https://opendev.org/openstack/glance_store/
- Bugs: https://bugs.launchpad.net/glance-store
- Release notes: https://docs.openstack.org/releasenotes/glance_store/index.html