Author: justi9
Date: 2010-06-30 15:10:29 -0400 (Wed, 30 Jun 2010)
New Revision: 4058
Modified:
mgmt/newdata/mint/python/mint/update.py
Log:
Don't mark an object synced until sql executes without failing; add more debugging
info
Modified: mgmt/newdata/mint/python/mint/update.py
===================================================================
--- mgmt/newdata/mint/python/mint/update.py 2010-06-30 17:23:24 UTC (rev 4057)
+++ mgmt/newdata/mint/python/mint/update.py 2010-06-30 19:10:29 UTC (rev 4058)
@@ -226,8 +226,6 @@
statements.append(sql)
- obj._sync_time = now
-
if sample_columns:
sample_columns.append(cls.sql_samples_table._qmf_update_time)
@@ -245,15 +243,37 @@
except:
log.exception("%s failed", self)
- log.info("Sql text: %s", text)
- log.info("Sql values:")
+ log.error("Sql text: %s", text)
+ log.error("Sql values:")
for item in sorted(obj.__dict__.items()):
- log.info(" %-34s %r", *item)
+ log.error(" %-34s %r", *item)
- log.info("Sql row count: %i", cursor.rowcount)
+ log.error("Sql object columns:")
+ for item in sorted(object_columns):
+ log.error(" %-34s", item)
+
+ log.error("Sql sample columns:")
+
+ for item in sorted(sample_columns):
+ log.error(" %-34s", item)
+
+ log.error("Sql row count: %i", cursor.rowcount)
+
+ log.error("Qmf properties:")
+
+ for item in sorted(self.object.getProperties()):
+ log.error(" %-34s %r", *item)
+
+ log.error("Qmf statistics:")
+
+ for item in sorted(self.object.getStatistics()):
+ log.error(" %-34s %r", *item)
+
raise
+
+ obj._sync_time = now
else:
stats.dropped += 1
Show replies by date