![](https://secure.gravatar.com/avatar/cdfdc7382d7a988a6574e78e3bb6310c.jpg?s=120&d=mm&r=g)
Dear Christian, I didn't answer outright, because I gave it a hard and long thinking about this session. Please #define N 3. In short, In week 48, I expect - W45, W46, W47, if BiT didn't take this week's backup. - W46, W47, W48, if BiT took this week's backups. However, it's a bit more complicated than that. I have questions: - What will be the effect if I take daily backups (which I do). Then I expect this week's individual backups (W48), and W47, W46 & W45 as weekly backups. - What will be the effect if I take weekly backups only? Then I expect W48, W47, W46. Since the numbers are tunable, the algorithm looks very complicated to approach and get it correctly. What I propose to implement is a slightly more complicated manner: - There's should be a well defined model of how backups are grouped. - Maybe BiT should consider having "buckets" of backups (daily, weekly, monthly, yearly). - A backup should migrate to the broader bucket (daily -> weekly -> monthly -> yearly) buckets as soon as it's kicked off its current one due to age. - The first entry of a bucket should allow snapshots merged into it until its rotation time comes. - If you keep 4 daily backups, the 5th one should move to weekly, and should accept new backups merged into it for a week, then rotated. - If you keep 6 weekly backups, 7th should be demoted to monthly, and should accept more weekly backups until it's a month old. The model is not complete, and somewhat complicated, but I think it can be iterated to something which makes sense and easier to implement and maintain. I'll try to polish it and report under the GitHub bug, too. Cheers, Hakan On 11/26/24 6:23 PM, c.buhtz@posteo.jp wrote:
Hi Hakan,
thank you for your thoughts.
Am 26.11.2024 12:26 schrieb Hakan Bayındır:
"I'll have N weekly copies at all times"
OK, but is the current week a week no matter if it is complete or not? ;)
Let's imagine your setting says 3 weeks to keep. Today we do have week number 48 in this year. What do you think? Will BIT keep the 3 backups for week 45, 46 and 47 or 46, 47 and 48?
I would like to know what you expect as a user. I now what BIT is doing or try (because of bugs) to does in this case.
Christian _______________________________________________ Bit-dev mailing list -- bit-dev@python.org To unsubscribe send an email to bit-dev-leave@python.org https://mail.python.org/mailman3/lists/bit-dev.python.org/ Member address: hakan@bayindir.org