It works as a proof of concept with these modifications
-----------------------------------------------------------------------------------------
Zend\Cache\Storage\Adapter\AbstractAdapter
-----------------------------------------------------------------------------------------
abstract protected function internalSetItem(& $normalizedKey, & $value,
$ttl = 0);
-----------------------------------------------------------------------------------------
Zend\Cache\Storage\StorageInterface
-----------------------------------------------------------------------------------------
public function setItem($key, $value, $ttl = 0);
-----------------------------------------------------------------------------------------
Zend\Cache\Storage\Adapter\Memcached
-----------------------------------------------------------------------------------------
protected function internalSetItem(& $normalizedKey, & $value, $ttl = 0)
{
$memc = $this->getMemcachedResource();
$expiration = $ttl ? $ttl : $this->expirationTime();
if (!$memc->set($this->namespacePrefix . $normalizedKey, $value,
$expiration)) {
throw $this->getExceptionByResultCode($memc->getResultCode());
}
return true;
}
and finally
-----------------------------------------------------------------------------------------
DoctrineModule\Cache\ZendStorageCache
-----------------------------------------------------------------------------------------
protected function doSave($id, $data, $lifeTime = false)
{
return $this->storage->setItem($id, $data, $lifeTime);
}
So i have to make a PR an ZF2 (on all storage adpaters for setItem
signature) *AND* DoctrineModule.
And find the test for $ttl.
--
View this message in context:
http://zend-framework-community.634137.n4.nabble.com/Doctrine-Cache-in-use-tp4661873p4661886.html
Sent from the Zend Framework mailing list archive at Nabble.com.
--
List: [email protected]
Info: http://framework.zend.com/archives
Unsubscribe: [email protected]