mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
SecondCacheLevel association and inheritance update problem #5105
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @mpoiriert on GitHub (Apr 19, 2016).
Originally assigned to: @lcobucci on GitHub.
I have a entities like this (I just document the minimum needed):
When changing the ChildClass->associations value and persisting it the data in the cache is not removed.
Investigating I found that the Doctrine\ORM\Cache\Persister\Entity\AbstractEntityPersister is using the entityName (that will be ChildClass) but that the Doctrine\ORM\Cache\Persister\Collection\NonStrictReadWriteCachedCollectionPersister is using the $this->sourceEntity->rootEntityName (that will be BaseClass) So it doesn't clear the proper key entry.
Pretty easy to change but might be risky...
If you consider that I am on the good track I can give it a try to make the unit test for it.