openstack-python-openstackc.../openstackclient
Johannes Kulik 60a0e379a4 volume: Support same_host, different_host hint as list
When creating a volume, the scheduler hints can be supplied as strings.
The "same_host" and "different_host" hints can also be supplied as a
list if affinity/anti-affinity to multiple volumes is requested [0]

The previously-used `KeyValueAction` only supplies strings as values - the
last one if multiple --hint contain the same key. An alternative already
used in `CreateServer` would be `KeyValueAppendAction`, but only a subset of
the scheduler hints accept lists, so we cannot use that in general.

Therefore, we create `KeyValueHintAction`. It contains both a
`KeyValueAction` and a `KeyValueAppendAction` object and calls the
appropriate action based on the beginning of the given values as defined
in `APPEND_KEYS`.

[0] d96b705774/cinder/api/schemas/scheduler_hints.py (L31-L65)

Change-Id: Ida7f4662dc9fea24510758541fd4f2622b73bf31
2023-10-31 09:22:25 +01:00
..
api Blacken openstackclient.api 2023-05-10 10:51:30 +01:00
common Remove project purge image commands 2023-08-28 13:52:23 +01:00
compute Merge "Remove use of oslo.utils" 2023-09-19 13:14:12 +00:00
identity Allow multiple --remove-tag in project set 2023-06-08 18:22:48 +10:00
image Adding image stores info command 2023-08-10 07:34:19 +00:00
locale/tr_TR/LC_MESSAGES Imported Translations from Zanata 2018-03-01 07:25:50 +00:00
network tests: Explicitly specify port fields for output 2023-09-12 08:33:20 +00:00
object Blacken openstackclient.object 2023-05-10 10:51:30 +01:00
tests volume: Support same_host, different_host hint as list 2023-10-31 09:22:25 +01:00
volume volume: Support same_host, different_host hint as list 2023-10-31 09:22:25 +01:00
__init__.py Clean up W503 and E402 pep8 errors 2018-04-15 12:23:06 +09:00
i18n.py Remove log translations 2017-03-21 17:23:09 +08:00
shell.py Blacken everything else 2023-05-10 10:51:30 +01:00