Erik (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
) *created* an issue
Hibernate ORM (
https://hibernate.atlassian.net/browse/HHH?atlOrigin=eyJpIjoiMWJiOWMxZTdm...
) / Improvement (
https://hibernate.atlassian.net/browse/HHH-14016?atlOrigin=eyJpIjoiMWJiOW...
) HHH-14016 (
https://hibernate.atlassian.net/browse/HHH-14016?atlOrigin=eyJpIjoiMWJiOW...
) Can not prevent cache region from being cleared from second level cache on bulk update (
https://hibernate.atlassian.net/browse/HHH-14016?atlOrigin=eyJpIjoiMWJiOW...
)
Issue Type: Improvement Affects Versions: 5.4.15 Assignee: Unassigned Created: 12/May/2020
10:57 AM Priority: Minor Reporter: Erik (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
)
Bulk updates using queries or the criteria API can be used to avoid fetching an entity
before executing the update. For example:
UPDATE User u SET u.deleted = true WHERE u.id = :id
In this case, the only modified entity is known, and the entity in question could be
manually evicted from the second level cache.
Instead, the whole cache region is evicted through a BulkOperationCleanupAction , and I
have not been able to find a workaround for this. Currently it seems like it'd require
modifying the EntityPersister itself, as this is where the affected regions are taken
from.
(
https://hibernate.atlassian.net/browse/HHH-14016#add-comment?atlOrigin=ey...
) Add Comment (
https://hibernate.atlassian.net/browse/HHH-14016#add-comment?atlOrigin=ey...
)
Get Jira notifications on your phone! Download the Jira Cloud app for Android (
https://play.google.com/store/apps/details?id=com.atlassian.android.jira....
) or iOS (
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=Em...
) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100126- sha1:dd08494 )