diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2019-02-08 07:30:37 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2019-02-08 07:30:37 +0000 |
commit | 8a7b72f7cd1ccd547a03eb4243294e741d661d3f (patch) | |
tree | 7bc7be4a8e9e298daa1349348400aa2a653866f2 /collectors/python.d.plugin/httpcheck | |
parent | New upstream version 1.11.1+dfsg (diff) | |
download | netdata-8a7b72f7cd1ccd547a03eb4243294e741d661d3f.tar.xz netdata-8a7b72f7cd1ccd547a03eb4243294e741d661d3f.zip |
Adding upstream version 1.12.0.upstream/1.12.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'collectors/python.d.plugin/httpcheck')
-rw-r--r-- | collectors/python.d.plugin/httpcheck/README.md | 2 | ||||
-rw-r--r-- | collectors/python.d.plugin/httpcheck/httpcheck.chart.py | 13 | ||||
-rw-r--r-- | collectors/python.d.plugin/httpcheck/httpcheck.conf | 6 |
3 files changed, 15 insertions, 6 deletions
diff --git a/collectors/python.d.plugin/httpcheck/README.md b/collectors/python.d.plugin/httpcheck/README.md index 759107663..4cd024d12 100644 --- a/collectors/python.d.plugin/httpcheck/README.md +++ b/collectors/python.d.plugin/httpcheck/README.md @@ -39,3 +39,5 @@ server: response time is low and should be used as reference only. --- + +[![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%2Fpython.d.plugin%2Fhttpcheck%2FREADME&_u=MAC~&cid=5792dfd7-8dc4-476b-af31-da2fdb9f93d2&tid=UA-64295674-3)]() diff --git a/collectors/python.d.plugin/httpcheck/httpcheck.chart.py b/collectors/python.d.plugin/httpcheck/httpcheck.chart.py index f046f33c0..fd51370da 100644 --- a/collectors/python.d.plugin/httpcheck/httpcheck.chart.py +++ b/collectors/python.d.plugin/httpcheck/httpcheck.chart.py @@ -16,7 +16,6 @@ from bases.FrameworkServices.UrlService import UrlService # default module values (can be overridden per job in `config`) update_every = 3 priority = 60000 -retries = 60 # Response HTTP_RESPONSE_TIME = 'time' @@ -29,11 +28,15 @@ HTTP_BAD_STATUS = 'bad_status' HTTP_TIMEOUT = 'timeout' HTTP_NO_CONNECTION = 'no_connection' -ORDER = ['response_time', 'response_length', 'status'] +ORDER = [ + 'response_time', + 'response_length', + 'status', +] CHARTS = { 'response_time': { - 'options': [None, 'HTTP response time', 'ms', 'response', 'httpcheck.responsetime', 'line'], + 'options': [None, 'HTTP response time', 'milliseconds', 'response', 'httpcheck.responsetime', 'line'], 'lines': [ [HTTP_RESPONSE_TIME, 'time', 'absolute', 100, 1000] ] @@ -60,12 +63,12 @@ CHARTS = { class Service(UrlService): def __init__(self, configuration=None, name=None): UrlService.__init__(self, configuration=configuration, name=name) + self.order = ORDER + self.definitions = CHARTS pattern = self.configuration.get('regex') self.regex = re.compile(pattern) if pattern else None self.status_codes_accepted = self.configuration.get('status_accepted', [200]) self.follow_redirect = self.configuration.get('redirect', True) - self.order = ORDER - self.definitions = CHARTS def _get_data(self): """ diff --git a/collectors/python.d.plugin/httpcheck/httpcheck.conf b/collectors/python.d.plugin/httpcheck/httpcheck.conf index bd21b5af8..1e1dd0205 100644 --- a/collectors/python.d.plugin/httpcheck/httpcheck.conf +++ b/collectors/python.d.plugin/httpcheck/httpcheck.conf @@ -27,6 +27,10 @@ # If unset, the default for python.d.plugin is used. # priority: 60000 +# penalty indicates whether to apply penalty to update_every in case of failures. +# Penalty will increase every 5 failed updates in a row. Maximum penalty is 10 minutes. +# penalty: yes + # chart_cleanup sets the default chart cleanup interval in iterations. # A chart is marked as obsolete if it has not been updated # 'chart_cleanup' iterations in a row. @@ -61,7 +65,7 @@ chart_cleanup: 0 # # JOBs sharing a name are mutually exclusive # update_every: 3 # [optional] the JOB's data collection frequency # priority: 60000 # [optional] the JOB's order on the dashboard -# retries: 60 # [optional] the JOB's number of restoration attempts +# penalty: yes # the JOB's penalty # timeout: 1 # [optional] the timeout when connecting, supports decimals (e.g. 0.5s) # url: 'http[s]://host-ip-or-dns[:port][path]' # # [required] the remote host url to connect to. If [:port] is missing, it defaults to 80 |