borgend/backup.py

changeset 107
f63835e9f29e
parent 106
a7bdc239ef62
child 108
6409aa77ddd5
equal deleted inserted replaced
106:a7bdc239ef62 107:f63835e9f29e
670 reason='post-prune' 670 reason='post-prune'
671 elif Operation.LIST in self.previous_operation_of_type: 671 elif Operation.LIST in self.previous_operation_of_type:
672 prev=self.previous_operation_of_type[Operation.LIST] 672 prev=self.previous_operation_of_type[Operation.LIST]
673 if prev.ok(): 673 if prev.ok():
674 return None 674 return None
675 if self.retry_interval==0: 675 if self.retry_interval<=0:
676 # Do not retry in case of errors if retry interval is zero 676 # Do not retry in case of errors if retry interval is <= 0
677 return None 677 return None
678 # Attempt after retry interval 678 # Attempt after retry interval
679 tm=MonotonicTime.after_other(prev.finish_time, self.retry_interval) 679 tm=MonotonicTime.after_other(prev.finish_time, self.retry_interval)
680 else: 680 else:
681 # Nothing has been attempted: run immediately 681 # Nothing has been attempted: run immediately
705 # Previous operation has been performed; perform after 705 # Previous operation has been performed; perform after
706 # retry interval if there were errors, otherwise after 706 # retry interval if there were errors, otherwise after
707 # standard interval. 707 # standard interval.
708 prev=self.previous_operation_of_type[optype] 708 prev=self.previous_operation_of_type[optype]
709 if not prev.ok(): 709 if not prev.ok():
710 # Do not retry in case of errors if retry interval is <= 0
711 if self.retry_interval<=0:
712 return None
710 tm=MonotonicTime.after_other(prev.start_time, 713 tm=MonotonicTime.after_other(prev.start_time,
711 self.retry_interval) 714 self.retry_interval)
712 return Operation(optype, tm, reason='retry') 715 return Operation(optype, tm, reason='retry')
713 elif standard_interval>0: 716 elif standard_interval>0:
714 tm=self.timeclass.after_other(prev.start_time, 717 tm=self.timeclass.after_other(prev.start_time,

mercurial