posted 9 years ago
Hi
I trying including a family of people, one by one... and the son records referencing the children their parents.
I have one @Transactional(propagation= Propagation.REQUIRED, rollbackFor = Throwable.class)
customer Table:
ID_CUSTOMER | NAME_CUSTOMER | ID_FATHER_CUSTOMER
1 | BOB | (null)
2 | BOB SON | 1
3 | SANDY SON | 1
...
In this case, let's imagine that 'SANDY SON' has inconsistent data and the application will get throws an exception.
I am not able to perform the rollback of the entire family (BOB and BOB SON) .... They're already commited in the database. Why ?
I can not configure Spring do not commit in this situation described above?
How I can get rollback?
Tks []'s