From c3d70ffcb43b62c95d71334ed49ad345ddf4360d Mon Sep 17 00:00:00 2001 From: Costa Tsaousis Date: Thu, 20 Apr 2023 20:49:06 +0300 Subject: WEBRTC for communication between agents and browsers (#14874) * initial webrtc setup * missing files * rewrite of webrtc integration * initialization and cleanup of webrtc connections * make it compile without libdatachannel * add missing webrtc_initialize() function when webrtc is not enabled * make c++17 optional * add build/m4/ax_compiler_vendor.m4 * add ax_cxx_compile_stdcxx.m4 * added new m4 files to makefile.am * id all webrtc connections * show warning when webrtc is disabled * fixed message * moved all webrtc error checking inside webrtc.cpp * working webrtc connection establishment and cleanup * remove obsolete code * rewrote webrtc code in C to remove dependency for c++17 * fixed left-over reference * detect binary and text messages * minor fix * naming of webrtc threads * added webrtc configuration * fix for thread_get_name_np() * smaller web_client memory footprint * universal web clients cache * free web clients every 100 uses * webrtc is now enabled by default only when compiled with internal checks * webrtc responses to /api/ requests, including LZ4 compression * fix for binary and text messages * web_client_cache is now global * unification of the internal web server API, for web requests, aclk request, webrtc requests * more cleanup and unification of web client timings * fixed compiler warnings * update sent and received bytes * eliminated of almost all big buffers in web client * registry now uses the new json generation * cookies are now an array; fixed redirects * fix redirects, again * write cookies directly to the header buffer, eliminating the need for cookie structures in web client * reset the has_cookies flag * gathered all web client cleanup to one function * fixes redirects * added summary.globals in /api/v2/data response * ars to arc in /api/v2/data * properly handle host impersonation * set the context of mem.numa_nodes --- Makefile.am | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'Makefile.am') diff --git a/Makefile.am b/Makefile.am index 9b38168871..fe979cc8d4 100644 --- a/Makefile.am +++ b/Makefile.am @@ -37,6 +37,8 @@ EXTRA_DIST = \ build/m4/ax_c_mallopt.m4 \ build/m4/tcmalloc.m4 \ build/m4/ax_c__generic.m4 \ + build/m4/ax_compiler_vendor.m4 \ + build/m4/ax_cxx_compile_stdcxx.m4 \ ml/dlib \ README.md \ LICENSE \ @@ -119,6 +121,7 @@ AM_CFLAGS = \ $(OPTIONAL_UUID_CFLAGS) \ $(OPTIONAL_MQTT_CFLAGS) \ $(OPTIONAL_LIBCAP_LIBS) \ + $(OPTIONAL_DATACHANNEL_CFLAGS) \ $(OPTIONAL_IPMIMONITORING_CFLAGS) \ $(OPTIONAL_CUPS_CFLAGS) \ $(OPTIONAL_XENSTAT_CFLAGS) \ @@ -659,6 +662,8 @@ STATSD_PLUGIN_FILES = \ $(NULL) WEB_PLUGIN_FILES = \ + web/rtc/webrtc.c \ + web/rtc/webrtc.h \ web/server/web_client.c \ web/server/web_client.h \ web/server/web_server.c \ @@ -980,6 +985,7 @@ NETDATA_COMMON_LIBS = \ $(OPTIONAL_MQTT_LIBS) \ $(OPTIONAL_UV_LIBS) \ $(OPTIONAL_LZ4_LIBS) \ + $(OPTIONAL_DATACHANNEL_LIBS) \ libjudy.a \ $(OPTIONAL_SSL_LIBS) \ $(OPTIONAL_JSONC_LIBS) \ -- cgit v1.2.3