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
Use smarter persistence context for findEach/iterate/stream queries - improve performance of un-tuned findEach/iterate/stream queries that invoke lazy loading
#2021
Closed
rbygrave opened this issue
Jun 17, 2020
· 0 comments
These changes should improve the performance of untuned findEach/iterate/stream queries that invoke lazy loading.
Changes:
Enable use existing persistence context (e.g. beans loaded by prior queries in the same transaction)
Use a smarter persistence context with a "per 1000 beans added" reset limit. This improves our use of batch lazy loading during iteration
Current limitations
The current implementation of has a few limitations which this change addresses. The findEach etc queries create their own persistence context effectively per "top level bean". The short lived persistence contexts allows these queries to support iterating of many thousands or millions of rows without having to how all the loaded beans in memory (ie. as we no longer have all beans referenced in a single persistence context).
The text was updated successfully, but these errors were encountered:
These changes should improve the performance of untuned findEach/iterate/stream queries that invoke lazy loading.
Changes:
Enable use existing persistence context (e.g. beans loaded by prior queries in the same transaction)
Use a smarter persistence context with a "per 1000 beans added" reset limit. This improves our use of batch lazy loading during iteration
Current limitations
The current implementation of has a few limitations which this change addresses. The findEach etc queries create their own persistence context effectively per "top level bean". The short lived persistence contexts allows these queries to support iterating of many thousands or millions of rows without having to how all the loaded beans in memory (ie. as we no longer have all beans referenced in a single persistence context).
The text was updated successfully, but these errors were encountered: