High-performance Java Persistence.pdf -
Vlad Mihalcea distills years of expertise into one simple truth: It is a tool that requires a deep understanding of both the database and the framework to perform well.
A common mistake is to use entities for all database operations. If you only need to update the status of 50 orders, do not load 50 Order entities into the Persistence Context, dirty check them, and let Hibernate generate 50 update statements. High-performance Java Persistence.pdf