summaryrefslogtreecommitdiffstats
path: root/collectors/charts.d.plugin/tomcat
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--collectors/charts.d.plugin/tomcat/Makefile.inc13
-rw-r--r--collectors/charts.d.plugin/tomcat/README.md2
-rw-r--r--collectors/charts.d.plugin/tomcat/tomcat.chart.sh (renamed from charts.d/tomcat.chart.sh)7
-rw-r--r--collectors/charts.d.plugin/tomcat/tomcat.conf (renamed from conf.d/charts.d/tomcat.conf)0
4 files changed, 20 insertions, 2 deletions
diff --git a/collectors/charts.d.plugin/tomcat/Makefile.inc b/collectors/charts.d.plugin/tomcat/Makefile.inc
new file mode 100644
index 000000000..ef05b1953
--- /dev/null
+++ b/collectors/charts.d.plugin/tomcat/Makefile.inc
@@ -0,0 +1,13 @@
+# SPDX-License-Identifier: GPL-3.0-or-later
+
+# THIS IS NOT A COMPLETE Makefile
+# IT IS INCLUDED BY ITS PARENT'S Makefile.am
+# IT IS REQUIRED TO REFERENCE ALL FILES RELATIVE TO THE PARENT
+
+# install these files
+dist_charts_DATA += tomcat/tomcat.chart.sh
+dist_chartsconfig_DATA += tomcat/tomcat.conf
+
+# do not install these files, but include them in the distribution
+dist_noinst_DATA += tomcat/README.md tomcat/Makefile.inc
+
diff --git a/collectors/charts.d.plugin/tomcat/README.md b/collectors/charts.d.plugin/tomcat/README.md
new file mode 100644
index 000000000..d82951aac
--- /dev/null
+++ b/collectors/charts.d.plugin/tomcat/README.md
@@ -0,0 +1,2 @@
+> THIS MODULE IS OBSOLETE.
+> USE THE PYTHON ONE - IT SUPPORTS MULTIPLE JOBS AND IT IS MORE EFFICIENT
diff --git a/charts.d/tomcat.chart.sh b/collectors/charts.d.plugin/tomcat/tomcat.chart.sh
index 4ea6ae683..294487b8b 100644
--- a/charts.d/tomcat.chart.sh
+++ b/collectors/charts.d.plugin/tomcat/tomcat.chart.sh
@@ -1,9 +1,10 @@
+# shellcheck shell=bash
# no need for shebang - this file is loaded from charts.d.plugin
+# SPDX-License-Identifier: GPL-3.0-or-later
# netdata
# real-time performance and health monitoring, done right!
# (C) 2016 Costa Tsaousis <costa@tsaousis.gr>
-# GPL v3+
#
# Contributed by @jgeromero with PR #277
@@ -46,6 +47,7 @@ tomcat_check() {
fi
if [ -z "${tomcat_user}" ]; then
# check backwards compatibility
+ # shellcheck disable=SC2154
if [ -z "${tomcatUser}" ]; then
error "tomcat user is unset or set to the empty string"
return 1
@@ -55,6 +57,7 @@ tomcat_check() {
fi
if [ -z "${tomcat_password}" ]; then
# check backwards compatibility
+ # shellcheck disable=SC2154
if [ -z "${tomcatPassword}" ]; then
error "tomcat password is unset or set to the empty string"
return 1
@@ -65,6 +68,7 @@ tomcat_check() {
# check if we can get to tomcat's status page
tomcat_get
+ # shellcheck disable=2181
if [ $? -ne 0 ]
then
error "cannot get to status page on URL '${tomcat_url}'. Please make sure tomcat url, username and password are correct."
@@ -116,7 +120,6 @@ EOF
# _update is called continuously, to collect the values
tomcat_update() {
- local reqs net
# the first argument to this function is the microseconds since last update
# pass this parameter to the BEGIN statement (see bellow).
diff --git a/conf.d/charts.d/tomcat.conf b/collectors/charts.d.plugin/tomcat/tomcat.conf
index e9f3eefa9..e9f3eefa9 100644
--- a/conf.d/charts.d/tomcat.conf
+++ b/collectors/charts.d.plugin/tomcat/tomcat.conf