Commit d34ed7b9 authored by Giorgos Korfiatis's avatar Giorgos Korfiatis
Browse files

no callback in notifiers

parent 020e50dc
...@@ -526,7 +526,7 @@ class LocalfsFileClient(FileClient): ...@@ -526,7 +526,7 @@ class LocalfsFileClient(FileClient):
def prepare_target(self, target_state): def prepare_target(self, target_state):
return LocalfsTargetHandle(self.settings, target_state) return LocalfsTargetHandle(self.settings, target_state)
def notifier(self, callback=None): def notifier(self):
def handle_path(path): def handle_path(path):
rel_path = os.path.relpath(path, start=self.ROOTPATH) rel_path = os.path.relpath(path, start=self.ROOTPATH)
objname = utils.to_standard_sep(rel_path) objname = utils.to_standard_sep(rel_path)
......
...@@ -296,7 +296,7 @@ class PithosFileClient(FileClient): ...@@ -296,7 +296,7 @@ class PithosFileClient(FileClient):
(last_modified, candidates)) (last_modified, candidates))
return candidates return candidates
def notifier(self, callback=None): def notifier(self):
interval = self.settings.pithos_list_interval interval = self.settings.pithos_list_interval
class PollPithosThread(utils.StoppableThread): class PollPithosThread(utils.StoppableThread):
def run_body(this): def run_body(this):
......
...@@ -68,8 +68,7 @@ class FileSyncer(object): ...@@ -68,8 +68,7 @@ class FileSyncer(object):
for signature, client in self.clients.iteritems(): for signature, client in self.clients.iteritems():
notifier = self.notifiers.get(signature) notifier = self.notifiers.get(signature)
if not self.thread_is_active(notifier): if not self.thread_is_active(notifier):
self.notifiers[signature] = \ self.notifiers[signature] = client.notifier()
client.notifier(callback=self.probe_file)
else: else:
logger.info("Notifier %s already up" % signature) logger.info("Notifier %s already up" % signature)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment