Skip to content

Main Admin Dashboard Page on SaaS Instance (/admin/users) Is Slow To Load #13334

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

Closed
jimmybrancaccio opened this issue Sep 26, 2022 · 6 comments · Fixed by #13569
Closed

Main Admin Dashboard Page on SaaS Instance (/admin/users) Is Slow To Load #13334

jimmybrancaccio opened this issue Sep 26, 2022 · 6 comments · Fixed by #13569
Assignees
Labels
component: dashboard meta: never-stale This issue can never become stale team: webapp Issue belongs to the WebApp team type: bug Something isn't working

Comments

@jimmybrancaccio
Copy link

Bug description

In the past 7 days or so the main page in the admin dashboard (/admin/users) has been much slower to than previously. Prior to about a week ago the page would load within 2-5 seconds. At this time it takes ~30 seconds for the page to load. While the page is loading searching is not possible.

Steps to reproduce

  1. Clear your web browsers cache.
  2. Visit https://gitpod.io/admin/users in your web browser while keeping an eye on the time.
  3. Observe the extended time it takes for the page to complete loading and for searching to be possible.

https://www.loom.com/share/957360c6c38043839fd9c79ffe079520

Workspace affected

N/A

Expected behavior

I would expect that the page loads in a timely manner. It's possible it's pulling additional user data to display the rows of users on the page which is causing this additional delay. The page will likely need to be profiled to get a better understand of what is causing it to load so slowly.

Example repository

N/A

Anything else?

N/A

@jimmybrancaccio jimmybrancaccio added type: bug Something isn't working component: dashboard meta: never-stale This issue can never become stale team: webapp Issue belongs to the WebApp team labels Sep 26, 2022
@jimmybrancaccio jimmybrancaccio changed the title Main Admin Dashboard Page (/admin/users) Is Slow To Load Main Admin Dashboard Page on SaaS Instance (/admin/users) Is Slow To Load Sep 26, 2022
@jldec jldec moved this to Scheduled in 🍎 WebApp Team Sep 29, 2022
@jldec
Copy link
Contributor

jldec commented Sep 29, 2022

I also noticed that starting a search while the intial open-page query is still in progress will cause the search input to be lost and the search results to be replaced by the default (empty) results of the intial page load.

@jldec
Copy link
Contributor

jldec commented Sep 29, 2022

scheduled as this makes our admin dashboard painful to use.

@easyCZ
Copy link
Member

easyCZ commented Oct 3, 2022

When the page loads, it makes a request for

{"jsonrpc":"2.0","id":10,"method":"adminGetUsers","params":{"searchTerm":"","limit":50,"orderBy":"creationDate","offset":0,"orderDir":"desc"}}

Which takes around ~21 seconds.

Subsequent query for a term "easy"

{"jsonrpc":"2.0","id":11,"method":"adminGetUsers","params":{"searchTerm":"easy","limit":50,"orderBy":"creationDate","offset":0,"orderDir":"desc"}}

Takes ~7 seconds.

Removing the search term and searching again makes

{"jsonrpc":"2.0","id":12,"method":"adminGetUsers","params":{"searchTerm":"","limit":50,"orderBy":"creationDate","offset":0,"orderDir":"desc"}}

And takes ~21 seconds again.

This is caused by the underlying DB query being slow.

@easyCZ
Copy link
Member

easyCZ commented Oct 3, 2022

Image
^ 90th percentile of the API call

From metrics, we can see that indeed this used to perform better and started happening around Sept 22 - metrics

@easyCZ
Copy link
Member

easyCZ commented Oct 3, 2022

This looks to be introduced with this commit - 29c88a7

@easyCZ
Copy link
Member

easyCZ commented Oct 3, 2022

Related to #13225

@svenefftinge svenefftinge self-assigned this Oct 4, 2022
@svenefftinge svenefftinge moved this from Scheduled to In Progress in 🍎 WebApp Team Oct 4, 2022
Repository owner moved this from In Progress to In Validation in 🍎 WebApp Team Oct 4, 2022
@jldec jldec moved this from In Validation to Done in 🍎 WebApp Team Oct 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: dashboard meta: never-stale This issue can never become stale team: webapp Issue belongs to the WebApp team type: bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants