diff options
author | martinko | 2012-11-28 16:32:01 +0000 |
---|---|---|
committer | martinko | 2012-11-28 16:32:01 +0000 |
commit | 6eda59aaf560bb3c76d5eb4bb63674e6c508a296 (patch) | |
tree | 2ef58d9e2f005e8ffc199c24a3a46cf3fd2dfef4 | |
parent | 9fa1e110a1212815a8f5b218f13afc8f857b12fa (diff) |
londiste/syncer: spit out debug msgs when waiting too
-rw-r--r-- | python/londiste/syncer.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/python/londiste/syncer.py b/python/londiste/syncer.py index eb26a207..d5879f23 100644 --- a/python/londiste/syncer.py +++ b/python/londiste/syncer.py @@ -87,11 +87,12 @@ class Syncer(skytools.DBScript): if consumer_lag < ticker_lag + 5: break + lag_msg = 'Consumer lag: %s, ticker_lag %s, too big difference, waiting' if c % 30 == 0: - self.log.warning('Consumer lag: %s, ticker_lag %s, too big difference, waiting', - consumer_lag, ticker_lag) + self.log.warning(lag_msg, consumer_lag, ticker_lag) + else: + self.log.debug(lag_msg, consumer_lag, ticker_lag) c += 1 - time.sleep(1) def get_tables(self, db): |