]> arthur.barton.de Git - netdata.git/blobdiff - python.d/python_modules/base.py
comments
[netdata.git] / python.d / python_modules / base.py
index 03754da629a9dfc9c2b41be3e83d841733237a62..b9737facd71939fb6dd2a33428192e1b8f9fab52 100644 (file)
@@ -75,6 +75,11 @@ class BaseService(threading.Thread):
                           'freq': freq}
 
     def _run_once(self):
+        """
+        Executes self.update(interval) and draws run time chart.
+        Return value presents exit status of update()
+        :return: boolean
+        """
         t_start = time.time()
         # check if it is time to execute job update() function
         if self.timetable['next'] > t_start:
@@ -103,6 +108,11 @@ class BaseService(threading.Thread):
         return True
 
     def run(self):
+        """
+        Runs job in thread. Handles retries.
+        Exits when job failed or timed out.
+        :return: None
+        """
         self.timetable['last'] = time.time()
         while True:
             try: