mirror of
https://github.com/ceph/ceph
synced 2025-03-11 02:39:05 +00:00
mgr/cephadm: kick serve loop if new metadata makes all hosts metadata up to date
Signed-off-by: Adam King <adking@redhat.com>
This commit is contained in:
parent
e2643798a9
commit
d4b070e033
@ -187,7 +187,12 @@ class HostData:
|
||||
self.mgr.cache.update_host_devices(host, ret.devices)
|
||||
|
||||
if up_to_date:
|
||||
was_out_of_date = not self.mgr.cache.all_host_metadata_up_to_date()
|
||||
self.mgr.cache.metadata_up_to_date[host] = True
|
||||
if was_out_of_date and self.mgr.cache.all_host_metadata_up_to_date():
|
||||
self.mgr.log.info(
|
||||
'New metadata from agent has made all hosts up to date. Kicking serve loop')
|
||||
self.mgr._kick_serve_loop()
|
||||
self.mgr.log.info(
|
||||
f'Received up-to-date metadata from agent on host {host}.')
|
||||
|
||||
|
@ -605,6 +605,7 @@ class CephadmServe:
|
||||
# end up stuck between wanting metadata to be up to date to apply specs
|
||||
# and needing to apply the agent spec to get up to date metadata
|
||||
if self.mgr.use_agent and not self.mgr.cache.all_host_metadata_up_to_date():
|
||||
self.log.info('Metadata not up to date on all hosts. Skipping non agent specs')
|
||||
try:
|
||||
specs.append(self.mgr.spec_store['agent'].spec)
|
||||
except Exception as e:
|
||||
|
Loading…
Reference in New Issue
Block a user