Go to content Go to navigation Go to search

Hibernate Performance

Instead of

SELECT a ...

use

SELECT DISTINCT a INNER JOIN FETCH a.rels ...

Then each iteration over as will not hit the DB.
for( A a : as ) { for( Rel r : a.getRels() ) { ... } }

Previous post:
Getting Tomcat native APR to work
Next post:
Damn Java Gotchas