Non transactional query cache only cache results if transaction is committed

Description

Local query caches are not populated if the transaction is not committed.
The same test case works on hibernate 4.3.11

Our scenario: Read-only services that only execute queries and never commit the transaction. It should still be possible to use/configure hibernate/infinispan to cache the results, regardless the transaction state.

The test case:

Test case is attached: MyApp3
Test case class: com.myapp.NonTransactionalQueryCacheTest

Environment

JPA/Hibernate + Spring + JTA + Infinispan

Assignee

Galder Zamarreno

Reporter

Jones

Fix versions

None

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Worked in

4.3.11

Components

Affects versions

Priority

Major
Configure