aboutsummaryrefslogtreecommitdiff
path: root/src/garage/cli/structs.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-09-02 15:34:21 +0200
committerAlex Auvolat <alex@adnab.me>2022-09-02 15:34:21 +0200
commit943d76c583f5740b1d922275a673233a27fe1693 (patch)
tree76a1d9b89c0ee0823d74b670849ed32bd373549f /src/garage/cli/structs.rs
parent532eca7ff94e4710283fb38951a349a83654de59 (diff)
downloadgarage-943d76c583f5740b1d922275a673233a27fe1693.tar.gz
garage-943d76c583f5740b1d922275a673233a27fe1693.zip
Ability to dynamically set resync tranquility
Diffstat (limited to 'src/garage/cli/structs.rs')
-rw-r--r--src/garage/cli/structs.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/garage/cli/structs.rs b/src/garage/cli/structs.rs
index 9274f80f..1fba934f 100644
--- a/src/garage/cli/structs.rs
+++ b/src/garage/cli/structs.rs
@@ -501,6 +501,12 @@ pub enum WorkerCmd {
#[structopt(flatten)]
opt: WorkerListOpt,
},
+ /// Set worker parameter
+ #[structopt(name = "set", version = version::garage())]
+ Set {
+ #[structopt(subcommand)]
+ opt: WorkerSetCmd,
+ },
}
#[derive(Serialize, Deserialize, StructOpt, Debug, Eq, PartialEq, Clone, Copy)]
@@ -512,3 +518,13 @@ pub struct WorkerListOpt {
#[structopt(short = "e", long = "errors")]
pub errors: bool,
}
+
+#[derive(Serialize, Deserialize, StructOpt, Debug, Eq, PartialEq, Clone)]
+pub enum WorkerSetCmd {
+ /// Set tranquility of scrub operations
+ #[structopt(name = "scrub-tranquility", version = version::garage())]
+ ScrubTranquility { tranquility: u32 },
+ /// Set tranquility of resync operations
+ #[structopt(name = "resync-tranquility", version = version::garage())]
+ ResyncTranquility { tranquility: u32 },
+}