Bug #56746
File list always fetches all files in folder
Status: | Resolved | Start date: | 2014-03-11 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | - | % Done: | 100% |
|
Category: | File Abstraction Layer (FAL) | Spent time: | - | |
Target version: | - | |||
TYPO3 Version: | 6.2 | Is Regression: | No | |
PHP Version: | Sprint Focus: | |||
Complexity: |
Description
When using the filelist module to list files in a folder of a FAL storage, FileList.php
always requests all files at once, even though only 40 are displayed at the same time.
This is problematic if there is a huge number of files in that folder that need to be fetched remotely via an API.
It would be better if at first a call would be made to fetch the number of files in that folder (to make pagination calculation work), and then only request needed files by setting $start
and $numberOfItems
arguments in getFilesInFolder()
correctly.
Happens with TYPO3 6.2beta6.
Related issues
Associated revisions
[!!!][FEATURE] Add count methods and sort functionality to FAL drivers
Instead of fetching all files and folders to count them,
two new FAL driver methods are introduced:
getFoldersInFolderCount() and getFilesInFolderCount()
Filelist makes use of the new counting methods, reducing the
processing time folders which contain a large number of files.
Sorting files is also moved into the driver.
Change-Id: I79c18fb697c976649adb40637f22df5341396d1e
Resolves: #56746
Releases: master
Reviewed-on: http://review.typo3.org/28560
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Frans Saris <franssaris@gmail.com>
Tested-by: Frans Saris <franssaris@gmail.com>
[FOLLOW-UP][TASK] Rename FAL driver count methods
This changes the names of the newly added FAL driver count methods
to be more intuitive.
Since the new API wasn't published yet, this is not a breaking change.
Resolves: #66327
Related: #56746
Releases: master
Change-Id: Ia5732266bada674b64a9d9768dfff98871eb6b13
Reviewed-on: http://review.typo3.org/38533
Reviewed-by: Steffen Müller <typo3@t3node.com>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Frans Saris <franssaris@gmail.com>
Tested-by: Steffen Müller <typo3@t3node.com>
Reviewed-by: Nicole Cordes <typo3@cordes.co>
Tested-by: Nicole Cordes <typo3@cordes.co>
History
#1 Updated by Gerrit Code Review over 1 year ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/28560
#2 Updated by Gerrit Code Review over 1 year ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/28560
#3 Updated by Gerrit Code Review 7 months ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/28560
#4 Updated by Gerrit Code Review 5 months ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/28560
#5 Updated by Gerrit Code Review 5 months ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/28560
#6 Updated by Gerrit Code Review 5 months ago
Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/28560
#7 Updated by Gerrit Code Review 4 months ago
Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/28560
#8 Updated by Christian Weiske 4 months ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset d32e20d192bcc04b945f778cfa8b66f9aaf85f42.