添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

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

Enhancement

This is in continuation of #1341 ,

We have seen that in case exception occurs in Spring Transaction After Completion Phase, the exception is thrown back to the caller method of Spring transaction . So is there some callback handling available to caller code in case the error is thrown ?

Also we have seen that in this case the resource is left over from previous transaction in case of exception thrown while commit and this corrupts the thread for subsequent flows. Can this be handled?

Errors in TransactionSynchronization.afterCompletion() are simply logged in TransactionSynchronizationUtils . There is no way to throw an exception to the calling thread. I don't see an easy way to add a callback; that code is all in core spring-transaction.

As discussed on that issue; I can't see any way that a resource can be "left over" from one operation to another; this code has been around for over a decade. Please provide a MCRE that exhibits this behavior.

Callback handling , How to use callback | Ref : https://github.com/spring-projects/spring-amqp/issues/1362 #1379