You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
storagenode/collector: reverse flat file store deletion order
We've killed many times the expiration jobs that were running the old
implementation, which left a lot of hour files that have already been
processed. Running the jobs again requires them to process these files
again, which significantly delays the deletion of the remaining expired
pieces.
By reversing the order, the job will priorities the expired pieces that
has not been deleted yet.
Change-Id: I95eaafe8ecc603fd939a34f91467b98766b715dd
Copy file name to clipboardExpand all lines: storagenode/collector/service.go
+13-10Lines changed: 13 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -25,6 +25,7 @@ type Config struct {
25
25
ExpirationGracePeriod time.Duration`help:"how long should the collector wait before deleting expired pieces. Should not be less than 30 min since nodes are allowed to be 30 mins out of sync with the satellite." default:"1h0m0s"`
26
26
ExpirationBatchSizeint`help:"how many expired pieces to delete in one batch. If <= 0, all expired pieces will be deleted in one batch. (ignored by flat file store)" default:"1000"`
27
27
FlatFileBatchLimitint`help:"how many per hour flat files can be deleted in one batch." default:"5"`
28
+
ReverseOrderbool`help:"delete expired pieces in reverse order (recently expired first)" default:"false"`
28
29
}
29
30
30
31
// Service implements collecting expired pieces on the storage node.
0 commit comments