-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
tctl resource selection ux #30081
Merged
Merged
tctl resource selection ux #30081
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* kube_cluster * kube_server * db * db_server
smallinsky
approved these changes
Aug 8, 2023
capnspacehook
approved these changes
Aug 8, 2023
You're not authorized to push to this branch. Visit "About protected branches" for more information.
@GavinFrazar See the table below for backport results.
|
GavinFrazar
added a commit
that referenced
this pull request
Sep 16, 2023
backports #30081 to branch/v13. * prefix matching for tctl get discovery resources: * kube_cluster * kube_server * db * db_server * skip 500ms wait for 0 databases in tests
GavinFrazar
added a commit
that referenced
this pull request
Sep 18, 2023
backports #30081 to branch/v13. * prefix matching for tctl get discovery resources: * kube_cluster * kube_server * db * db_server * skip 500ms wait for 0 databases in tests
GavinFrazar
added a commit
that referenced
this pull request
Sep 18, 2023
backports #30081 to branch/v13. * prefix matching for tctl get discovery resources: * kube_cluster * kube_server * db * db_server * skip 500ms wait for 0 databases in tests
GavinFrazar
added a commit
that referenced
this pull request
Sep 18, 2023
* [v13] show discovered name in non-verbose request search backports #30196 to branch/v13. * factor out discovered name func from tsh and tctl into tool/common * [v13] tctl resource selection ux (#32086) backports #30081 to branch/v13. * prefix matching for tctl get discovery resources: * kube_cluster * kube_server * db * db_server * skip 500ms wait for 0 databases in tests
github-merge-queue bot
pushed a commit
that referenced
this pull request
Sep 19, 2023
* [v13] show discovered name in tsh kube ls backports #30149 to branch/v13. * update tsh kube ls tests * fix SiteName godoc typo * [v13] `tsh request search` displays discovered resource name (#32085) * [v13] show discovered name in non-verbose request search backports #30196 to branch/v13. * factor out discovered name func from tsh and tctl into tool/common * [v13] tctl resource selection ux (#32086) backports #30081 to branch/v13. * prefix matching for tctl get discovery resources: * kube_cluster * kube_server * db * db_server * skip 500ms wait for 0 databases in tests
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR allows users to select resources in
tctl [get | edit | rm]
for resources of kinddb
,db_server
,kube_cluster
, andkube_server
using a prefix of the resource name.Part of the implementation for RFD 129.
Majority of changes were in adding test coverage for these commands.
UX
If the name given by the user matches any resource's name exactly, other resources that match the prefix are ignored, to avoid annoying UX, for example:
Additionally, since
tctl rm
is a destructive action, I decided to make it an error if the given name matches multiple resources at once, which is consistent with how we already allowtctl get <kind>
and disallowtctl rm <kind>
:For
tctl get
andtctl edit
, a prefix is allowed to match more than one resource:Related issue: