Caching does not work properly when hibernate.cache.use_structured_entries is turned on

Description

When hibernate.cache.use_structured_entries is set to true, entities that have superclass are not properly put in cache. Problem is in org.hibernate.sql.results.graph.entity.AbstractEntityInitializer.putInCache , structure from superclass is used for storing cache entry, instead of structure from entity that should be put in cache. This is only a problem when hibernate.cache.use_structured_entries is set to true (see org.hibernate.cache.spi.entry.StructuredCacheEntry.structure vs org.hibernate.cache.spi.entry.UnstructuredCacheEntry.structure). Gradle test case attached.

Attachments

1

Activity

Show:
Fixed

Details

Assignee

Reporter

Sprint

Fix versions

Affects versions

Priority

Created May 29, 2023 at 4:05 PM
Updated June 15, 2023 at 9:23 AM
Resolved June 14, 2023 at 8:29 AM