Issue Bug Closed

#23545Memcache::delete() without timeout param causes loss of memcache server in pool

Ivar 09/16/10, 09:51 updated 10/02/18, 12:22

Description

I found this problem in typo3 v. 4.3.x in combination with the PECL Memcache extension v.1.4.4
(this bug doesn’t seem to occur in all Memcache versions)

The problem is that Memcache::getServerStatus() return 0 after a call to Memcache::delete() without the 2nd timeout param. This means the Memcache server is not available anymore so all the following get()/set() calls will return false.
In TYPO3 v. 4.3.5 this will result in a ‘t3lib_cache_Exception’ wich causes typo3 to crash. So the bug itself is not in the TYPO3 core but it’s better to use the 2nd timout param (default value of 0) in Memcache::delete() calls to prevent people from getting these exceptions.
People who use an older TYPO3 version don’t get these exception, but since half of the Memcache::set() calls will fail it’s not very effective..

Memcache::delete() calls occur in file:
t3lib/cache/backend/class.t3lib_cache_backend_memcachedbackend.php

in the methods:
remove() & removeIdentifierFromAllTags(),

(issue imported from #M15721)

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.