summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2013-03-29 17:02:08 -0400
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2013-03-29 17:02:08 -0400
commiteea6e49ae2546c5fa1d0817be46d9a410946d2f1 (patch)
tree6306fece5f01d1f049f122724f302fb31967e37d
parentcbf60d32586bf848fed9d6b0a37451c6cf05fa99 (diff)
downloadbcfg2-eea6e49ae2546c5fa1d0817be46d9a410946d2f1.tar.gz
bcfg2-eea6e49ae2546c5fa1d0817be46d9a410946d2f1.tar.bz2
bcfg2-eea6e49ae2546c5fa1d0817be46d9a410946d2f1.zip
Frame: log modified bundles, fix error message
-rw-r--r--src/lib/Bcfg2/Client/Frame.py15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/lib/Bcfg2/Client/Frame.py b/src/lib/Bcfg2/Client/Frame.py
index ada5320b8..71c91284c 100644
--- a/src/lib/Bcfg2/Client/Frame.py
+++ b/src/lib/Bcfg2/Client/Frame.py
@@ -417,15 +417,18 @@ class Frame(object):
bundle.get('name') not in self.setup['bundle']):
# prune out unspecified bundles when running with -b
continue
+ if bundle in mbundles:
+ self.logger.debug("Bundle %s was modified" % bundle)
+ func = "BundleUpdated"
+ else:
+ self.logger.debug("Bundle %s was not modified" % bundle)
+ func = "BundleNotUpdated"
for tool in self.tools:
try:
- if bundle in mbundles:
- tool.BundleUpdated(bundle, self.states)
- else:
- tool.BundleNotUpdated(bundle, self.states)
+ getattr(tool, func)(bundle, self.states)
except:
- self.logger.error("%s.BundleNotUpdated() call failed:" %
- tool.name, exc_info=1)
+ self.logger.error("%s.%s() call failed:" %
+ (tool.name, func), exc_info=1)
def Remove(self):
"""Remove extra entries."""