I have dao which basically inserts a record into a table using hibernate, this dao is marked by @Transactional annotation with propogation-NESTED, and I have service which makes some other stuff and then invokes my dao. My service is also annotated with @Transactional with propagation-REQUIRED.
I call service in a loop. Does my inserts on my dao works in batch or one by one? How can I be sure that they work in batch? Does hibernateTransaction manager manage batch inserts?
I am using Oracle DB.
解决方案
I have set following property and my performance increased;
hibernate.jdbc.batch_size=50