Bases: nova.objects.base.NovaObject
Returns a new RequestSpec object by hydrating it from legacy dicts.
That helper is not intended to leave the legacy dicts kept in the nova codebase, but is rather just for giving a temporary solution for populating the Spec object until we get rid of scheduler_utils’ build_request_spec() and the filter_properties hydratation in the conductor.
Parameters: |
|
---|
Convenient helper for accessing a particular scheduler hint since it is hydrated by putting a single item into a list.
In order to reduce the complexity, that helper returns a string if the requested hint is a list of only one value, and if not, returns the value directly (ie. the list). If the hint is not existing (or scheduler_hints is None), then it returns the default value.
Parameters: |
|
---|
Returns a legacy filter_properties dict from the RequestSpec object.
Since we need to manage backwards compatibility and rolling upgrades within our RPC API, we need to accept to provide an helper for primitiving the right RequestSpec object into a legacy dict until we drop support for old Scheduler RPC API versions. If you don’t understand why this method is needed, please don’t use it.
Returns a legacy request_spec dict from the RequestSpec object.
Since we need to manage backwards compatibility and rolling upgrades within our RPC API, we need to accept to provide an helper for primitiving the right RequestSpec object into a legacy dict until we drop support for old Scheduler RPC API versions. If you don’t understand why this method is needed, please don’t use it.
Bases: nova.objects.base.NovaObject
Bases: nova.objects.base.NovaObject