rdsn icon indicating copy to clipboard operation
rdsn copied to clipboard

BREAKING CHANGE: fix behavior when backup period less than 1day

Open zhangyifan27 opened this issue 4 years ago • 1 comments

Before this patch, we cannot start periodic backup correctly when backup_interval_secends less than one_day_seconds, because there is some issues in should_start_backup_unlocked().

Now we start the first backup only when cur_time == start_time, then periodically start backup at intervals defined by backup_interval_secends. The start time of subsequent backups is only related to last_backup_start_time and backup_interval_secends, so the start_time of a policy shouldn't be modified if a backup has already started.

zhangyifan27 avatar Jan 11 '21 10:01 zhangyifan27

@acelyc111 The new implementation is actually making the kernel design simpler than before, considering the deleted code that handles clock drift. We don't have to avoid the two backups being too close, or similiar edge cases.

From the users perspective, this design is primitive and prone to misuse. I prefer this problem to be solved in Backup Manager. You can set up rules or limitations in Backup Manager.

neverchanje avatar Feb 20 '21 10:02 neverchanje