From a8220ab2d293bb7f4b014b79d16b2fb05090fa93 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Feb 2021 12:45:55 +0100 Subject: Adding upstream version 1.29.0. Signed-off-by: Daniel Baumann --- collectors/charts.d.plugin/tomcat/Makefile.inc | 13 -- collectors/charts.d.plugin/tomcat/README.md | 6 - collectors/charts.d.plugin/tomcat/tomcat.chart.sh | 152 ---------------------- collectors/charts.d.plugin/tomcat/tomcat.conf | 38 ------ 4 files changed, 209 deletions(-) delete mode 100644 collectors/charts.d.plugin/tomcat/Makefile.inc delete mode 100644 collectors/charts.d.plugin/tomcat/README.md delete mode 100644 collectors/charts.d.plugin/tomcat/tomcat.chart.sh delete mode 100644 collectors/charts.d.plugin/tomcat/tomcat.conf (limited to 'collectors/charts.d.plugin/tomcat') diff --git a/collectors/charts.d.plugin/tomcat/Makefile.inc b/collectors/charts.d.plugin/tomcat/Makefile.inc deleted file mode 100644 index ef05b1953..000000000 --- a/collectors/charts.d.plugin/tomcat/Makefile.inc +++ /dev/null @@ -1,13 +0,0 @@ -# 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 deleted file mode 100644 index 752332cfb..000000000 --- a/collectors/charts.d.plugin/tomcat/README.md +++ /dev/null @@ -1,6 +0,0 @@ -# tomcat - -> THIS MODULE IS OBSOLETE. -> USE [THE PYTHON ONE](../../python.d.plugin/tomcat) - IT SUPPORTS MULTIPLE JOBS AND IT IS MORE EFFICIENT - -[![analytics](https://www.google-analytics.com/collect?v=1&aip=1&t=pageview&_s=1&ds=github&dr=https%3A%2F%2Fgithub.com%2Fnetdata%2Fnetdata&dl=https%3A%2F%2Fmy-netdata.io%2Fgithub%2Fcollectors%2Fcharts.d.plugin%2Ftomcat%2FREADME&_u=MAC~&cid=5792dfd7-8dc4-476b-af31-da2fdb9f93d2&tid=UA-64295674-3)](<>) diff --git a/collectors/charts.d.plugin/tomcat/tomcat.chart.sh b/collectors/charts.d.plugin/tomcat/tomcat.chart.sh deleted file mode 100644 index 9ca75e63e..000000000 --- a/collectors/charts.d.plugin/tomcat/tomcat.chart.sh +++ /dev/null @@ -1,152 +0,0 @@ -# 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 -# -# Contributed by @jgeromero with PR #277 - -# Description: Tomcat netdata charts.d plugin -# Author: Jorge Romero - -# the URL to download tomcat status info -# usually http://localhost:8080/manager/status?XML=true -tomcat_url="" -tomcat_curl_opts="" - -# set tomcat username/password here -tomcat_user="" -tomcat_password="" - -# _update_every is a special variable - it holds the number of seconds -# between the calls of the _update() function -tomcat_update_every= - -tomcat_priority=60000 - -# convert tomcat floating point values -# to integer using this multiplier -# this only affects precision - the values -# will be in the proper units -tomcat_decimal_detail=1000000 - -# used by volume chart to convert bytes to kB -tomcat_decimal_kB_detail=1000 - -tomcat_check() { - - require_cmd xmlstarlet || return 1 - - # check if url, username, passwords are set - if [ -z "${tomcat_url}" ]; then - error "tomcat url is unset or set to the empty string" - return 1 - 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 - else - tomcat_user="${tomcatUser}" - fi - 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 - else - tomcat_password="${tomcatPassword}" - fi - fi - - # 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." - return 1 - fi - - # this should return: - # - 0 to enable the chart - # - 1 to disable the chart - - return 0 -} - -tomcat_get() { - # collect tomcat values - tomcat_port="$( - IFS=/ read -ra a <<<"$tomcat_url" - hostport=${a[2]} - echo "${hostport#*:}" - )" - mapfile -t lines < <(run curl -u "$tomcat_user":"$tomcat_password" -Ss ${tomcat_curl_opts} "$tomcat_url" | - run xmlstarlet sel \ - -t -m "/status/jvm/memory" -v @free \ - -n -m "/status/connector[@name='\"http-bio-$tomcat_port\"']/threadInfo" -v @currentThreadCount \ - -n -v @currentThreadsBusy \ - -n -m "/status/connector[@name='\"http-bio-$tomcat_port\"']/requestInfo" -v @requestCount \ - -n -v @bytesSent -n -) - - tomcat_jvm_freememory="${lines[0]}" - tomcat_threads="${lines[1]}" - tomcat_threads_busy="${lines[2]}" - tomcat_accesses="${lines[3]}" - tomcat_volume="${lines[4]}" - - return 0 -} - -# _create is called once, to create the charts -tomcat_create() { - cat < -# GPL v3+ - -# THIS PLUGIN IS DEPRECATED -# USE THE PYTHON.D ONE - -# the URL to download tomcat status info -# usually http://localhost:8080/manager/status?XML=true -#tomcat_url="" -#tomcat_curl_opts="" - -# set tomcat username/password here -#tomcat_user="" -#tomcat_password="" - -# the data collection frequency -# if unset, will inherit the netdata update frequency -#tomcat_update_every=1 - -# the charts priority on the dashboard -#tomcat_priority=60000 - -# the number of retries to do in case of failure -# before disabling the module -#tomcat_retries=10 - -# convert tomcat floating point values -# to integer using this multiplier -# this only affects precision - the values -# will be in the proper units -#tomcat_decimal_detail=1000000 - -# used by volume chart to convert bytes to KB -#tomcat_decimal_KB_detail=1000 -- cgit v1.2.3