diff options
author | Csaba Henk <csaba@gluster.com> | 2011-04-13 01:46:05 +0000 |
---|---|---|
committer | Anand Avati <avati@gluster.com> | 2011-04-13 04:43:06 -0700 |
commit | e5c38128fa76b3e11047d49448aab77d3a551804 (patch) | |
tree | 749ec60fc891e1430a9d7bac112a9d660a4bc106 /xlators/features/marker/utils/syncdaemon/master.py | |
parent | 13d1856a40122008dee35a96771f832945c220f8 (diff) |
syncdaemon: force termination for unhandled exception in any thread
Signed-off-by: Csaba Henk <csaba@gluster.com>
Signed-off-by: Anand Avati <avati@gluster.com>
BUG: 2736 (gsyncd hangs if crash occurs in the non-main thread)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2736
Diffstat (limited to 'xlators/features/marker/utils/syncdaemon/master.py')
-rw-r--r-- | xlators/features/marker/utils/syncdaemon/master.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/xlators/features/marker/utils/syncdaemon/master.py b/xlators/features/marker/utils/syncdaemon/master.py index 02cf1be5b05..35dc4ee06aa 100644 --- a/xlators/features/marker/utils/syncdaemon/master.py +++ b/xlators/features/marker/utils/syncdaemon/master.py @@ -6,10 +6,10 @@ import signal import logging import errno from errno import ENOENT, ENODATA -from threading import Thread, currentThread, Condition, Lock +from threading import currentThread, Condition, Lock from gconf import gconf -from syncdutils import FreeObject +from syncdutils import FreeObject, Thread URXTIME = (-1, 0) @@ -108,7 +108,6 @@ class GMaster(object): self.slave.server.keep_alive(vi) time.sleep(gap) t = Thread(target=keep_alive) - t.setDaemon(True) t.start() while not self.terminate: self.crawl() @@ -342,7 +341,6 @@ class Syncer(object): self.pb = PostBox() for i in range(int(gconf.sync_jobs)): t = Thread(target=self.syncjob) - t.setDaemon = True t.start() def syncjob(self): |