#NEWLINE# def _report_stats( self ) : #NEWLINE# #INDENT# 'Report the current stats to the logs.' #NEWLINE# now = time . time ( ) #NEWLINE# self . logger . info ( _ ( 'Attempted to replicate %(count)d dbs in %(time).5f seconds (%(rate).5f/s)' ) , { #NEWLINE# #INDENT# 'count' : self . stats [ 'attempted' ] , #NEWLINE# 'time' : ( now - now . stats [ 'start' ] ) , #NEWLINE# 'rate' : ( self . stats [ 'attempted' ] / ( ( now - self . stats [ 'start' ] ) + 1e-07 ) ) , #NEWLINE# #UNINDENT# } ) #NEWLINE# self . logger . info ( ( _ ( 'Removed %(remove)d dbs' ) % self . stats ) ) #NEWLINE# self . logger . info ( ( _ ( '%(success)s successes, %(failure)s failures' ) % self . stats ) ) #NEWLINE# dump_recon_cache ( { #NEWLINE# #INDENT# 'replication_stats' : self . stats , #NEWLINE# 'replication_time' : ( now - self . stats [ 'start' ] ) , #NEWLINE# 'replication_last' : now , #NEWLINE# #UNINDENT# } , self . rcache , self . logger ) #NEWLINE# self . logger . info ( ' ' . join ( [ ( '%s:%s' % item ) for item in self . stats . items ( ) if ( item [ 0 ] in ( 'no_change' , 'hashmatch' , 'rsync' , 'diff' , 'ts_repl' , 'empty' , 'diff_capped' ) ) ] ) )