pruning: implement 'grid' keep rule

This commit is contained in:
Christian Schwarz
2018-09-24 17:30:03 +02:00
parent 328ac687f6
commit 9e941d5be5
11 changed files with 138 additions and 190 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ type RetentionIntervalList []RetentionInterval
type PruneGrid struct {
Type string `yaml:"type"`
Grid RetentionIntervalList `yaml:"grid"`
KeepBookmarks string `yaml:"keep_bookmarks"`
Regex string `yaml:"regex"`
}
type RetentionInterval struct {
+1 -1
View File
@@ -25,4 +25,4 @@ jobs:
keep_receiver:
- type: grid
grid: 1x1h(keep=all) | 24x1h | 35x1d | 6x30d
keep_bookmarks: all
regex: "zrepl_.*"
+2 -2
View File
@@ -17,8 +17,8 @@ jobs:
count: 10
- type: grid
grid: 1x1h(keep=all) | 24x1h | 14x1d
keep_bookmarks: all
regex: "zrepl_.*"
keep_receiver:
- type: grid
grid: 1x1h(keep=all) | 24x1h | 35x1d | 6x30d
keep_bookmarks: all
regex: "zrepl_.*"
+2 -2
View File
@@ -19,10 +19,10 @@ jobs:
count: 10
- type: grid
grid: 1x1h(keep=all) | 24x1h | 14x1d
keep_bookmarks: all
regex: "^zrepl_.*"
keep_receiver:
- type: prefix
prefix: keep_
- type: grid
grid: 1x1h(keep=all) | 24x1h | 35x1d | 6x30d
keep_bookmarks: all
regex: "^zrepl_.*"
+2 -3
View File
@@ -18,9 +18,8 @@ jobs:
count: 10
- type: grid
grid: 1x1h(keep=all) | 24x1h | 14x1d
keep_bookmarks: all
regex: "^zrepl_.*"
keep_receiver:
- type: grid
grid: 1x1h(keep=all) | 24x1h | 35x1d | 6x30d
keep_bookmarks: all
regex: "^zrepl_.*"