Reputation: 946
Is it possible to catch exception inside spring transaction and commit without rollback?
Upvotes: 1
Views: 279
Reputation: 7940
You can specify exceptions to be ignored, in other words the commit will happen.
Example
@Transactional(noRollbackFor = SomeException.class)
Doc is here
Or you can just catch the exception, will have the same effect.