Page MenuHomePhabricator

Improve Diffusion behavior for directories with impressive numbers of files
ClosedPublic

Authored by epriestley on Jan 6 2016, 12:15 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Dec 19, 4:42 PM
Unknown Object (File)
Tue, Dec 17, 3:35 PM
Unknown Object (File)
Fri, Dec 13, 5:41 AM
Unknown Object (File)
Wed, Dec 11, 1:09 PM
Unknown Object (File)
Sat, Dec 7, 3:57 AM
Unknown Object (File)
Tue, Dec 3, 4:12 PM
Unknown Object (File)
Tue, Dec 3, 7:21 AM
Unknown Object (File)
Fri, Nov 29, 4:04 AM
Subscribers
None

Details

Summary

Fixes T4366. Two years ago, Facebook put 16,000 files in a directory. Today, the page has nearly loaded.

Paginate large directories.

Test Plan
  • Viewed home and browse views in Git, Mercurial and Subversion.

I put an artificially small page size (5) on home:

Screen Shot 2016-01-06 at 4.07.35 AM.png (1×1 px, 265 KB)

I pushed 16,000 files to a directory and paged through them. Here's the last page, which rendered in about 200ms:

Screen Shot 2016-01-06 at 4.07.05 AM.png (1×1 px, 437 KB)

Our behavior is a bit better than GitHub here, which shows only the first 1,000 files, disables pagination, and can't retrieve history for the files:

Screen Shot 2016-01-06 at 4.07.48 AM.png (1×1 px, 160 KB)

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to Improve Diffusion behavior for directories with impressive numbers of files.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
This revision is now accepted and ready to land.Jan 6 2016, 2:40 PM
This revision was automatically updated to reflect the committed changes.