#1169 DDC-3343 - eagerly evicting cache if a persister passes a delete operation down to the DB
This commit is contained in:
parent
a9671fdc2e
commit
c7a6352b08
@ -103,7 +103,9 @@ class ReadWriteCachedEntityPersister extends AbstractEntityPersister
|
|||||||
$key = new EntityCacheKey($this->class->rootEntityName, $this->uow->getEntityIdentifier($entity));
|
$key = new EntityCacheKey($this->class->rootEntityName, $this->uow->getEntityIdentifier($entity));
|
||||||
$lock = $this->region->lock($key);
|
$lock = $this->region->lock($key);
|
||||||
|
|
||||||
$this->persister->delete($entity);
|
if ($this->persister->delete($entity)) {
|
||||||
|
$this->region->evict($key);
|
||||||
|
}
|
||||||
|
|
||||||
if ($lock === null) {
|
if ($lock === null) {
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user