diff options
Diffstat (limited to 'src/lib/Server')
-rw-r--r-- | src/lib/Server/Plugins/Snapshots.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/Server/Plugins/Snapshots.py b/src/lib/Server/Plugins/Snapshots.py index c4802a9c3..b71f085d9 100644 --- a/src/lib/Server/Plugins/Snapshots.py +++ b/src/lib/Server/Plugins/Snapshots.py @@ -1,15 +1,19 @@ #import lxml.etree +import logging import binascii import difflib #import sqlalchemy #import sqlalchemy.orm import Bcfg2.Server.Plugin import Bcfg2.Server.Snapshots +import Bcfg2.Logger from Bcfg2.Server.Snapshots.model import Snapshot import Queue import time import threading +logger = logging.getLogger('Snapshots') + ftypes = ['ConfigFile', 'SymLink', 'Directory'] datafields = {'Package': ['version'], 'Service': ['status'], @@ -118,5 +122,5 @@ class Snapshots(Bcfg2.Server.Plugin.Statistics, self.session.add(snap) self.session.commit() t3 = time.time() - print "Storage took", t3-t2 + logger.info("Snapshot storage took %fs" % (t3-t2)) return True |