Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[omdb] Add a couple simple Sled Agent queries #4126

Merged
merged 4 commits into from
Sep 21, 2023
Merged

[omdb] Add a couple simple Sled Agent queries #4126

merged 4 commits into from
Sep 21, 2023

Conversation

smklein
Copy link
Collaborator

@smklein smklein commented Sep 20, 2023

Related to #1881

Copy link
Collaborator

@davepacheco davepacheco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! A few small suggestions above.

Thanks also for alphabetizing the commands and fixing the copy/pasted comments.

OmdbCommands::Db(db) => db.run_cmd(&log).await,
OmdbCommands::Nexus(nexus) => nexus.run_cmd(&log).await,
OmdbCommands::Sled(sled) => sled.run_cmd(&log).await,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I only wonder if this should be sled-agent (there are other things on the sled). If you do I'd carry that through everywhere -- e.g., the URL env var name too.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!


#[derive(Debug, Subcommand)]
enum ZoneCommands {
/// Print list of all zones
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// Print list of all zones
/// Print list of control plane zones that the sled agent is configured to run

(just trying to be precise about what it's printing so that someone doesn't interpret this as the same as zoneadm list)

edit: I just checked and it looks like this is only the running zones that are the subset of zones the sled agent is configured to run, I think.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated, specifying that these are "running control plane zones". I think we could also expose the set of zones the sled was told to run, but this will require modifying the sled agent API.


#[derive(Debug, Subcommand)]
enum ZpoolCommands {
/// Print list of all zpools
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// Print list of all zpools
/// Print list of all zpools managed by the sled agent

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated

@davepacheco
Copy link
Collaborator

I forgot to mention: you will need to merge with #4101 and regenerate the output with EXPECTORATE.

@smklein smklein merged commit 88785de into main Sep 21, 2023
21 checks passed
@smklein smklein deleted the omdb-sleds branch September 21, 2023 05:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants