stats_gatherer: verbose debug logging

one of the storage servers is throwing foolscap violations about the
return value of get_stats().  this adds a log of the data returned
to the foolscap log event stream at the debug level '12' (between
NOISY(10) and OPERATIONAL(20))  hopefully this will facilitate
finding the cause of this problem.
This commit is contained in:
robk-tahoe 2008-04-09 16:10:53 -07:00
parent 3b4d29b013
commit 0d2eb1edf6

View File

@ -107,7 +107,10 @@ class StatsProvider(foolscap.Referenceable, service.MultiService):
stats = {}
for sp in self.stats_producers:
stats.update(sp.get_stats())
return { 'counters': self.counters, 'stats': stats }
#return { 'counters': self.counters, 'stats': stats }
ret = { 'counters': self.counters, 'stats': stats }
log.msg(format='get_stats() -> %s', args=(pprint.pformat(ret),), level=12)
return ret
def _connected(self, gatherer, nickname):
gatherer.callRemoteOnly('provide', self, nickname or '')