changed throttling
This commit is contained in:
parent
b89862f304
commit
5b051aae32
|
@ -48,11 +48,13 @@ class BaseListener(object):
|
|||
class OrganizeListener(BaseListener, pyinotify.ProcessEvent, Loggable):
|
||||
def process_IN_CLOSE_WRITE(self, event):
|
||||
#self.logger.info("===> handling: '%s'" % str(event))
|
||||
self.process_to_organize(event)
|
||||
#self.process_to_organize(event)
|
||||
pass
|
||||
# got cookie
|
||||
def process_IN_MOVED_TO(self, event):
|
||||
#self.logger.info("===> handling: '%s'" % str(event))
|
||||
self.process_to_organize(event)
|
||||
#self.process_to_organize(event)
|
||||
pass
|
||||
|
||||
def process_default(self, event):
|
||||
pass
|
||||
|
|
|
@ -18,7 +18,7 @@ class ManagerTimeout(threading.Thread,Loggable):
|
|||
secnods. This used to be just a work around for cc-4235 but recently
|
||||
became a permanent solution because it's "cheap" and reliable
|
||||
"""
|
||||
def __init__(self, manager, interval=3):
|
||||
def __init__(self, manager, interval=1.5):
|
||||
# TODO : interval should be read from config and passed here instead
|
||||
# of just using the hard coded value
|
||||
threading.Thread.__init__(self)
|
||||
|
|
|
@ -72,12 +72,12 @@ class Organizer(ReportHandler,Loggable):
|
|||
directory=d)
|
||||
return cb
|
||||
|
||||
time.sleep(0.05)
|
||||
time.sleep(0.02)
|
||||
|
||||
mmp.magic_move(event.path, new_path,
|
||||
after_dir_make=new_dir_watch(dirname(new_path)))
|
||||
|
||||
time.sleep(0.05)
|
||||
time.sleep(0.02)
|
||||
|
||||
# The reason we need to go around saving the owner in this ass
|
||||
# backwards way is bewcause we are unable to encode the owner id
|
||||
|
|
Loading…
Reference in New Issue