diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-07-20 04:49:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-07-20 04:49:55 +0000 |
commit | ab1bb5b7f1c3c3a7b240ab7fc8661459ecd7decb (patch) | |
tree | 7a900833aad3ccc685712c6c2a7d87576d54f427 /aclk/schema-wrappers | |
parent | Adding upstream version 1.40.1. (diff) | |
download | netdata-ab1bb5b7f1c3c3a7b240ab7fc8661459ecd7decb.tar.xz netdata-ab1bb5b7f1c3c3a7b240ab7fc8661459ecd7decb.zip |
Adding upstream version 1.41.0.upstream/1.41.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'aclk/schema-wrappers')
-rw-r--r-- | aclk/schema-wrappers/alarm_config.cc | 5 | ||||
-rw-r--r-- | aclk/schema-wrappers/alarm_config.h | 2 | ||||
-rw-r--r-- | aclk/schema-wrappers/alarm_stream.cc | 2 |
3 files changed, 8 insertions, 1 deletions
diff --git a/aclk/schema-wrappers/alarm_config.cc b/aclk/schema-wrappers/alarm_config.cc index 56d7e6f39..fe0b0517c 100644 --- a/aclk/schema-wrappers/alarm_config.cc +++ b/aclk/schema-wrappers/alarm_config.cc @@ -48,6 +48,8 @@ void destroy_aclk_alarm_configuration(struct aclk_alarm_configuration *cfg) freez(cfg->p_db_lookup_dimensions); freez(cfg->p_db_lookup_method); freez(cfg->p_db_lookup_options); + + freez(cfg->chart_labels); } char *generate_provide_alarm_configuration(size_t *len, struct provide_alarm_configuration *data) @@ -127,6 +129,9 @@ char *generate_provide_alarm_configuration(size_t *len, struct provide_alarm_con cfg->set_p_db_lookup_options(data->cfg.p_db_lookup_options); cfg->set_p_update_every(data->cfg.p_update_every); + if (data->cfg.chart_labels) + cfg->set_chart_labels(data->cfg.chart_labels); + *len = PROTO_COMPAT_MSG_SIZE(msg); char *bin = (char*)mallocz(*len); if (!msg.SerializeToArray(bin, *len)) diff --git a/aclk/schema-wrappers/alarm_config.h b/aclk/schema-wrappers/alarm_config.h index 157fbc60f..4eaa4fd70 100644 --- a/aclk/schema-wrappers/alarm_config.h +++ b/aclk/schema-wrappers/alarm_config.h @@ -50,6 +50,8 @@ struct aclk_alarm_configuration { char *p_db_lookup_method; char *p_db_lookup_options; int32_t p_update_every; + + char *chart_labels; }; void destroy_aclk_alarm_configuration(struct aclk_alarm_configuration *cfg); diff --git a/aclk/schema-wrappers/alarm_stream.cc b/aclk/schema-wrappers/alarm_stream.cc index 11b9284f5..d1079a688 100644 --- a/aclk/schema-wrappers/alarm_stream.cc +++ b/aclk/schema-wrappers/alarm_stream.cc @@ -59,7 +59,7 @@ static alarms::v1::AlarmStatus aclk_alarm_status_to_proto(enum aclk_alarm_status case aclk_alarm_status::ALARM_STATUS_CRITICAL: return alarms::v1::ALARM_STATUS_CRITICAL; default: - error("Unknown alarm status"); + netdata_log_error("Unknown alarm status"); return alarms::v1::ALARM_STATUS_UNKNOWN; } } |