MCPcopy Create free account
hub / github.com/ceph/ceph / _config_notify

Method _config_notify

src/pybind/mgr/mgr_module.py:1438–1462  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1436 pass
1437
1438 def _config_notify(self) -> None:
1439 # check logging options for changes
1440 mgr_level = cast(str, self.get_ceph_option("debug_mgr"))
1441 module_level = cast(str, self.get_module_option("log_level"))
1442 cluster_level = cast(str, self.get_module_option("log_to_cluster_level"))
1443 assert isinstance(cluster_level, str)
1444 log_to_file = self.get_module_option("log_to_file", False)
1445 assert isinstance(log_to_file, bool)
1446 log_to_cluster = self.get_module_option("log_to_cluster", False)
1447 assert isinstance(log_to_cluster, bool)
1448 self._set_log_level(mgr_level, module_level, cluster_level)
1449
1450 if log_to_file != self.log_to_file:
1451 if log_to_file:
1452 self._enable_file_log()
1453 else:
1454 self._disable_file_log()
1455 if log_to_cluster != self.log_to_cluster:
1456 if log_to_cluster:
1457 self._enable_cluster_log()
1458 else:
1459 self._disable_cluster_log()
1460
1461 # call module subclass implementations
1462 self.config_notify()
1463
1464 def config_notify(self) -> None:
1465 """

Callers

nothing calls this directly

Calls 8

get_ceph_optionMethod · 0.95
get_module_optionMethod · 0.95
config_notifyMethod · 0.95
_set_log_levelMethod · 0.80
_enable_file_logMethod · 0.80
_disable_file_logMethod · 0.80
_enable_cluster_logMethod · 0.80
_disable_cluster_logMethod · 0.80

Tested by

no test coverage detected