diff options
author | Austin S. Hemmelgarn <austin@netdata.cloud> | 2020-04-13 10:32:33 -0400 |
---|---|---|
committer | Austin S. Hemmelgarn <austin@netdata.cloud> | 2020-04-13 10:32:33 -0400 |
commit | 983a26d1a2c110b35db252b4b79c3f03eb4eeb4b (patch) | |
tree | 85d42c30bc81514bd5c18aa564497e439290523b /libnetdata | |
parent | 5a12b4a7e42587058b9b42871a1316545d527a57 (diff) |
Revert "Revert changes since v1.21 in pereparation for hotfix release."
This reverts commit e2874320fc027f7ab51ab3e115d5b1889b8fd747.
Diffstat (limited to 'libnetdata')
-rw-r--r-- | libnetdata/config/appconfig.c | 3 | ||||
-rw-r--r-- | libnetdata/config/appconfig.h | 25 |
2 files changed, 15 insertions, 13 deletions
diff --git a/libnetdata/config/appconfig.c b/libnetdata/config/appconfig.c index 6c008234ad..39a57e5ff5 100644 --- a/libnetdata/config/appconfig.c +++ b/libnetdata/config/appconfig.c @@ -547,7 +547,8 @@ int appconfig_load(struct config *root, char *filename, int overwrite_used, cons s++; if (is_exporter_config) { - global_exporting_section = !(strcmp(s, CONFIG_SECTION_EXPORTING)); + global_exporting_section = + !(strcmp(s, CONFIG_SECTION_EXPORTING)) || !(strcmp(s, CONFIG_SECTION_PROMETHEUS)); if (unlikely(!global_exporting_section)) { int rc; rc = is_valid_connector(s, 0); diff --git a/libnetdata/config/appconfig.h b/libnetdata/config/appconfig.h index a0a3bd6329..8c2ce09a97 100644 --- a/libnetdata/config/appconfig.h +++ b/libnetdata/config/appconfig.h @@ -82,18 +82,19 @@ #define CONFIG_FILENAME "netdata.conf" -#define CONFIG_SECTION_GLOBAL "global" -#define CONFIG_SECTION_WEB "web" -#define CONFIG_SECTION_STATSD "statsd" -#define CONFIG_SECTION_PLUGINS "plugins" -#define CONFIG_SECTION_CLOUD "cloud" -#define CONFIG_SECTION_REGISTRY "registry" -#define CONFIG_SECTION_HEALTH "health" -#define CONFIG_SECTION_BACKEND "backend" -#define CONFIG_SECTION_STREAM "stream" -#define CONFIG_SECTION_EXPORTING "exporting:global" -#define CONFIG_SECTION_HOST_LABEL "host labels" -#define EXPORTING_CONF "exporting.conf" +#define CONFIG_SECTION_GLOBAL "global" +#define CONFIG_SECTION_WEB "web" +#define CONFIG_SECTION_STATSD "statsd" +#define CONFIG_SECTION_PLUGINS "plugins" +#define CONFIG_SECTION_CLOUD "cloud" +#define CONFIG_SECTION_REGISTRY "registry" +#define CONFIG_SECTION_HEALTH "health" +#define CONFIG_SECTION_BACKEND "backend" +#define CONFIG_SECTION_STREAM "stream" +#define CONFIG_SECTION_EXPORTING "exporting:global" +#define CONFIG_SECTION_PROMETHEUS "prometheus:exporter" +#define CONFIG_SECTION_HOST_LABEL "host labels" +#define EXPORTING_CONF "exporting.conf" // these are used to limit the configuration names and values lengths // they are not enforced by config.c functions (they will strdup() all strings, no matter of their length) |