Bug #82672
closedFileadmin garbage collection is failing
100%
Description
The scheduler job "Fileadmin garbage collection" is failing with the error message:
Execution failed: 1314516809, File /foo/bar/fileadmin/subfolder/_recycler_ does not exist.
I'm using typo3 v7.6.23
A look at the source code reveals that this cannot work and never has. That's strange because it was reviewed and tested, allegedly:
https://forge.typo3.org/issues/78473
commit: a43deabd6728526b1237b4d76a369baffd211c27
It's not working because the method getFileObjectFromCombinedIdentifier() receives wrong input:
should be something like: 'fileadmin/subfolder/_recycler_/garbage.txt'
but is: '/foo/bar/fileadmin/subfolder/_recycler_'
Maybe the version from master does run in v7? It seems to be much cleaner and better.
Regards
Michael
Updated by Alexander Grein about 7 years ago
I can confirm this bug.
There is a problem inside the method cleanupRecycledFiles of the typo3/sysext/scheduler/Classes/Task/RecyclerGarbageCollectionTask.php class.
It is this call in line 93:
$fileObject = ResourceFactory::getInstance()->getFileObjectFromCombinedIdentifier($filePath);
The passed parameter is an absolute path without the filename, but should be a relative path to a file from the web root view to work as an identifier for the resource factory.
If you change this line to
$fileObject = ResourceFactory::getInstance()->getFileObjectFromCombinedIdentifier(substr($fileName, strlen(PATH_site)));the error message of this issue will disappear.
Updated by Sebastian Hofer almost 7 years ago
- Sprint Focus set to On Location Sprint
Updated by Gerrit Code Review almost 7 years ago
- Status changed from New to Under Review
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/54839
Updated by Gerrit Code Review almost 7 years ago
Patch set 2 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/54839
Updated by Gerrit Code Review almost 7 years ago
Patch set 3 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/54839
Updated by Sebastian Hofer almost 7 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset d1105723f0af1314507f0f26db3ea817ec4badf8.