summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2017-02-12 19:27:03 +0200
committerLars Wirzenius <liw@liw.fi>2017-02-12 19:27:03 +0200
commitf3808b879394bc123f6f5bc85d1a1092281f34df (patch)
tree6b60fb016dca06d43f66dba491d67056415460be
parent28a120805bb8b7531f76d9556f2d539621ee44f4 (diff)
downloadobnam-f3808b879394bc123f6f5bc85d1a1092281f34df.tar.gz
Add a bit more logging
-rw-r--r--obnamlib/fmt_ga/tree.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/obnamlib/fmt_ga/tree.py b/obnamlib/fmt_ga/tree.py
index 43e6a018..eca6f79a 100644
--- a/obnamlib/fmt_ga/tree.py
+++ b/obnamlib/fmt_ga/tree.py
@@ -160,14 +160,18 @@ class DirectoryObjectCache(object):
def __init__(self):
self.clear()
- self._max_objs = 10**5
+ self._max_objs = 10**3
def _clear_immutable(self): # pragma: no cover
if len(self._objs) >= self._max_objs:
+ logging.debug('DirObjCache has %s iterms', len(self._objs))
for pathname, dirobj in self._objs.items():
if not dirobj.is_mutable():
del self._objs[pathname]
logging.debug('Deleted %s from DirObjCache', pathname)
+ logging.debug(
+ 'After dropping immutable, DirObjCache has %s iterms',
+ len(self._objs))
def clear(self):
self._objs = {}