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

Asynchronous requests to retrieve stats in clusters list #435

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

rezib
Copy link
Contributor

@rezib rezib commented Jan 10, 2025

Some tasks are still pending:

  • Add loading placeholders
  • Add unit tests to cover ClustersView and ClusterListItem component
  • Update gateway assets with new /clusters response

fix #428

@rezib rezib added the refactor Code refactoring to reduce maintenance cost and technical debt label Jan 10, 2025
@rezib rezib added this to the v4.1.0 milestone Jan 10, 2025
@rezib rezib self-assigned this Jan 10, 2025
@rezib rezib force-pushed the pr/fix-428 branch 3 times, most recently from 1cd70d7 to 8f01abe Compare January 13, 2025 20:41
@rezib rezib marked this pull request as ready for review January 13, 2025 20:43
rezib added 6 commits January 17, 2025 22:42
Do not return clusters global stats in /clusters endpoint anymore. These
stats can take lot of time to get from clusters, depending on the number
of jobs and cache status. The user experience is better if the frontend
can quickly retrieve the clusters list with their permissions and then
clusters stats asynchronously.
Instead of expecting the clusters stats in response along the clusters
list, send asynchronous requests to retrieve the stats on all clusters
after the list of clusters is rendered to users.

fix #428
Introduce ClusterListItem component in order to move some code out of
ClustersView and simplify logic of parallel and asynchronous cluster
stats retrieval.
Do not report ongoing issue when users do not have permission on
view-stats action on a cluster in clusters list page.
Display loading spinner when loading cluster stats in clusters list.
Add unit tests to cover ClustersView and ClustersListItem component.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactor Code refactoring to reduce maintenance cost and technical debt
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Split clusters and jobs/nodes retrieval to minimize rendering time of clusters list
1 participant