From 9b7afd4aac42c3629d1cc17f4e55d5551f3d3c3a Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Wed, 24 Jun 2020 11:59:52 +0100 Subject: [PATCH] bin: ch-remote: Implement "counters" command This is used to obtain the counters from the VM. The raw JSON data is presented to the user. Signed-off-by: Rob Bradford --- src/bin/ch-remote.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/bin/ch-remote.rs b/src/bin/ch-remote.rs index a51bbb6d1..1cd79a6f4 100644 --- a/src/bin/ch-remote.rs +++ b/src/bin/ch-remote.rs @@ -337,6 +337,7 @@ fn do_command(matches: &ArgMatches) -> Result<(), Error> { match matches.subcommand_name() { Some("info") => simple_api_command(&mut socket, "GET", "info", None), + Some("counters") => simple_api_command(&mut socket, "GET", "counters", None), Some("resize") => resize_api_command( &mut socket, matches @@ -498,6 +499,7 @@ fn main() { .arg(Arg::with_name("id").index(1).help("")), ) .subcommand(SubCommand::with_name("info").about("Info on the VM")) + .subcommand(SubCommand::with_name("counters").about("Counters from the VM")) .subcommand(SubCommand::with_name("pause").about("Pause the VM")) .subcommand(SubCommand::with_name("reboot").about("Reboot the VM")) .subcommand(