Actions
Bug #101730
closedMissing last_indexed entry on initial file upload
Status:
Closed
Priority:
Should have
Assignee:
-
Category:
File Abstraction Layer (FAL)
Target version:
Start date:
2023-08-22
Due date:
% Done:
100%
Estimated time:
TYPO3 Version:
11
PHP Version:
8.1
Tags:
fal, indexer, metadata
Complexity:
easy
Is Regression:
Sprint Focus:
Description
The createIndexEntry function in TYPO3\CMS\Core\Resource\Index\Indexer does not update the last_indexed column in the sys_file table after processing an uploaded file. This leads to a loss of edited metadata while the index is updated (e.g. executed by the scheduler task /typo3/sysext/scheduler/Classes/Task/FileStorageIndexingTask.php), since the file is considered as unindexed. The result is: The original metadata is extracted from the file again and used to overwrite the edited metadata.
Adding
$this->getFileIndexRepository()->updateIndexingTime($fileObject->getUid());
after Line 90 in the Indexer.php
$fileObject->getMetaData()->add($metaData)->save();
fixes the issue.
Actions