-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compaction Scheduling #1981
Compaction Scheduling #1981
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this nice addition!
3b5bcbb
to
277b9b9
Compare
@m3nu All checks passed, can we merge this now? |
277b9b9
to
d89b832
Compare
src/vorta/store/models.py
Outdated
@@ -90,6 +90,8 @@ class BackupProfileModel(BaseModel): | |||
schedule_make_up_missed = pw.BooleanField(default=True) | |||
validation_on = pw.BooleanField(default=True) | |||
validation_weeks = pw.IntegerField(default=3) | |||
compaction_on = pw.BooleanField(default=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's disable it by default to avoid surprising behavior.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure!
d89b832
to
bd0433a
Compare
Description
Allows users to run
borg compact
after specified intervals. Added 2 columns to the profile model:compaction_on
to check/uncheck scheduling, andcompaction_weeks
to set interval in weeks. Default interval set to 3 weeks.Related Issue
Resolves #1718
Motivation and Context
Backup space usage is exploding for some people until they realize they have to run compact manually. This allows users to schedule running compact just like validation.
How Has This Been Tested?
Tested manually by setting
compaction_cutoff
to minutes instead of days inscheduler.py
.Screenshots (if appropriate):
Types of changes
Checklist:
I provide my contribution under the terms of the license of this repository and I affirm the Developer Certificate of Origin.