This document previously existed to explain how to use either
application/json or application/xml with Nova. It's mostly confusing
in it's current state, and we're correctly defaulting to
application/json on request and response now.
Just remove most of what's confusing, users don't need to send
headers, we only do one thing now.
Change-Id: I597aeab73f1075f400f053016b4ea7bda01893a5
_api_version and request_api_version are pretty confusing
semantically. Update these to more meaningful names to make the code
easier to understand: api_major_version, microversion.
Change-Id: Ief6b12fc755a6c48cbef7b82ba226e47850c0b9e
The test_create_ebs_image_and_check_boot test in Tempest does the
following:
1. create volume1 from an image
2. boot server1 from volume1 with delete_on_termination=True and wait
for the server to be ACTIVE
3. create snapshot from server1 (creates image and volume snapshots)
4. delete server1
5. create server2 from the image snapshot (don't wait for it to be
ACTIVE - this auto-creates volume2 from the volume snapshot in
cinder and attaches server2 to it)
6. delete server2 (could still be building/attaching volumes in the
background)
7. cleanup
There is a race when booting server2, which creates and attaches
volume2, and deleting server2 before it's active.
The volume attach completes and updates the bdm.volume_id in the DB before
we get to _shutdown_instance, but after the delete request is in the API.
The compute API gets potentially stale BDMs and passes those over RPC to
the compute. So we add a check in _shutdown_instance to see if we have
potentially stale volume BDMs and refresh that list if so.
The instance.uuid locks in build_and_run_instance and terminate_instance
create the mutex on the compute host such that the bdm.volume_id should
be set in the database after the volume attach and before terminate_instance
gets the lock. The bdm.volume_id could still be None in _shutdown_instance
if the volume create fails, but we don't have anything to teardown in cinder
in that case anyway.
In the case of the race bug, deleting the volume snapshot in cinder fails
because volume2 was never deleted by nova, so the test fails in
teardown. Note that there is still potential for a race here, this does
not eliminate it, but should narrow the race window.
This also cleans up the logging in attach_block_devices since there
may not be a volume_id at that point (depending on bdm.source_type).
Closes-Bug: #1464259
Change-Id: Ib60d60a5af35be89ad8afbcf44fcffe0b0ce2876
For compute-api set the launchpad project users report bugs
against to "nova". Users can report bugs using the "bug icon" that will
directly link to the launchpad project, it currently goes to
"openstack-manuals" which is wrong for this content.
This variable is used by openstackdocstheme 1.2.6.
Closes-Bug: #1524476
Change-Id: I08ba11bb1c5388bc4611cea581274ac5d724c8d9
The host associated with a service looks like it really should be a
hostname and not a uuid in the current code. This changes it to
default to the name of the service started if nothing else is
specified in the test fixture. It then updates all samples to expect a
thing that looks like a name, and not a uuid.
This also allows us to drop the special casing of this function for
aggregate testing.
Change-Id: I37415b89b733c021daa38040fee447cf3934b821
This adds SIGHUP handlers to console, consoleauth, and conductor
services to reload the compute_rpcapi. This is required for auto
version pinning to be dynamic at runtime.
Related to blueprint service-version-behavior
Change-Id: I83a25bda681daa249ffca8bc1f38edcd70dd7cc5
The compute rpcapi module was looking up the desired automatic
version pin each time it was initialized. Turns out, we create and
destroy this object too often, which means we do a lot of those
lookups unnecessarily. That's a larger problem that will be harder
to solve, but we can be smarter about the DB impact of that.
This adds a cache of the last version we discovered and avoids doing
the lookup when possible. It makes the reset() method invalidate the
cache prior to reinitializing the object so that we will do the lookup
on SIGHUP as desired.
Closes-Bug: #1524444
Change-Id: Ia1c58efa7105d32973f6921c2144b17c30b764c2
testscenarios was previously used to set an intermediary symbol, which
then set additional attributes. This got really complicated to figure
out what scenarios were really doing, and how to add more (or bypass
them in tests).
This clarifies that usage, unwinds the testscenarios simplifying what
gets set up.
It also starts making calls to API v2.1 on the v2.1 url. This is
supported with existing API samples docs with a mechanism to update
links if they exist in the docs.
Change-Id: I9affc046300295cdf3e284ccc736019ccaffb9f2
The use of %(host) and an hardcoded project_id makes the templates
less semantically meaningful or flexible than they should be. It means
all manner of hackery will need to be done to run a set of tests
without project_id.
This introduces two new semantic variables, ``compute_endpoint`` which
is the unversioned compute endpoint (i.e. schema://host/project_id)
and the ``versioned_compute_endpoint`` which includes the API version.
Change-Id: Iead42f60c9e0cb703fc963e423e7bb99ca71094c
Python 2.7 filter method result was a list, while for
Python 3.4 the result is a "filter object". Trying to
use it as a list will result in a TypeError.
Enables some unit tests for gate-nova-python34.
Partially implements blueprint: nova-python3-mitaka
Change-Id: I681b084bc96fc293488ddbc03218b9c449555578
Miscellaneous structural and grammatic adjustments to improve the
clarity and readability of the Filter Scheduler doc. There are
certainly additional improvements that could be made (there always
are) but these were obvious while doing a read through.
Change-Id: I26af2ff71df86754545c1dc329ad6ad5218d25d9
As a step towards using keystoneauth instead of keystoneclient, remove
the deprecated to-be-removed-in-mitaka neutron auth options so that we
don't have to translate the deprecated code paths to the new library
interface.
bp: keystoneclient-to-keystoneauth
Co-Authored-By: Morgan Fainberg <morgan.fainberg@gmail.com>
Change-Id: I3e3393d99533a70379822178983f73d5eef09bee
It should be "IP" not "ip". Change strings
that are user visible or documentation strings.
Include some small updates in updated strings.
This does not change any comments.
Closes-Bug: #1524276
Change-Id: I16147e60b60be0f51c2aeb404ea9ed9fd3066795