Project

General

Profile

Actions

Bug #73032

closed

File search causes memory leaks with too many files

Added by Alexander Schnitzler about 8 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Should have
Category:
File Abstraction Layer (FAL)
Target version:
Start date:
2016-01-30
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

During the file search in the file module the search result is only limited to possibly matching folders. That itself decreases the search over all files in a storage but it still does not prevent memory leaks, where the result of possible folders contain a decent amount of files.

Example:
fileadmin has a total of 10.000 files.
fileadmin has a subfolder called foo
fileadmin/foo holds a subset of 1000 files.
fileadmin/foo holds the file bar

A search for bar asks the database for all folders that contain files with the matching identifier bar. As a result, only the folder fileadmin/foo is returned which already excludes 9000 possible files.

Still, the resultset contains 1000 files, whoose name is compared php-wise with the search string. During that foreach loop each a file object with a decent memory footprint will be created. This easily exceeds the avialable memory limit.

Actions #1

Updated by Gerrit Code Review about 8 years 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/46395

Actions #2

Updated by Gerrit Code Review about 8 years ago

Patch set 1 for branch TYPO3_7-6 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/47078

Actions #3

Updated by Anonymous about 8 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #4

Updated by Riccardo De Contardi over 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF