Otherwise, even when we explicitly mute the warning, the health log
lines still appear and fail tests. This troublesome for the kclient
fallback to aes where we want to conditionally mute relevant warnings.
Signed-off-by: Patrick Donnelly <pdonnell@ibm.com>
Change-Id:
b57e8d3c-4d38-462b-8d22-
399916efdf5b
bool check_leader_health();
bool check_member_health();
bool check_mutes();
+
+public:
+ bool is_muted(const std::string& code) const {
+ return mutes.count(code) > 0;
+ }
};
#endif // CEPH_HEALTH_MONITOR_H
const auto min_log_period = g_conf().get_val<int64_t>(
"mon_health_log_update_period");
for (auto& p : updated.checks) {
+ if (healthmon()->is_muted(p.first)) {
+ continue;
+ }
+
auto q = previous.checks.find(p.first);
bool logged = false;
if (q == previous.checks.end()) {
for (const auto &i : health.checks) {
const std::string &code = i.first;
+
+ if (healthmon()->is_muted(code)) {
+ continue;
+ }
+
const std::string &summary = i.second.summary;
const health_status_t severity = i.second.severity;