Greetings, actually what's my problem. I can not adequately get Hibernate to work. Maybe someone can tell a recipe for approaching it, I don’t ask for the code, just what, how to set it up so as not to catch all sorts of problems.
What I have:
Entities with connections. fetch everywhere LAZY, cascade = ALL
A couple of methods implemented in the style of open session, save / receive, commit. Next session takes my bike, which closes them after 10 seconds.
Tests that in parallel begin to peel at all DAO methods,
From time to time, these tests get:
LockAcquisitionException: could not execute statement
LockAcquisitionException: could not extract ResultSet
and their source HsqlException: transaction rollback: serialization failure
Everything is so bad that I already screwed it in
<property name="jta.UserTransaction">8</property> <property name="hibernate.connection.isolation">8</property> hsqldb.tx=mvcc and hell, I think he ignores them. Or I do not understand why at the SERIALIZATION level can it catch problems with transactions?
If necessary, I can throw off the code. Although I'm just asking about the approach :)