]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/cephadm/schedule: remove unused methods
authorSage Weil <sage@newdream.net>
Wed, 10 Mar 2021 16:00:04 +0000 (11:00 -0500)
committerSage Weil <sage@newdream.net>
Mon, 15 Mar 2021 22:55:16 +0000 (18:55 -0400)
Signed-off-by: Sage Weil <sage@newdream.net>
src/pybind/mgr/cephadm/schedule.py

index 1a72744462b1950dd793bb2303bbcd12a17fe8f8..d335f7bf569157e1c0ed3a14e33699159413c443 100644 (file)
@@ -151,24 +151,6 @@ class HostAssignment(object):
             existing, to_add))
         return existing_slots + to_add, to_add, to_remove
 
-    def add_daemon_hosts(self, host_pool: List[HostPlacementSpec]) -> List[HostPlacementSpec]:
-        hosts_with_daemons = {d.hostname for d in self.daemons}
-        _add_daemon_hosts = []  # type: List[HostPlacementSpec]
-        for host in host_pool:
-            if host.hostname not in hosts_with_daemons:
-                _add_daemon_hosts.append(host)
-        return _add_daemon_hosts
-
-    def remove_daemon_hosts(self, host_pool: List[HostPlacementSpec]) -> Set[DaemonDescription]:
-        target_hosts = [h.hostname for h in host_pool]
-        _remove_daemon_hosts = set()
-        for d in self.daemons:
-            if d.hostname not in target_hosts:
-                _remove_daemon_hosts.add(d)
-            else:
-                target_hosts.remove(d.hostname)
-        return _remove_daemon_hosts
-
     def get_candidates(self) -> List[HostPlacementSpec]:
         if self.spec.placement.hosts:
             hosts = self.spec.placement.hosts