Skip to content
This repository was archived by the owner on Apr 11, 2019. It is now read-only.

Have a two tier data fetching approach to improve the expired and no cache scenarios #164

Open
armenzg opened this issue Mar 29, 2018 · 1 comment

Comments

@armenzg
Copy link
Contributor

armenzg commented Mar 29, 2018

We currently query json-pushes to give us all the pushes in the last day which we then turn into changesets.
After we do that, for every changeset we asynchronously query the backend (producing 100-400 fetches) and wait for all of them to finish first.
This is specially bad since the browser allows for a maximum of 6 fetches in parallel.
Nothing in the UI is rendered until all fetches have been completed.

Now, there's a two tier approach I want to implement.
We first query for every push the tipmost changeset.
For the pushes that have coverage data we then proceed to fetch the data of all of its changesets. When that batch of changesets is completed we proceed to set the state and the UI will show all changesets for that specific push.

This approach would likely cause the main view to show changesets on batches. I don't know how much of a problem it would be from a UX perspective (e.g. about to click on a changeset and it suddenly a new changesets shows up in its place). We will have to see.

@marco-c
Copy link
Collaborator

marco-c commented Apr 3, 2018

Another option might be to add an API in the backend to retrieve coverage summary for multiple changesets at the same time.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants