You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If an entity is deleted after creation, but before the EntityCache is flushed, it is not deleted from the cache and will be returned by findById(id: ID) in the same transaction block. The behaviour I would expect is that the entity is deleted from the cache, and that findById(id: ID) would return null. Flushing the cache before delete, or opening a new transaction block before deleting the entity fixes the issue.
Affected versions: 0.22.1 and 0.29.1 (others not tested)
Database: PostgreSQL 42.2.6
The text was updated successfully, but these errors were encountered:
kiliangrashoff
changed the title
Deleting entity after it is created does not delete it from transaction cache
Deleting entity after it is created does not delete it from cache
Feb 18, 2021
If an entity is deleted after creation, but before the EntityCache is flushed, it is not deleted from the cache and will be returned by
findById(id: ID)
in the same transaction block. The behaviour I would expect is that the entity is deleted from the cache, and thatfindById(id: ID)
would return null. Flushing the cache before delete, or opening a new transaction block before deleting the entity fixes the issue.Reproduction case:
Affected versions: 0.22.1 and 0.29.1 (others not tested)
Database: PostgreSQL 42.2.6
The text was updated successfully, but these errors were encountered: