Description
This is a follow-up for #15813 (comment).
When a PHP process crashes or terminates (maybe the OOM killer kicks in or other bad things ™️ happen) while the HttpCache
holds a .lck
file, that lock file may not get unlink()
ed.
The result is that other requests trying to access this cache entry will see a few seconds delay while waiting for the lock; they will eventually continue but send 503 status codes along with the response. The sudden buildup of PHP processes caused by the additional delay may cause further problems (sudden load increase).
One solution might be to use the LockHandler
from the Filesystem component. It applies flock()
-based locking, so the lock will automatically be released when the process holding it terminates.
As the LockHandler
was added in 2.6, this is not a bugfix we could provide for 2.3.
(Yes, I've seen this happen quite a few time in practice.)