stable
Clone or download
Read-only
This is part of story #8762: add attachment in modal - The existing limit (5) on total temporary files is removed - Instead, a new limit is added: a given user has a total file size quota that is the sum of all her temporary files' sizes. E.g. with a limit of 64 MB, if userA already has uploaded File1 of 33MB, userA can upload File2 of 16 MB but cannot upload File3 of 32 MB. - Related REST routes now send two additional custom headers: X-QUOTA and X-DISK-USAGE. X-QUOTA is defined at platform level (sys_max_size_upload in local.inc) and X-DISK-USAGE is the total size of temporary files of the current user. Change-Id: I331cf1c5b3b83b8af539bab4bfe9356074ccad8b
Modified Files
Name | ||||
---|---|---|---|---|
M | plugins/tests/include/TestsPluginRunner.class.php | +10 | −6 | Go to diff View file |
M | plugins/tracker/include/REST/v1/ArtifactFilesResource.class.php | +5 | −3 | Go to diff View file |
M | plugins/tracker/include/REST/v1/ArtifactTemporaryFilesResource.class.php | +76 | −58 | Go to diff View file |
R | plugins/tracker/include/Tracker/Artifact/Attachment/MaxFilesException.php | Go to diff View file | ||
M | plugins/tracker/include/Tracker/Artifact/Attachment/TemporaryFileManager.class.php | +51 | −31 | Go to diff View file |
D | plugins/tracker/include/Tracker/Artifact/Attachment/TemporaryFileTooBigException.php | +0 | −22 | Go to diff View file |
M | plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_File.class.php | +6 | −3 | Go to diff View file |
M | plugins/tracker/include/autoload.php | +3 | −4 | Go to diff View file |
A | plugins/tracker/tests/Artifact/Attachment/TemporaryFileManagerTest.php | +180 | −0 | Go to diff View file |
M | src/common/REST/Header.class.php | +10 | −0 | Go to diff View file |
M | tests/rest/ArtifactFilesTest.php | +12 | −1 | Go to diff View file |