[TASK] Optimize clearing file backend caches 12/19512/2
authorOliver Hader <oliver@typo3.org>
Wed, 28 Nov 2012 10:49:36 +0000 (11:49 +0100)
committerOliver Hader <oliver.hader@typo3.org>
Tue, 2 Apr 2013 09:32:20 +0000 (11:32 +0200)
commit1da73545ffb7870e3f4c3ab6372367c41fd3eab4
tree93892ec0d6bb3b35cf879b8a4fff86a2886940c8
parentc05fe218746eb174ff637b28e54580d17595f368
[TASK] Optimize clearing file backend caches

During concurrent requests it might happen that one request
flushes a cache that is stored in the filesystem and another
different request tries to recreate the data. This will lead
to race conditions if the cached contents are large.

The idea is to move the current cache to a temporary location
and then remove it.

Change-Id: I242fdbc6ab28008363747a8076d021ebce127e17
Resolves: #43382
Releases: 6.0, 6.1
Reviewed-on: https://review.typo3.org/19512
Reviewed-by: Oliver Hader
Tested-by: Oliver Hader
typo3/sysext/core/Classes/Cache/Backend/FileBackend.php
typo3/sysext/core/Classes/Cache/Backend/SimpleFileBackend.php
typo3/sysext/core/Classes/Utility/GeneralUtility.php