From 50485bedfd9818165aa1d039d0abe95a559134b7 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 8 Feb 2019 08:31:03 +0100 Subject: Merging upstream version 1.12.0. Signed-off-by: Daniel Baumann --- collectors/python.d.plugin/httpcheck/httpcheck.chart.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'collectors/python.d.plugin/httpcheck/httpcheck.chart.py') 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): """ -- cgit v1.2.3