diff options
author | Stelios Fragkakis <52996999+stelfrag@users.noreply.github.com> | 2020-07-28 15:04:39 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-28 15:04:39 +0300 |
commit | eda12f579f97b123ef9b890b01528223a89a70aa (patch) | |
tree | 49fe4fd2adbf7fac9ef0f0e959d767ec4daa7849 /web/api/web_api_v1.c | |
parent | 3d4314bc4ded8ce68385665754fb3b2134906422 (diff) |
Implemented multihost database (#9556)
* Hard code a node for non-legacy multidb test
Skip dbengine initialization for new incoming children
Add code to switch to multidb ctx when accessing the dbengine
* When a non-legacy streaming connection is detected, use the multidb metadata log context
* Clear the superblock memory to avoid random data written in the metadata log
* Activate the host detection during compaction
Activate the host detection during metadata log chart updates
Keep the host in the user object during replay of the HOST command
* Add defaults for health / rrdpush on HOST metadata replay
Check for legacy status on host creation by checking is_archived and if not conclusive, call is_legacy_child()
Use defaults from the stream.conf
* Count hosts only if not archived
When host switches from archived to active update rrd_hosts_available
Remove archived hosts from charts and info
* Change parameter from "multidb disk space" to "dbengine multihost disk space"
Remove unused variables
Fix compilation error when dbengine is disabled
Fix condition for machine_guid directory creation under cache_dir
* Enable multidb disk space file creation.
* Stop deleting dimensions when rotating archived metrics if the dimension is active in a different database engine.
* Fix old bug in the code that confused obsolete hosts with orphan hosts.
* Do not delete multi-host DB host files.
* Discard dbengine state when a legacy memory mode instantiates to avoid inconsistencies.
* Identify metadata that collide with non-dbengine memory mode hosts and ignore them.
* Handle non-dbengine localhost with dbengine archived charts in localhost and streaming.
* Ignore archived hosts in streaming.
* Add documentation before merging to master.
Co-authored-by: Markos Fountoulakis <markos.fountoulakis.senior@gmail.com>
Diffstat (limited to 'web/api/web_api_v1.c')
-rw-r--r-- | web/api/web_api_v1.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/web/api/web_api_v1.c b/web/api/web_api_v1.c index be358e66bb..09366de86a 100644 --- a/web/api/web_api_v1.c +++ b/web/api/web_api_v1.c @@ -778,6 +778,8 @@ static inline void web_client_api_request_v1_info_mirrored_hosts(BUFFER *wb) { int count = 0; rrd_rdlock(); rrdhost_foreach_read(rc) { + if (rrdhost_flag_check(rc, RRDHOST_FLAG_ARCHIVED)) + continue; if(count > 0) buffer_strcat(wb, ",\n"); buffer_sprintf(wb, "\t\t\"%s\"", rc->hostname); count++; |