diff options
author | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2012-10-30 11:35:46 -0400 |
---|---|---|
committer | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2013-01-17 10:44:14 -0500 |
commit | 45c7bbf24ae3c6530f33ebb33c062818ad44816d (patch) | |
tree | d39fbacaae2d712fdf250a9bce19f9737392539e /src/lib/Bcfg2/Server/Plugins/FileProbes.py | |
parent | a6b269011b2f1e84c650239065e56778591f087e (diff) | |
download | bcfg2-45c7bbf24ae3c6530f33ebb33c062818ad44816d.tar.gz bcfg2-45c7bbf24ae3c6530f33ebb33c062818ad44816d.tar.bz2 bcfg2-45c7bbf24ae3c6530f33ebb33c062818ad44816d.zip |
added a module-level FAM object to avoid passing it as an argument a billion times
Diffstat (limited to 'src/lib/Bcfg2/Server/Plugins/FileProbes.py')
-rw-r--r-- | src/lib/Bcfg2/Server/Plugins/FileProbes.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/Bcfg2/Server/Plugins/FileProbes.py b/src/lib/Bcfg2/Server/Plugins/FileProbes.py index 365549e85..461b718e2 100644 --- a/src/lib/Bcfg2/Server/Plugins/FileProbes.py +++ b/src/lib/Bcfg2/Server/Plugins/FileProbes.py @@ -11,6 +11,7 @@ import lxml.etree import Bcfg2.Options import Bcfg2.Server import Bcfg2.Server.Plugin +import Bcfg2.Server.FileMonitor from Bcfg2.Compat import b64decode #: The probe we send to clients to get the file data. Returns an XML @@ -69,7 +70,6 @@ class FileProbes(Bcfg2.Server.Plugin.Plugin, Bcfg2.Server.Plugin.Plugin.__init__(self, core, datastore) Bcfg2.Server.Plugin.Probing.__init__(self) self.config = FileProbesConfig(os.path.join(self.data, 'config.xml'), - fam=core.fam, should_monitor=True) self.entries = dict() self.probes = dict() @@ -196,7 +196,7 @@ class FileProbes(Bcfg2.Server.Plugin.Plugin, if tries >= 10: self.logger.error("%s still not registered" % filename) return - self.core.fam.handle_events_in_interval(1) + Bcfg2.Server.FileMonitor.get_fam().handle_events_in_interval(1) try: cfg.entries[filename].bind_entry(entry, metadata) except Bcfg2.Server.Plugin.PluginExecutionError: |