Fake collector to provoke ACLK messages (#8427)
For internal testing use only.
Andrew Moss committed
Mar 25, 2020 at 16:21 UTC
9ee4478f9a9eedbaff5887a415a897d984e74828
4 files changed
+41
-5
aclk/Makefile.am
+6
-5
@@ -4,15 +4,16 @@ AUTOMAKE_OPTIONS = subdir-objects
4
MAINTAINERCLEANFILES = $(srcdir)/Makefile.in
5
6
CLEANFILES = \
7
+ tests/install-fake-charts.d.sh \
8
$(NULL)
9
10
include $(top_srcdir)/build/subst.inc
11
SUFFIXES = .in
12
12
-sbin_SCRIPTS = \
13
- $(NULL)
13
+#sbin_SCRIPTS = \
14
+# tests/install-fake-charts.d.sh \
15
+# $(NULL)
16
15
-dist_noinst_DATA = \
16
- README.md \
17
- $(NULL)
17
+dist_noinst_SCRIPTS = tests/install-fake-charts.d.sh
18
+dist_noinst_DATA = README.md tests/install-fake-charts.d.sh.in
19
aclk/tests/fake-charts.d.plugin
new
+24
@@ -0,0 +1,24 @@
1
+#!/usr/bin/env bash
2
+
3
+sleep 45 # Wait until popcorning finishes
4
+
5
+echo "CHART aclk_test.newcol '' 'Generate new collector/chart event' 'units' aclk_test aclk_test lines 900001 1"
6
+sleep 5
7
+echo "DIMENSION aclk1 '' percentage-of-absolute 1 1"
8
+sleep 5
9
+echo "BEGIN aclk_test.newcol 1000000"
10
+echo "SET aclk1 = 3"
11
+echo "END"
12
+sleep 5
13
+echo "DIMENSION aclk2 '' percentage-of-absolute 1 1"
14
+sleep 5
15
+echo "BEGIN aclk_test.newcol 1000000"
16
+echo "SET aclk1 = 3"
17
+echo "SET aclk2 = 3"
18
+echo "END"
19
+sleep 5
20
+echo "CHART aclk_test2.newcol '' 'Generate new collector/chart event' 'units' aclk_test aclk_test lines 900001 1"
21
+echo "DIMENSION aclk1 '' percentage-of-absolute 1 1"
22
+
23
+sleep 5
24
+exit 0 # Signal that we are done
aclk/tests/install-fake-charts.d.sh.in
new
+6
@@ -0,0 +1,6 @@
1
+#!/usr/bin/env bash
2
+
3
+TARGET="@pluginsdir_POST@"
4
+BASE="$(cd "$(dirname "$0")" && pwd)"
5
+
6
+cp "$BASE/fake-charts.d.plugin" "$TARGET/charts.d.plugin"
web/gui/dashboard_info.js
+5
@@ -190,6 +190,11 @@ netdataDashboard.menu = {
190
info: 'Performance metrics for the operation of netdata itself and its plugins.'
191
},
192
193
+ 'aclk_test': {
194
+ title: 'ACLK Test Generator',
195
+ info: 'For internal use to perform integration testing.'
196
+ },
197
+
198
'example': {
199
title: 'Example Charts',
200
info: 'Example charts, demonstrating the external plugin architecture.'