@cryptotaxi247 / netdata-1 / commits / d58707e86

hit and miss values

paulfantom committed Jul 1, 2016 at 18:06 UTC d58707e867ceb3945d9c820d7519bbaaafd2677b
1 file changed +2 -4
python.d/apache_cache.chart.py
+2 -4
@@ -41,7 +41,6 @@ class Service(LogService):
41
42 hit = 0
43 miss = 0
44 -
44 for line in raw:
45 if "cache hit" in line:
46 hit += 1
@@ -52,6 +51,5 @@ class Service(LogService):
51 if total == 0:
52 return None
53
55 - hit_percent = int(hit/float(total) * 100)
56 - return {'hit': hit_percent,
57 - 'miss': 100 - hit_percent}
54 + return {'hit': int(hit/float(total) * 100),
55 + 'miss': int(miss/float(total) * 100)}