]> arthur.barton.de Git - netdata.git/blobdiff - python.d/apache.chart.py
Merge pull request #1807 from l2isbad/elasticsearch_plugin_p26
[netdata.git] / python.d / apache.chart.py
index e40d388ed83ce2c37f314744d6c3749b76094dc2..2e4d16dd379425d5d9ea32f0197a4b70565817cb 100644 (file)
@@ -1,5 +1,5 @@
 # -*- coding: utf-8 -*-
-# Description: apache netdata python.d plugin
+# Description: apache netdata python.d module
 # Author: Pawel Krupa (paulfantom)
 
 from base import UrlService
@@ -7,7 +7,7 @@ from base import UrlService
 # default module values (can be overridden per job in `config`)
 # update_every = 2
 priority = 60000
-retries = 5
+retries = 60
 
 # default job configuration (overridden by python.d.plugin)
 # config = {'local': {
@@ -71,7 +71,7 @@ class Service(UrlService):
     def __init__(self, configuration=None, name=None):
         UrlService.__init__(self, configuration=configuration, name=name)
         if len(self.url) == 0:
-            self.url = "http://www.apache.org/server-status?auto"
+            self.url = "http://localhost/server-status?auto"
         self.order = ORDER
         self.definitions = CHARTS
         self.assignment = {"BytesPerReq": 'size_req',
@@ -86,13 +86,13 @@ class Service(UrlService):
                            "ConnsAsyncClosing": 'closing',
                            "ConnsAsyncWriting": 'writing'}
 
-    def _formatted_data(self):
+    def _get_data(self):
         """
         Format data received from http request
         :return: dict
         """
         try:
-            raw = self._get_data().split("\n")
+            raw = self._get_raw_data().split("\n")
         except AttributeError:
             return None
         data = {}