1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-21 18:41:03 +00:00

Fix indexcounters and globallock in 2.2 and 2.4 version

This commit is contained in:
Dimitri Savineau 2013-05-13 16:54:57 -04:00
parent 3c08471566
commit 271a38f0ba
2 changed files with 11 additions and 2 deletions

View file

@ -16,7 +16,11 @@ def getServerStatus():
return json.loads( raw )["serverStatus"]
def get():
return getServerStatus()["indexCounters"]["btree"]
status = getServerStatus()
if status["version"] >= "2.4.0":
return getServerStatus()["indexCounters"]
else:
return getServerStatus()["indexCounters"]["btree"]
def doData():
for k,v in get().iteritems():