Page MenuHomePhabricator

Don't let blame run for longer than 15 seconds
ClosedPublic

Authored by epriestley on Jan 7 2016, 2:10 AM.
Tags
None
Referenced Files
F14017980: D14964.id36157.diff
Tue, Nov 5, 2:16 AM
F14015420: D14964.diff
Sun, Nov 3, 6:36 PM
F13997409: D14964.id36157.diff
Thu, Oct 24, 4:20 AM
F13984075: D14964.diff
Sun, Oct 20, 10:51 AM
F13956245: D14964.id.diff
Oct 14 2024, 4:54 AM
Unknown Object (File)
Oct 9 2024, 7:47 PM
Unknown Object (File)
Sep 4 2024, 10:55 PM
Unknown Object (File)
Sep 4 2024, 4:08 PM

Details

Reviewers
chad
Maniphest Tasks
T2450: Build a blame cache
Commits
Restricted Diffusion Commit
rP438100691d42: Don't let blame run for longer than 15 seconds
Summary

Fixes T2450. If we spend more than 15 seconds in blame, just cut it off.

Test Plan
  • Changed timeout to 0.01 seconds.
  • Did blame on a non-highlighted file, got no blame, saw warning.
  • Did blame on a highlighted file, got no blame.
    • Note: you don't get a warning here because of Ajax stuff. It'd be kind of tricky to add and doesn't seem like a big deal so I'm planning to leave it as-is for now.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to Don't let blame run for longer than 15 seconds.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
  • Also simply prevent it from running on large files at all.

@20after4 / @chasemp:

  • This and prior commits in the sequence (see T2450) should generally improve the behavior you ran into.
  • We will no longer try to generate blame data for very large files (>256KB of text).
  • We no longer try to highlight very large files.
  • We will no longer spend more than 15 seconds trying to generate blame data for files we do try to pull it for.
  • Generation of blame data is now faster and cached better; cache hits are on the order of tens of milliseconds instead of multiple seconds.
  • Rendering of blame data is now much better in extreme cases (although, broadly speaking, we now decline to try to pull the data in extreme cases).
chad edited edge metadata.
This revision is now accepted and ready to land.Jan 7 2016, 2:42 AM
This revision was automatically updated to reflect the committed changes.