From: Kefu Chai Date: Fri, 31 Jan 2020 15:42:49 +0000 (+0800) Subject: mgr/dashboard: pass a list of drive_group to create_osds X-Git-Tag: v15.1.1~579^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=063caebe0f95d07bff39c7ccb1beafc81a084b33;p=ceph-ci.git mgr/dashboard: pass a list of drive_group to create_osds as orchestrator backends expect a list of drive_groups. Signed-off-by: Kefu Chai --- diff --git a/src/pybind/mgr/dashboard/services/orchestrator.py b/src/pybind/mgr/dashboard/services/orchestrator.py index 6b6309f50e3..c60e32cec69 100644 --- a/src/pybind/mgr/dashboard/services/orchestrator.py +++ b/src/pybind/mgr/dashboard/services/orchestrator.py @@ -95,7 +95,7 @@ class OsdManager(ResourceManager): @wait_api_result def create(self, drive_group): - return self.api.create_osds(drive_group) + return self.api.create_osds([drive_group]) class OrchClient(object): diff --git a/src/pybind/mgr/orchestrator.py b/src/pybind/mgr/orchestrator.py index 0335b56a8c6..410d5946a58 100644 --- a/src/pybind/mgr/orchestrator.py +++ b/src/pybind/mgr/orchestrator.py @@ -872,7 +872,7 @@ class Orchestrator(object): #assert not (service_name and service_id) raise NotImplementedError() - def create_osds(self, drive_group): + def create_osds(self, drive_groups): # type: (DriveGroupSpec) -> Completion """ Create one or more OSDs within a single Drive Group. @@ -882,7 +882,7 @@ class Orchestrator(object): finer-grained OSD feature enablement (choice of backing store, compression/encryption, etc). - :param drive_group: DriveGroupSpec + :param drive_groups: a list of DriveGroupSpec :param all_hosts: TODO, this is required because the orchestrator methods are not composable Probably this parameter can be easily removed because each orchestrator can use the "get_inventory" method and the "drive_group.host_pattern" attribute