-
-
Notifications
You must be signed in to change notification settings - Fork 741
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
backup series, fixes #7930 #8379
backup series, fixes #7930 #8379
Conversation
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #8379 +/- ##
==========================================
- Coverage 81.73% 81.68% -0.06%
==========================================
Files 70 70
Lines 12650 12699 +49
Branches 2288 2300 +12
==========================================
+ Hits 10340 10373 +33
- Misses 1665 1671 +6
- Partials 645 655 +10 ☔ View full report in Codecov by Sentry. |
b215bb6
to
d17b597
Compare
aid:<archive-id-prefix> can be used for -a / --match-archives to match on the archive id (prefix) instead of the name. NAME positional argument now also supports matching (and aid:), but requires that there is exactly ONE result.
so if one works with backup series, one can just do: borg prune --keep-daily 30 seriesname seriesname will then do a precise match on the archive names and select that series.
- we should always output name and id when talking about an archive - no problem anymore if names in archives directory are "duplicate" - use "by-id" archives directory entry delete function - rewrite/simplify test for borg check --undelete-archives
d3a8f87
to
470168b
Compare
for the archives directory, we only need to know the archive IDs, everything else can be fetched from the ArchiveItem in the repo. so we store empty files into archives/* with the archiv ID as name. this makes some "by-id" operations much easier and we don't have to deal with a useless "store_key" anymore. removed .delete method - we can't delete by name anymore as we allow duplicate names for the series feature. everything uses delete_by_id() now. also: simplify, clean up, refactor
LegacyRepository of borg2 knows this method.
470168b
to
a4d2fc8
Compare
in borg 1.x, we used to put a timestamp into the archive name to make it unique, because borg1 required that. borg2 does not require unique archive names, but it encourages you to even use an identical archive name within the same SERIES of archives. that makes matching (e.g. for prune, but also at other places) much simpler and borg KNOWS which archives belong to the same series.
the archives list entries have (since ever):
borg1:
borg2 (this PR):
aid:unique_archive_id_prefix
because the name does not necessarily work for that anymore when using the always-same-series-name method.aid: can be used as a pattern for the -a / --match-archives cli option to match on the archive id (prefix) instead of the archive name.
NAME positional cli argument now also supports patterns (including aid:), but requires that there is exactly ONE result from the match against the list of archives. that way, it can be used e.g. for
borg extract NAME
.Some stuff got simpler by this change: