Skip to content

Commit

Permalink
feat(horaectl): impl horaectl in rs (#1481)
Browse files Browse the repository at this point in the history
## Rationale
Implement horaectl using rust

## Detailed Changes
- Support `cluster list`, `cluster diagnose`, `cluster schedule`

```
$ target/debug/horaectl -h
HoraeCTL is a command line tool for HoraeDB

Usage: horaectl [OPTIONS] [COMMAND]

Commands:
  cluster  Operations on cluster
  help     Print this message or the help of the given subcommand(s)

Options:
  -m, --meta <META_ADDR>        Meta addr [env: HORAECTL_META_ADDR=] [default: 127.0.0.1:8080]
  -c, --cluster <CLUSTER_NAME>  Cluster name [env: HORAECTL_CLUSTER=] [default: defaultCluster]
  -i, --interactive             Enter interactive mode
  -h, --help                    Print help

$ target/debug/horaectl cluster -h
Operations on cluster

Usage: horaectl cluster [OPTIONS] <COMMAND>

Commands:
  list      List cluster
  diagnose  Diagnose cluster
  schedule  Schedule cluster
  help      Print this message or the help of the given subcommand(s)

Options:
  -m, --meta <META_ADDR>        Meta addr [env: HORAECTL_META_ADDR=] [default: 127.0.0.1:8080]
  -c, --cluster <CLUSTER_NAME>  Cluster name [env: HORAECTL_CLUSTER=] [default: defaultCluster]
  -h, --help                    Print help


```

## Test Plan
- Manual tests

---------

Co-authored-by: jiacai2050 <[email protected]>
  • Loading branch information
2 people authored and zealchen committed Apr 9, 2024
1 parent bb15b63 commit 36079a5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ catalog_impls = { path = "src/catalog_impls" }
horaedbproto = { git = "https://github.com/apache/incubator-horaedb-proto.git", rev = "19ece8f771fc0b3e8e734072cc3d8040de6c74cb" }
codec = { path = "src/components/codec" }
chrono = "0.4"
clap = "4.5.1"
clap = { version = "4.5.1", features = ["derive"] }
clru = "0.6.1"
cluster = { path = "src/cluster" }
criterion = "0.5"
Expand Down

0 comments on commit 36079a5

Please sign in to comment.