Page MenuHomePhabricator

Prioritize loading of files clicked in ToC
Needs ReviewPublic

Authored by vrana on Nov 23 2013, 7:44 PM.
Tags
None
Referenced Files
F14355250: D7641.diff
Thu, Dec 19, 5:42 PM
Unknown Object (File)
Tue, Dec 17, 11:11 AM
Unknown Object (File)
Sat, Dec 7, 5:50 PM
Unknown Object (File)
Wed, Dec 4, 5:24 PM
Unknown Object (File)
Wed, Nov 20, 4:48 AM
Unknown Object (File)
Wed, Nov 20, 1:22 AM
Unknown Object (File)
Nov 19 2024, 5:39 AM
Unknown Object (File)
Nov 15 2024, 9:18 AM
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

Also fix double loading of files clicked in ToC before they were loaded.

In future, we can detect which file is looked at by user and load that with priority too.

Array is not the best data structure for priority queue but it's not a big deal as we'd usually reorder it just once.

Test Plan

Added sleep(5) to DifferentialChangesetViewController, decreased load_limit to 1, clicked on third file in ToC, saw it loaded before the second.

Diff Detail

Branch
master
Lint
Lint Passed
Unit
No Test Coverage

Event Timeline

vrana updated this revision to Unknown Object (????).Nov 23 2013, 11:32 PM

Generalize

epriestley removed a reviewer: epriestley.

This is obsoleted by D8979, which adds a flexible global priority queue for AJAX requests and covers this use case specifically.