I have two entites with JpaRepo Say A and B (I don't have any custom api, I am using spring data rest)
When I do any update to A I use @HandleAfterSave and add an entry to B.
I need to ensure that either both the updates are done or none are done.
example:
If A fails B will obviously fails. But if B fails A should not perform an update ?
What should I do to achieve this ?
Thanks a lot in Advance .