Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent treatment of Errors by CallbackPreferringPlatformTransactionManager [SPR-15749] #20305

spring-projects-issues opened this issue Jul 9, 2017 · 0 comments
in: data status: waiting-for-triage


Copy link

@spring-projects-issues spring-projects-issues commented Jul 9, 2017

Philippe Marschall opened SPR-15749 and commented

Most places in spring-tx treat RuntimeException and Error equally rolling back in both cases as both of them are unchecked. This can be seen in TransactionAspectSupport. completeTransactionAfterThrowing and DefaultTransactionAttribute. rollbackOn

The execution path for CallbackPreferringPlatformTransactionManager seems to be different
where an Error is not thrown but instead wrapped in a ThrowableHolderException. However looking at the code in (used by the only present implementation of CallbackPreferringPlatformTransactionManager) any kind of Throwable seems to cause a rollback. It seems to me as if RuntimeException and Error should be treated equally in the CallbackPreferringPlatformTransactionManager path in

Affects: 4.3.9

@spring-projects-issues spring-projects-issues added type: bug status: waiting-for-triage in: data and removed type: bug labels Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
in: data status: waiting-for-triage
None yet

No branches or pull requests

1 participant