1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-02-26 13:39:08 +01:00
phorge-phorge/src/applications/diffusion/conduit
epriestley e96cd29eff Reduce badness in viewing large files in the Diffusion web UI
Summary:
Fixes T8597. Second issue there is that if you look at a huge file in Diffusion (like `/path/to/300MB.pdf`) we pull the whole thing over Conduit upfront, then try to shove it into file storage.

Instead, pull no more than the chunk limit (normally 4MB) and don't spend more than 10s pulling data.

If we get 4MB of data and/or time out, just fail with a message in the vein of "this is a really big file".

Eventually, we could improve this:

  - We can determine the //size// of very large files correctly in at least some VCSes, this just takes a little more work. This would let us show the true filesize, at least.
  - We could eventually stream the data out of the VCS, but we can't stream data over Conduit right now and this is a lot of work.

This is just "stop crashing".

Test Plan: Changed limits to 0.01 seconds and 8 bytes and saw reasonable errors. Changed them back and got normal beahvior.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T8597

Differential Revision: https://secure.phabricator.com/D13348
2015-06-18 13:06:01 -07:00
..
DiffusionBranchQueryConduitAPIMethod.php Ignore closed branch heads by default in Mercurial 2015-04-27 03:51:21 -07:00
DiffusionBrowseQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionCommitParentsQueryConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00
DiffusionConduitAPIMethod.php Fix some missing renames of Application classes 2014-07-24 18:03:59 -07:00
DiffusionCreateCommentConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionDiffQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionExistsQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionFileContentQueryConduitAPIMethod.php Reduce badness in viewing large files in the Diffusion web UI 2015-06-18 13:06:01 -07:00
DiffusionFindSymbolsConduitAPIMethod.php Add repository parameter to diffusion.findsymbols method 2015-05-05 08:27:08 +10:00
DiffusionGetCommitsConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionGetLintMessagesConduitAPIMethod.php Change "lint save" to not use Arcanist Projects 2015-05-19 00:07:47 +10:00
DiffusionGetRecentCommitsByPathConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionHistoryQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionLastModifiedQueryConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00
DiffusionLookSoonConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00
DiffusionMergedCommitsQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionQueryCommitsConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00
DiffusionQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionQueryPathsConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00
DiffusionRawDiffQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionRefsQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionResolveRefsConduitAPIMethod.php Only resolve branch names to branches 2015-04-27 03:51:53 -07:00
DiffusionSearchQueryConduitAPIMethod.php phtize all the things 2015-05-22 21:16:39 +10:00
DiffusionTagsQueryConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00
DiffusionUpdateCoverageConduitAPIMethod.php Give Conduit params/return/errors protected visibility 2015-04-13 11:58:35 -07:00