| Commit message (Collapse) | Author | Age | Files | Lines |
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
select_destinations returns a list of (host, node) tuples that satisfy
the request_spec and filter_properties passed to it. This will allow
the conductor to get a list of destinations for workflows such as
creating or resizing an instance and then handle the orchestration
itself.
part of bp query-scheduler
Change-Id: I1a42cea64dbad67562d7efe8d759e6efb5ec8121
|
| |\ \ |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Implements blueprint per-aggregate-resource-ratio
* AggregateRamFilter to support per-aggregate ram_allocation_ratio
* Falls back to global setting if per-aggregate value not found
DocImpact
Change-Id: I93e069f0ac3f595d9a2a17119274c7bfbe8fca31
|
| |\ \ \ |
|
| | |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Implements blueprint per-aggregate-resource-ratio
* AggregateCoreFilter to support per-aggregate cpu_allocation_ratio
* Falls back to global setting if per-aggregate value not found
DocImpact
Change-Id: I9230f46e2490226f3c50d616aa173d4722095087
|
| | |/
|/|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This method is required by the scheduler.manager.prep_resize method
which is being moved to conductor.manager.
We move it to scheduler.utils until we completely move migrations
logic out of scheduler.manager.
Partially implements bp cold-migrations-to-conductor
Change-Id: I8203577fc26da5cc1039815e31fb8fe356d1f7d6
|
| |\ \ |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Calls to scheduler.manager.select_hosts are expected to throw NoValidHost
exceptions if no hosts match such requests. For the exception to be passed
over RPC, the method must be decorated with:
@rpc_common.client_exceptions(exception.NoValidHost)
Resolves bug 1192693.
Change-Id: If9d1f15ff1239e422067893f9d837c41e5f5474d
|
| | |/
|/|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Before moving the control of live-migration into the conductor,
extract the live-migration control logic into a separate class.
The callback to select_hosts will be replaced by a new
scheduler rpc method in a later changeset.
Part of blueprint live-migration-to-conductor
Change-Id: I6de33ada6dc377e20f8df07da92244f2c150b9fe
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Make sure that when scheduling, the instance_type used in filters
contains the 'extra_specs'. This is a bit ugly, but will get cleaned up
with objects.
Fixes bug 1192331
Change-Id: I3614f3a858840c9561b4e618fc30f3d3ae5ac689
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit b2c17ae891b12118b9d11bf0ecc44e77956715c8.
While reviewing merged changes, I came across this one. It's using the
conductor in a way that it shouldn't. The scheduler has db access, so
there's no need to add the extra conductor overhead. The best thing to
do here is to just revert for now, IMO.
Change-Id: Iaa0d67df7bb84913784d925cffebcd5f252249ea
|
| |\ \ |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Scheduler support for blueprint instance-group-api-extension
The patch set adds the following:
1. conductor support for getting instances via the instance_group uuid
2. conductor support for removing an instance from the instance_group
members
In addition to this it replaces the 'group' hint with 'instance_group'.
DocImpact
Change-Id: I4a4febc2e85d4ffc8b1579d2673fa107171a3c5b
|
| |\ \ \ |
|
| | | |/
| |/|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Using of locals() for formatting string is a nasty thing because:
1) It is not so clear as using explicit dicts
2) It could produce hidden errors during refactoring
3) Changing name of variable causes change in message
4) Creating a lot of unused variables
fixes bug #1171936
Change-Id: I7639631846a9145c3a18f2a704b71184ec781f45
|
| |\ \ \
| |/ /
|/| | |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Other than 'instance', 'image' can also be a complex structure and
then it needs to be converted. See: nova.compute.rpcapi.prep_resize
as an example.
Change-Id: I54570dad3eae6ecc91a433af68263794c22e268d
|
| |\ \ \
| |/ /
|/| | |
|
| | |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In extra_specs_ops.match(value, req) function, req are
always string,but value of host capabilities may be number.
When filter host by comparing number with string,even right
os-extra_specs can't pass filter.
We should convert value to string to make the filter work
correctly.
Fixes: bug #1186881
Change-Id: I3e1ab60109673450caae3a7f0bc4a3610ae619ef
|
| |\ \ |
|
| | |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Kill some of the variables marked as unused by flakes8. This should
allow to enable F841 check in the future.
Only trivial cases with no function calls and obviously pure functions
(like datetime.now(), or len()) are cleaned up here.
Part 1, split to reduce conflicts.
Change-Id: I82854349574ec4bcb9336aba626eefdaed81a8c8
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a first pass at client side version control for rpc. It allows
you to configure a max version of messages that clients are allowed to
send. You can find one example of how clients need to adapt in the
conductor rpcapi. All other changes in rpc apis since the grizzly
release are not applicable to this.
Some future improvements to this could be reporting the versions
supported by running services and having that be discoverable via the
API. We could also consider allow setting these client side version
caps via the API. For now, recommended values for these config
options while attempting a rolling upgrade will just have to be documented.
The config options allow specifying specific rpc api version numbers if
desired, but an alias of 'grizzly' is also supported. So typically at
the start of a rolling upgrade you'd have:
[upgrade_levels]
compute=grizzly
conductor=grizzly
scheduler=grizzly
... etc ...
And as you update all instances of a service, you would remove that bit
from your configuration across the deployment using your config management
system of choice.
DocImpact
Implements blueprint rpc-version-control.
Change-Id: I2c0fd6dd7484c87823846d7c31d6525d93cd1b43
|
| |\ |
|
| | |
| |
| |
| |
| |
| | |
Multi-line doc-strings should end on a new, separate line.
Change-Id: I4cf0cfe92b634ef77971863a4df41ef43531bc20
|
| |\ \
| |/
|/| |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If live migration encounter some exception before nova scheduler
cast message to nova compute, nova scheduler will set the VM state
to ERROR and send notification, but the notification do not include
VM UUID, this might cause some problem if some components want to
handle the notification since those components will not able to know
the VM UUID about the notification.
The solution is add UUID to live migration error notification so other
components can get the related notification correctly.
Fix bug 1182117
Change-Id: Id101f9e2a689a02d1604c12cd7677e0975bd7428
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Second step in removing references to instance_types. Remove all
references to instance_type in nova.compute.flavors.
Also update compute devref to reflect changed name.
Partially implements bp flavor-instance-type-dedup
renamed: nova/tests/test_instance_types.py -> test_flavors.py
Change-Id: I7413bf832c61d04ab90ec8b1370d3f01372c4172
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change is intended to refactor the method to be consistent
with the filter_scheduler.select_hosts implementation.
This method is called by scheduler.manager and it is exposed
through the scheduler.rpcapi. Thus, both implementations should
behave the same.
This change is needed by others that will move cold migration
to conductor.
Partially implements bp cold-migrations-to-conductor
Change-Id: I0f6fef43324cf829cdb26633874c537572423f77
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| | |
For easier debuging. Report more detailed log when
aggregate_instance_extra_specs failed.
Change-Id: I9e285fc55ca4dfa75688bb0645b8d1b71a0b55bd
|
| |\ \
| |/
|/| |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
Mechanical translation of the deprecated
except x,y: construct with except x as y:
The latter works with any Python >= 2.6.
Add Hacking check.
Change-Id: I845829d97d379c1cd9b3a77e7e5786586f263b64
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This prepares for having the conductor query the scheduler for a list of
hosts to build an instance on. In order to accomplish this the API
sends a build_instances message to conductor, or spawns a greenthread in
local mode, rather than sending a message to the scheduler. This is
being done so that conductor can handle the orchestration of long
running tasks like spawning instances. By making this move, the API is
free to return to the caller while conductor queries the scheduler for a
host to provision to.
In the case of cells the build_instances message first goes to the
cells scheduler in order to pick a cell to send it to, and then it is
sent to the conductor in that cell.
Part of bp query-scheduler
Change-Id: I4539888e78ebdbb8cef6647273b959a012280110
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| | |
Raising raw exception classes works, but is old deprecated syntax, and
may bite us later.
Change-Id: I03f41da267ce5cbfc5ea98c531acc9a9b13e082a
|
| |/
|
|
|
|
|
|
| |
GroupAntiAffinityFilter was introduced to filter a set of hosts,
howerver the docstring saying filter a set of instances which need to be
fixed.
Change-Id: Icf66a3ad15b4135c06e2e2ccc62837a346fcfdf7
|
| |\ |
|
| | |
| |
| |
| |
| |
| | |
Just removed locals() and replaced it with an explicit dicionary.
Change-Id: Id476a684abde36238b5abfe8ce4c3ddb0874423b
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Presently when scheduler raises NoValidHost due to max attempts
being reached, the instance remains in a build state.
Exception handler for NoValidHost in manager.run_instance() needs
request_spec[instance_uuids] to know which host to put into an
error state in _set_vm_state_and_notify().
schedule_run_instances() was popping instance_uuids from the
request_spec prior to a call to _schedule().
Changed pop of instance_uuids prior to call to _schedule() to be a get.
Added pop of instance_uuids to beneath call to _schedule() as
individual creates do not need them.
Change-Id: I9654820e01d5611763e9e673f15f46b947d09e6d
Fixes: bug #1182056
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The destination check in live migration will fetch the image
information from glance and it will throw ImageNotFound if
the instance is booted from volume since there is no image id
on the instance
Fix bug 1170596
Change-Id: Ie683a3ca5d6430c52ead77b41f98fbcb4114ea1e
|
| |\ \
| |/
|/| |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
On a large system (>500 hosts) the amount of logging
information if everything is at DEBUG is vasts, due to
the number of hosts checked for each filter
However at the moment some useful information is only
available within the filter's debug entrys (such as
parts of the request_spec). Also instance uuids are
not logged making it hard to search for instance entries.
This set of changes allows it to be used in a very
large install with debug turned off for everything
except nova.filters
Specifically:
- Log.Info the instance_uuids at the start of schedule
- Log.debug the request_spec at the start of schedule
- Log.debug hosts in weighted order
- Log.info which host has been allocated to a specific
instance_uuid
- Log.debug how many hosts are returned by each filter
To get a count from each filter nova.filters had to be
changed to generate a list after each filter rather than
building a recursive generator object. Although this
new approach is less elegant it does provide simple and
useful insight into the behaviour of the filters, and s
the impact on execution time on a system with several
hundred hosts and 10 filters was negligible
Change-Id: Ibbdd14f87b1dfd3cee8bf3cf6388e40b474e530a
|
| |/
|
|
|
|
|
|
|
|
|
|
|
| |
First step in removing references to instance_types. Rename instnace_types.py
and update references to it. We currently use instance_type and flavor as
synonyms, to reduce confusion we are picking one. We are going with our own
terminology, flavors.
renamed: nova/compute/instance_types.py -> nova/compute/flavors.py
Partially implements bp flavor-instance-type-dedup
Change-Id: I9dc04cf311aa8813be4f5329f23729d2c43cae6d
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add support for "force_nodes" to filter properties, following the example
of force_hosts. In doing so, fix an issue where the presence of either
force_hosts or ignore_hosts would have squashed a host with multiple nodes.
A node can be passed in via the --availability_zone
option, separated from the hostname with a colon. Eg,
nova boot --availability_zone=zone:host:node
Note that "host" is optional here, and "zone::node" also works.
DocImpact
Implements bp baremetal-force-node
Change-Id: Icfee63c80eb355c29594f8badde4183496b395ac
|
| |/
|
|
|
|
|
|
|
|
| |
This method does not at all belong in the scheduler. Its only use is
from being remotely called by nova-manage to whom it returns data
fetched from the db. I think nova-manage is better of fetching this
data on its own instead of making this extra round trip to the
scheduler.
Change-Id: I435300cdd15bdd041cbe5718ae064b98cec4cceb
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create an exception type for pre-check errors and add it to the list
of exceptions for which instance task state is reset to ACTIVE to
avoid cases where an instance get stuck in MIGRATING state.
Convert existing instances of raise MigrationError in scheduler and
driver pre-checks to have them raise the new MigrationPreCheckError
exception instead.
In addition, also make sure that expected exceptions are passed over
RPC silently.
Resolves bug 1171526.
Change-Id: I00fa0962e555f895dd98861684ec7767fed3b37b
|
| |
|
|
|
|
|
| |
Convert nova to using the oslo periodic tasks implementation. There
are no functional changes in this review.
Change-Id: I767e0ad17781d5f9d5e987e0a4ad65796243ae5c
|