Project

General

Profile

Actions

Bug #82565

closed

Improve performance for version nr of file

Added by Faton Haliti about 7 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
Start date:
2017-09-27
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
8
PHP Version:
7.1
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

When processing javascript and css, typo3 currently incorrectly tries to process resources loaded from external as local resources, cause some very expensive file_exists calls.
In the function createVersionNumberedFilename($file) which will make the filename automatically change when a file is changed and re-cached by the browser will check for existence of the file and that might be expensive when we do not have the file and mode is not either 'embed' or 'querystring'
Setting
$GLOBALS['TYPO3_CONF_VARS']['FE']['versionNumberInFilename'] = ''

Will still cause a check to the local filesystime, because

GeneralUtility::createVersionNumberedFilename
..
if (!file_exists($path) || $doNothing) {

One solution is to change this to

if ($doNothing || !file_exists($path)) {

Actions

Also available in: Atom PDF