python.d: add plugin and module names to the runtime charts (#11007)
Ilya Mashchenko committed
Apr 21, 2021 at 15:06 UTC
c15e0fef00784293ba4f15dade972677e74ab190
1 file changed
+2
-1
collectors/python.d.plugin/python_modules/bases/charts.py
+2
-1
@@ -24,7 +24,7 @@ DIMENSION_SET = "SET '{id}' = {value}\n"
24
CHART_VARIABLE_SET = "VARIABLE CHART '{id}' = {value}\n"
25
26
RUNTIME_CHART_CREATE = "CHART netdata.runtime_{job_name} '' 'Execution time for {job_name}' 'ms' 'python.d' " \
27
- "netdata.pythond_runtime line 145000 {update_every}\n" \
27
+ "netdata.pythond_runtime line 145000 {update_every} '' 'python.d.plugin' '{module_name}'\n" \
28
"DIMENSION run_time 'run time' absolute 1 1\n"
29
30
@@ -45,6 +45,7 @@ def create_runtime_chart(func):
45
chart = RUNTIME_CHART_CREATE.format(
46
job_name=self.name,
47
update_every=self._runtime_counters.update_every,
48
+ module_name=self.module_name,
49
)
50
safe_print(chart)
51
ok = func(*args, **kwargs)