[Web] Implement Instance Inventory UI#62027
Conversation
|
@rudream - this PR will require admin approval to merge due to its size. Consider breaking it up into a series smaller changes. |
1 similar comment
|
@rudream - this PR will require admin approval to merge due to its size. Consider breaking it up into a series smaller changes. |
884f7a8 to
b9f9ff1
Compare
| Bots ResourceAccess `json:"bots"` | ||
| // BotInstances defines access to manage bot instances | ||
| BotInstances ResourceAccess `json:"botInstances"` | ||
| // Instances defines access to manage instances |
There was a problem hiding this comment.
| // Instances defines access to manage instances | |
| // Instances defines access to view instance inventory. |
There was a problem hiding this comment.
Technically the acl here contains all the permissions for KindInstance, including create, edit, and delete (which we may use in the future for another feature). I think it'd be more correct to keep the language here more generic
b9f9ff1 to
96f43c7
Compare
nicholasmarais1158
left a comment
There was a problem hiding this comment.
Overall, looks good. A few non-major comments.
I think this feature is sufficiently complicated to warrant adding a few tests. Provide a safety net for future you and other maintainers. Don't necessarily cover everything, just the parts that are important, complex, or a pain to regression test manually.
f93e1cf to
1b340ca
Compare
5dda58e to
cd07c74
Compare
ravicious
left a comment
There was a problem hiding this comment.
I submitted a bunch of nitpicks but looks good overall. I agree with Michael's comment wrt the UI for version filters, but I suppose this can be addressed in a further PR.
| const { | ||
| isSuccess, | ||
| data, | ||
| isLoading, |
There was a problem hiding this comment.
Good feedback, it could also be isLoading || isRefetching which I think describes the purpose in a slightly more clear (and universal) manner. But it doesn't really matter that much.
https://tanstack.com/query/v5/docs/framework/react/reference/useInfiniteQuery
avatus
left a comment
There was a problem hiding this comment.
Once other nits have been addressed, LGTM
0d83eaa to
06e4cee
Compare
fbdd28c to
b75e401
Compare
06e4cee to
de933f4
Compare
b75e401 to
b28bbf0
Compare
de933f4 to
a1a584e
Compare
974a984 to
9e8474f
Compare
9e8474f to
3654b3f
Compare
Purpose
This PR is part of #60528
This PR adds the new "Instance Inventory" page to the Web UI, which allows users to list instances and bot instances with support for search, sorting, and filtering by various criteria.
ecounterpart: https://github.com/gravitational/teleport.e/pull/7732Figma mockups
Required merges
Implementation
A new type of filter component was created for filtering by versions, this contains some preset version filters based on common use-cases as well as the option for a custom filter where the user can enter their own. This filter control works under the hood by appending a predicate query for that given filter selection to the request, it will combine with any other search/predicate query entered by the user, however it will not populate the advanced search bar.
For bot instances, the services column contains a deeplink button which takes the user to the Bot Instances dashboard with that bot instance in view.
The language for the upgraders differs slightly from those shown in the Figma mockup, as the ones used there are not very accurate and the autoupdate team suggested to use different labels.
Demo
Example default view
Multiple filters and search active
Filter controls