Open amitgalitz opened 1 month ago
I would recommend providing a drop down that can lazy load. Specifically, it will load the next batch of data once the user scrolls to the end of first batch. @virajsanghvi, does selectable or combobox OUI components support any sort of lazy loading?
Additionally @virajsanghvi I see that we have an example of a combo box utilizing react-window but I am not sure if the demo JS is correct: https://oui.opensearch.org/1.17/#/forms/combo-box#virtualized
Would this solution be good to use here for the paginated _list/indices
API or should we have another lazy loading solution when we reach the bottom of the list.
I think the combo box virtualizes by default, which is why the demo js doesn't have anything called out. Virtualization assumes you have all the options though.
It looks like the component supports async search, https://oui.opensearch.org/1.17/#/forms/combo-box#async, but that doesn't handle loading.
I don't see a component that supports this out of the box, but maybe @AMoo-Miki may know of a component or example somewhere.
Is your feature request related to a problem? We should use the new
_list/indices
API instead of_cat/indices
to better handle fetching of indices as currentcat
API consumes too many resources.Issue for new
_list/indices
API: https://github.com/opensearch-project/OpenSearch/pull/15986 issue for context on limitation of CAT api: https://github.com/opensearch-project/OpenSearch/issues/15954What solution would you like? Changing to a paginated API means we need to potentially change our UI as well as we will either need a mechanism to make API calls to the next set of results or relay more so on our search functionality and only display a limited (1k) number of results on the frontend at a time.
Options:
Option 1: Make the changes to list/indices and we set default to 1k without implementing pagination.
Pros:
Cons:
Option 2: Change index selection drop down to include pagination or other UI based mechanism to fetch the next page of results
Pros:
Cons: