return self.data.state
def set_state(self, state):
- logging.info("Setting state of %s to %s" % (self.hostname, state))
+ logging.debug("Setting state of %s to %s" % (self.hostname, state))
if self.state == state:
return
@tornado.gen.coroutine
def check(self):
- logging.info("Running check for mirror %s" % self.hostname)
+ logging.debug("Running check for mirror %s" % self.hostname)
self.db.execute("UPDATE mirrors SET address = %s WHERE id = %s",
self.address, self.id)
# Update state
self.check_state(timestamp)
- logging.info("Successfully updated timestamp from %s" % self.hostname)
+ logging.debug("Successfully updated timestamp from %s" % self.hostname)
+
return True
@tornado.gen.coroutine
self.db.execute("INSERT INTO mirror_files(mirror, filename) \
VALUES(%s, %s)", self.id, file)
- logging.info("Successfully updated mirror filelist from %s" % self.hostname)
+ logging.debug("Successfully updated mirror filelist from %s" % self.hostname)
@property
def development(self):
@tornado.gen.coroutine
def scan_files(self, basepath="/pub/mirror"):
for release in self:
- logging.info("Scanning %s..." % release)
+ logging.debug("Scanning %s..." % release)
with self.db.transaction():
release.scan_files(basepath=basepath)