1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-23 22:10:55 +01:00
phorge-phorge/src/applications/diffusion/controller
epriestley d1fb2f7fb9 Make diffusion.filecontentquery return file PHIDs instead of raw content
Summary:
Fixes T9319. Proxied requests (e.g., in the cluster) for binary files (like images) currently fail because we can not return binary data over Conduit in JSON.

Although Conduit will eventually support binary-safe encodings, a cleaner approach to this is just to return a `filePHID` instead of the raw content. This is generally faster and more flexible, and gives us more opportunities to add caching later.

After making the call, the client pulls the file data separately.

We also no longer need to return a complex data structure because we don't do blame over this call any longer.

Test Plan:
  - Viewed images in Diffusion.
  - Viewed READMEs in Diffusion.
  - Used `bin/differential attach-commit rX Dy` to hit attach pathway.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T9319

Differential Revision: https://secure.phabricator.com/D14970
2016-01-08 09:29:16 -08:00
..
DiffusionBranchTableController.php Modernize tag and branch controllers in Diffusion 2016-01-05 13:58:36 -08:00
DiffusionBrowseController.php Make diffusion.filecontentquery return file PHIDs instead of raw content 2016-01-08 09:29:16 -08:00
DiffusionChangeController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionCommitBranchesController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionCommitController.php Make CommitController more flexible about handling URIs 2016-01-05 13:56:27 -08:00
DiffusionCommitEditController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionCommitTagsController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionController.php Make diffusion.filecontentquery return file PHIDs instead of raw content 2016-01-08 09:29:16 -08:00
DiffusionDiffController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionExternalController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionHistoryController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionInlineCommentController.php Correctly clear draft markers when deleting an inline comment 2015-07-21 11:36:46 -07:00
DiffusionInlineCommentPreviewController.php Touch up PHP/JS interactions for inline comments 2015-03-27 17:08:31 -07:00
DiffusionLastModifiedController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionLintController.php Modernize Diffusion lint controllers 2016-01-05 14:01:20 -08:00
DiffusionMirrorDeleteController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionMirrorEditController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionPathCompleteController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionPathTreeController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionPathValidateController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionPushEventViewController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionPushLogController.php Diffusion - return 404 errors for bad URIs 2015-01-09 13:29:08 -08:00
DiffusionPushLogListController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionRefTableController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionRepositoryController.php Make diffusion.filecontentquery return file PHIDs instead of raw content 2016-01-08 09:29:16 -08:00
DiffusionRepositoryCreateController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryDefaultController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditActionsController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditActivateController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditAutomationController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditBasicController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditBranchesController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditController.php Fix all remaining weird Diffusion request processing 2016-01-05 14:01:53 -08:00
DiffusionRepositoryEditDangerousController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditDeleteController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditEncodingController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditHostingController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditMainController.php Show import progress on repository main page 2016-01-05 14:02:59 -08:00
DiffusionRepositoryEditStagingController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditStorageController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditSubversionController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryEditUpdateController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryListController.php Modernize more Diffusion controllers 2016-01-05 14:00:20 -08:00
DiffusionRepositoryNewController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionRepositorySymbolsController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionRepositoryTestAutomationController.php Slightly modernize all Diffusion edit endpoints 2016-01-05 14:00:36 -08:00
DiffusionServeController.php Fix all remaining weird Diffusion request processing 2016-01-05 14:01:53 -08:00
DiffusionSymbolController.php Modernize most somewhat-weird Diffusion controllers 2016-01-05 14:00:57 -08:00
DiffusionTagListController.php Modernize tag and branch controllers in Diffusion 2016-01-05 13:58:36 -08:00