Skip to content

Commit

Permalink
Add SnapshotsVacuumTask task for vacuum command #577
Browse files Browse the repository at this point in the history
  • Loading branch information
anatol-sialitski authored and rymsha committed Dec 13, 2024
1 parent 1358d48 commit e210d49
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/xp.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -827,7 +827,7 @@ Options:
|Description

|`--blob, -b`
|Triggers `BinaryBlobVacuumTask` and `NodeBlobVacuumTask` in addition to `SegmentVacuumTask` and `VersionTableVacuumTask`
|Triggers `BinaryBlobVacuumTask` and `NodeBlobVacuumTask` in addition to `SegmentVacuumTask`, `VersionTableVacuumTask` and `SnapshotsVacuumTask`

|`-t, --threshold`
|Age of data to be removed in ISO-8601 duration format PnDTnHnMn.nS with days considered to be exactly 24 hours
Expand Down
4 changes: 3 additions & 1 deletion internal/app/commands/vacuum/vacuum.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,10 @@ func createVacuumRequest(c *cli.Context) *http.Request {
params := map[string]interface{}{}
if c.Bool("blob") {
params["tasks"] = []string{
"NodeBlobVacuumTask", "BinaryBlobVacuumTask", "SegmentVacuumTask", "VersionTableVacuumTask",
"NodeBlobVacuumTask", "BinaryBlobVacuumTask", "SegmentVacuumTask", "VersionTableVacuumTask", "SnapshotsVacuumTask",
}
} else {
params["tasks"] = []string{"SegmentVacuumTask", "VersionTableVacuumTask", "SnapshotsVacuumTask"}
}
if c.IsSet("threshold") {
params["ageThreshold"] = c.String("threshold")
Expand Down

0 comments on commit e210d49

Please sign in to comment.