Toplink batch reading

634 Views Asked by At

IS their any way to set property like hibernate 'hibernate.batch_size' in toplink. which will increase fetching query performance.

1

There are 1 best solutions below

0
James On

Batch reading is supported in TopLink, but I'm not sure about TopLink Essentials. You can do it by accessing the ReadAllQuery and adding the relationship to be batch read.

You could also upgrade to EclipseLink, which supports batch fetching using the query hint "eclipselink.batch", and also support batch fetch using joins, in, or sub-selects.

See, http://wiki.eclipse.org/EclipseLink/Examples/JPA/QueryOptimization

http://java-persistence-performance.blogspot.com/2010/08/batch-fetching-optimizing-object-graph.html