self._trigger_osd_removal()
def _trigger_osd_removal(self) -> None:
+ remove_queue = self.to_remove_osds.as_osd_ids()
+ if not remove_queue:
+ return
data = self.get("osd_stats")
for osd in data.get('osd_stats', []):
if osd.get('num_pgs') == 0:
# if _ANY_ osd that is currently in the queue appears to be empty,
# start the removal process
- if int(osd.get('osd')) in self.to_remove_osds.as_osd_ids():
+ if int(osd.get('osd')) in remove_queue:
self.log.debug('Found empty osd. Starting removal process')
# if the osd that is now empty is also part of the removal queue
# start the process