diff options
| author | Csaba Henk <csaba@gluster.com> | 2012-01-05 02:01:00 +0100 | 
|---|---|---|
| committer | Vijay Bellur <vijay@gluster.com> | 2012-02-07 09:50:05 -0800 | 
| commit | aec6d5d89249868dc99d8fb432d8ab120bb38ef1 (patch) | |
| tree | b88a33e85cc724711a3243599b75b9f4cb6465d2 /xlators | |
| parent | f4db9775655b24b9896ad697c534caec8868562d (diff) | |
geo-rep: gsyncd: fix up fallback xtime for orphans on master side
Change-Id: I2fa543b4bd317e06ea621ae968300ffb7223a68a
BUG: 771787
Signed-off-by: Csaba Henk <csaba@gluster.com>
Reviewed-on: http://review.gluster.com/2580
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushik BV <kaushikbv@gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
Diffstat (limited to 'xlators')
| -rw-r--r-- | xlators/features/marker/utils/syncdaemon/master.py | 15 | 
1 files changed, 8 insertions, 7 deletions
diff --git a/xlators/features/marker/utils/syncdaemon/master.py b/xlators/features/marker/utils/syncdaemon/master.py index 9e54dc4fa..cd470f315 100644 --- a/xlators/features/marker/utils/syncdaemon/master.py +++ b/xlators/features/marker/utils/syncdaemon/master.py @@ -74,14 +74,15 @@ class GMaster(object):          if isinstance(xt, int) and xt != ENODATA:              return xt          invalid_xtime = (xt == ENODATA or xt < self.volmark) -        if invalid_xtime and opts['create']: -            t = time.time() -            sec = int(t) -            nsec = int((t - sec) * 1000000) -            xt = (sec, nsec) -            rsc.server.set_xtime(path, self.uuid, xt)          if invalid_xtime: -            xt = opts['default_xtime'] +            if opts['create']: +                t = time.time() +                sec = int(t) +                nsec = int((t - sec) * 1000000) +                xt = (sec, nsec) +                rsc.server.set_xtime(path, self.uuid, xt) +            else: +                xt = opts['default_xtime']          return xt      def __init__(self, master, slave):  | 
