Releasenote translation publishing is being prepared. 'locale_dirs'
needs to be defined in conf.py to generate translated version of the
release notes.
Change-Id: Ibf005a434417c7b6ad7b7bada27d45f3bf238db1
These tests did not mock imagebackend and left a temporary instances/
directory after completion. As imagebackend is not really used, just
mock it entirely instead of using a tempdir fixture.
TrivialFix
Change-Id: I5f084112757bedf9a5da546033d3a5fc68e68991
When block live migrate an instance with ephemerals an exception
FlavorDiskSmallerThanImage can be raised because the size used to
create the base ephemeral disk is the total size allowed by flavor
which can be greater than the size effectively requested by the
instance when spwaned.
Closes-Bug: #1628449
Change-Id: I264f5beb73d9b8ba441aec8f8a317b553a7e22c0
This adds a --until_complete flag to the db archive command, which will
attempt to run batches of max_rows continuously until archiving has
completed (or stops being able to archive anything). We also take care
to catch KeyboardInterrupt so that it will, if stopped, still print
the verbose report at the end. Instead of printing the table on each
iteration, we print some progress information and then provide a completed
summary table at the end of the run.
This also defaults max_rows to a sane value. The previous meaning of not
providing a value was "archive a whole table in a single operation",
which was useful only in the most simple of cases. Now that we have
a more reasonable "do it until you are done" mechanism, we default this
to 1000 rows for sanity, which also serves as the batch size for the
continuous mode.
Implements blueprint archive-deleted-rows-all
Change-Id: I2929c2f5b3116b63a4666b258bf078bc51d4e45a
While debugging a failed event delivery bug, I realized that our
logging of the event path leaves some ambiguity which makes it
difficult to follow. This adds the instance host to the existing
debug message on the API side, which helps to identify that events
are being sent to the right (or wrong) host. Further, which logs
a warning in the case where a compute host receives an instance
message when no thread was waiting for it.
Change-Id: I9a1461493a19750fe5dc11869cfa33d2e6fd3c6f
We were misinterpreting the return value of blockJobInfo. Most
immediately we were expecting it to return an integer, which has never
been the case. blockJobInfo also raises an exception on error. Note
that the implementation of abort_on_error has always expected an
integer return value, and exceptions have never been handled, which
means that abort_on_error has always been a no-op, and exceptions have
never been swallowed. As this is also the most intuitive behaviour, we
make it explicit by removing abort_on_error. Any exception raised by
blockJobInfo will continue to propagate unhandled.
We were obfuscating the return value indicating that the job did not
exist, {}, by populating a BlockDeviceJobInfo with fake values. We
de-obfuscate this by returning None instead, which is unambiguous.
wait_for_job() was misnamed, as it does not wait. This is renamed to
is_job_complete() to be less confusing. Note that the logic is
reversed.
After discussion with Eric Blake of the libvirt team (see review
comments: https://review.openstack.org/#/c/375652/), we are now
confident asserting that if no job exists then it has completed
(although we are still not sure that it succeeded). Consequently we
remove the wait_for_job_clean parameter, and always assume that no job
means it has completed. Previously this was implicit because no job
meant a defaulted BlockDeviceJobInfo.job value of 0.
Co-authored-by: Sławek Kapłoński <slawek@kaplonski.pl>
Closes-Bug: #1627134
Change-Id: I2d0daa32b1d37fa60412ad7a374ee38cebdeb579
When doing Live migration with shared storage, it happens erratically,
that the check for the shared storage test_file fails. Because the shared
volume is under heavy IO (many instances on many compute nodes) the client
does not immediately sees the new content of the folder. This delay
could take up to 30s.
This can be fixed if the client is forced to refresh the directories
content, which can be achieved by 'touch' on the directory. Doing so,
the test_file is visibile instantly, within ms.
The patch adds a 'touch' on instances_path in check_shared_storage_test_file,
before checking the existence of the file.
Change-Id: I16be39142278517f43e6eca3441a56cbc9561113
Closes-Bug: #1617299
Unit tests should never *actually* sleep. Some of the DB API tests
that poke the retry wrapper in oslo.db trigger situations that would
call time.sleep(). This is part of a desirable exponential backoff
timer in oslo.db, but there's no reason to actually wait to call
the next mock in a unit test. So, mock out sleep for those tests.
Before this, the single-thread time to run test_db_api was 289s,
and afterwards it is 133s.
Change-Id: I0492b497000585f079691ae863b2b2ebf078795d
As the following part of API-WG guidline[1],
If a request contains a reference to a nonexistent resource in the
body (not URI), the code should be 400 Bad Request. Do not use 404
NotFound because :rfc:`7231#section-6.5.4` (section 6.5.4) mentions
the origin server did not find a current representation for the
target resource for 404 and representation for the target resource
means a URI
Nova should return a BadRequest response(400) in this case, because
new_volume_id is specified in a request body. old_volume_id is not
necessary to be changed because the value is specified with URI.
So it is valid to return NotFound response if that is not existent.
[1]: https://github.com/openstack/api-wg/blob/master/guidelines/http.rst#failure-code-clarifications
Close-Bug: #1629110
Change-Id: Ib781b116f5af713d64b5880858cc4f81c3da3977
* Fix indentation
* Add TODOs for items that still need attention
* Place items that are deprecated to the top to ease grouping in the
future
Change-Id: I5283f8eb7c4906f974a76af0a154711b3b1aeac5
blueprint centralize-config-options-ocata