1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-22 02:51:03 +00:00

Merge pull request #463 from skyeagle/master

Updated swift plugins
This commit is contained in:
Steve Schnepp 2014-02-27 17:21:35 +01:00
commit dd4de036bc
2 changed files with 4 additions and 2 deletions

View file

@ -45,4 +45,6 @@ except IndexError:
async_r = requests.get("http://%s:%s/recon/async" \ async_r = requests.get("http://%s:%s/recon/async" \
% (swift_server, os.getenv("SWIFT_OBJECT_PORT", "6000"))) % (swift_server, os.getenv("SWIFT_OBJECT_PORT", "6000")))
print "async_pending.value %d" % json.loads(async_r.text)['async_pending'] async_r = json.loads(async_r.text)['async_pending']
async_r = int(0 if async_r is None else async_r)
print "async_pending.value %d" % async_r

View file

@ -64,7 +64,7 @@ except IndexError:
pass pass
with os.popen("swift-dispersion-report -j %s" \ with os.popen("swift-dispersion-report -j %s" \
% os.getenv("SWIFT_DISPERSION_CONFIG", "/etc/swift/swift.conf")) as report: % os.getenv("SWIFT_DISPERSION_CONFIG", "/etc/swift/dispersion.conf")) as report:
stats = json.load(report) stats = json.load(report)
for type_, values in stats.iteritems(): for type_, values in stats.iteritems():