Skip to content
Snippets Groups Projects

Performance: Reduce waterfall fetching by making repo and resolvedRev optional

Merged Administrator requested to merge vb/improve-waterfall-fetching into main

Created by: valerybugakov

Status

WIP: going through Typescript errors and testing affected pages. WIP: testing affected pages and simplifying Typescript types. Ready for functional review and early feedback.

The main-dry-run CI build is here. :white_check_mark:

Context

Main ideas behind this PR:

  1. Make repo and resolvedRev optional for components like the BlobPage. Render these components earlier to start their network requests like the fetchBlob query earlier and, as a result, render the blob view faster.
  2. Merge fetchRepository and resolveRevision GraphQL queries into one query to improve the network waterfall. Let me know if you know why it's a bad idea! We discussed this question with @mrnugget and didn't find any obvious blockers. See the relevant Slack thread.

Based on @umpox's draft PR https://github.com/sourcegraph/sourcegraph/pull/40244

Test plan

  1. Open web application locally.
  2. Navigate between all possible repo pages (e.g., blob view, commits, tags, settings, etc.)
  3. Test history API navigation for these pages (clicking links) along with full page refreshes.
  4. Try adding a new repo that takes time to clone, and try opening the repo page.

App preview:

Check out the client app preview documentation to learn more.

Merge request reports

Merged by avatar (Jun 5, 2025 2:50pm UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading