Automattic / Automattic/jetpack
VaultPress: Reduce the backup frequency for older files in the uploads directory
- Dominant language
- PHP
- Stars
- 1.8k
- Forks
- 898
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 774
Description
### Impacted plugin
VaultPress
### What
Reduce the backup frequency for older files in the uploads directory
### How
Hi there,
In older sites, VaultPress takes a really long time to finish backing up everything. It happens because it tries sync the entire /uploads/ folder every single day. This makes no sense to do that. Only the most recent month will have new content everyday.
Older folders will only change if the owner make some drastic change, like rebuilding all the thumbnails. Even in this case, there's no need to sync every single day.
So my suggestion is that VP has more granular rules for the uploads folder. Once the full backup is made, VaultPress could sync previous years last ofter: starting from once a week, then 2 weeks, then once a month. It could also have a button to schedule a full sync, in case the user changed the folders and needs to speed up the process.
Or, at least give us an option to set this configs in the `wp-admin` or `wp-config.php`.
I have two sites that are over 16 years old, with 1,7 million files and 110GB of data. Older files don't change at all, but still, VP takes a lot of CPU everyday to read every single file that are in those two uploads folders.
Since those options doesn't exist today, i had to ask the support to completely disable the backup of my /uploads folder.
Contributor guide
Research direction
No files, tests, or entry points are named. Start by locating VaultPress handling for uploads backups and its scheduling or configuration paths, then determine the scope of age-based frequencies and an optional full sync; done should include a defined configuration and verification of reduced scanning for older files.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100