summaryrefslogtreecommitdiffstats
path: root/registry
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2023-08-10 09:18:52 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2023-08-10 09:19:08 +0000
commita2d7dede737947d7c6afa20a88e1f0c64e0eb96c (patch)
treefed4aff7dbe0be00cf91de6261d98bc0eb9a2449 /registry
parentReleasing debian version 1.41.0-1. (diff)
downloadnetdata-a2d7dede737947d7c6afa20a88e1f0c64e0eb96c.tar.xz
netdata-a2d7dede737947d7c6afa20a88e1f0c64e0eb96c.zip
Merging upstream version 1.42.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'registry')
-rw-r--r--registry/registry.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/registry/registry.c b/registry/registry.c
index b63c6db0f..0393389ea 100644
--- a/registry/registry.c
+++ b/registry/registry.c
@@ -58,7 +58,7 @@ static inline void registry_set_person_cookie(struct web_client *w, REGISTRY_PER
static inline void registry_json_header(RRDHOST *host, struct web_client *w, const char *action, const char *status) {
buffer_flush(w->response.data);
w->response.data->content_type = CT_APPLICATION_JSON;
- buffer_json_initialize(w->response.data, "\"", "\"", 0, true, true);
+ buffer_json_initialize(w->response.data, "\"", "\"", 0, true, BUFFER_JSON_OPTIONS_DEFAULT);
buffer_json_member_add_string(w->response.data, "action", action);
buffer_json_member_add_string(w->response.data, "status", status);
buffer_json_member_add_string(w->response.data, "hostname", rrdhost_registry_hostname(host));
@@ -186,8 +186,11 @@ int registry_request_hello_json(RRDHOST *host, struct web_client *w) {
}
buffer_json_object_close(w->response.data);
- buffer_json_member_add_string(w->response.data, "registry", registry.registry_to_announce);
+ CLOUD_STATUS status = cloud_status();
+ buffer_json_member_add_string(w->response.data, "cloud_status", cloud_status_to_string(status));
buffer_json_member_add_string(w->response.data, "cloud_base_url", registry.cloud_base_url);
+
+ buffer_json_member_add_string(w->response.data, "registry", registry.registry_to_announce);
buffer_json_member_add_boolean(w->response.data, "anonymous_statistics", netdata_anonymous_statistics_enabled);
buffer_json_member_add_array(w->response.data, "nodes");