Spring's transaction configuration

来源:互联网 发布:modbus主站程序单片机 编辑:程序博客网 时间:2024/04/28 10:36

we often use "PROPAGATION_REQUIRED" to config our transaction.

but if there throw an exception ,the transaction will not rollback as we expect.

 

so,we should add a special code in the configuration file to resolve this problem.

 

the code below:

 

"PROPAGATION_REQUIRED,-Exception"

原创粉丝点击