@@ -542,8 +542,8 @@ def crawlwrap(self, oneshot=False, register_time=None):
542542 rconf .volume_id = self .uuid
543543 if self .volinfo :
544544 if self .volinfo ['retval' ]:
545- logging .warn (lf ("primary cluster's info may not be valid" ,
546- error = self .volinfo ['retval' ]))
545+ logging .warning (lf ("primary cluster's info may not be valid" ,
546+ error = self .volinfo ['retval' ]))
547547 else :
548548 raise GsyncdError ("primary volinfo unavailable" )
549549 self .lastreport ['time' ] = time .time ()
@@ -1169,9 +1169,9 @@ def process_change(self, change, done, retry):
11691169 entries .append (
11701170 edct (ty , stat = st , entry = en , gfid = gfid , link = rl ))
11711171 else :
1172- logging .warn (lf ('ignoring op' ,
1173- gfid = gfid ,
1174- type = ty ))
1172+ logging .warning (lf ('ignoring op' ,
1173+ gfid = gfid ,
1174+ type = ty ))
11751175 elif et == self .TYPE_GFID :
11761176 # If self.unlinked_gfids is available, then that means it is
11771177 # retrying the changelog second time. Do not add the GFID's
@@ -1202,8 +1202,8 @@ def process_change(self, change, done, retry):
12021202 (gconf .get ("sync-xattrs" ) or gconf .get ("sync-acls" )):
12031203 datas .add (os .path .join (pfx , ec [0 ]))
12041204 else :
1205- logging .warn (lf ('got invalid fop type' ,
1206- type = et ))
1205+ logging .warning (lf ('got invalid fop type' ,
1206+ type = et ))
12071207 logging .debug ('entries: %s' % repr (entries ))
12081208
12091209 # Increment counters for Status
@@ -1407,8 +1407,8 @@ def process(self, changes, done=1):
14071407 # entry_ops() that failed... so we retry the _whole_ changelog
14081408 # again.
14091409 # TODO: remove entry retries when it's gets fixed.
1410- logging .warn (lf ('incomplete sync, retrying changelogs' ,
1411- files = list (map (os .path .basename , changes ))))
1410+ logging .warning (lf ('incomplete sync, retrying changelogs' ,
1411+ files = list (map (os .path .basename , changes ))))
14121412
14131413 # Reset the Data counter before Retry
14141414 self .status .dec_value ("data" , self .files_in_batch )
@@ -1708,8 +1708,8 @@ def Xsyncer():
17081708 time = item [1 ]))
17091709 self .upd_stime (item [1 ][1 ], item [1 ][0 ])
17101710 else :
1711- logging .warn (lf ('unknown tuple in comlist' ,
1712- entry = item ))
1711+ logging .warning (lf ('unknown tuple in comlist' ,
1712+ entry = item ))
17131713 except IndexError :
17141714 time .sleep (1 )
17151715
@@ -1787,20 +1787,20 @@ def Xcrawl(self, path='.', xtr_root=None):
17871787 xtr_root = self .xtime ('.' , self .secondary )
17881788 if isinstance (xtr_root , int ):
17891789 if xtr_root != ENOENT :
1790- logging .warn (lf ("secondary cluster not returning the "
1791- "xtime for root" ,
1792- error = xtr_root ))
1790+ logging .warning (lf ("secondary cluster not returning the "
1791+ "xtime for root" ,
1792+ error = xtr_root ))
17931793 xtr_root = self .minus_infinity
17941794 xtl = self .xtime (path )
17951795 if isinstance (xtl , int ):
1796- logging .warn ("primary cluster's xtime not found" )
1796+ logging .warning ("primary cluster's xtime not found" )
17971797 xtr = self .xtime (path , self .secondary )
17981798 if isinstance (xtr , int ):
17991799 if xtr != ENOENT :
1800- logging .warn (lf ("secondary cluster not returning the "
1801- "xtime for dir" ,
1802- path = path ,
1803- error = xtr ))
1800+ logging .warning (lf ("secondary cluster not returning the "
1801+ "xtime for dir" ,
1802+ path = path ,
1803+ error = xtr ))
18041804 xtr = self .minus_infinity
18051805 xtr = max (xtr , xtr_root )
18061806 zero_zero = (0 , 0 )
@@ -1815,32 +1815,32 @@ def Xcrawl(self, path='.', xtr_root=None):
18151815 dem = self .primary .server .entries (path )
18161816 pargfid = self .primary .server .gfid (path )
18171817 if isinstance (pargfid , int ):
1818- logging .warn (lf ('skipping directory' ,
1819- path = path ))
1818+ logging .warning (lf ('skipping directory' ,
1819+ path = path ))
18201820 for e in dem :
18211821 bname = e
18221822 e = os .path .join (path , e )
18231823 xte = self .xtime (e )
18241824 if isinstance (xte , int ):
1825- logging .warn (lf ("irregular xtime" ,
1826- path = e ,
1827- error = errno .errorcode [xte ]))
1825+ logging .warning (lf ("irregular xtime" ,
1826+ path = e ,
1827+ error = errno .errorcode [xte ]))
18281828 continue
18291829 if not self .need_sync (e , xte , xtr ):
18301830 continue
18311831 st = self .primary .server .lstat (e )
18321832 if isinstance (st , int ):
1833- logging .warn (lf ('got purged in the interim' ,
1834- path = e ))
1833+ logging .warning (lf ('got purged in the interim' ,
1834+ path = e ))
18351835 continue
18361836 if self .is_sticky (e , st .st_mode ):
18371837 logging .debug (lf ('ignoring sticky bit file' ,
18381838 path = e ))
18391839 continue
18401840 gfid = self .primary .server .gfid (e )
18411841 if isinstance (gfid , int ):
1842- logging .warn (lf ('skipping entry' ,
1843- path = e ))
1842+ logging .warning (lf ('skipping entry' ,
1843+ path = e ))
18441844 continue
18451845 mo = st .st_mode
18461846 self .counter += 1 if ((stat .S_ISDIR (mo ) or
0 commit comments