Spring集成中的全局事务处理 [英] Global Transaction Handling in Spring Integration

查看:50
本文介绍了Spring集成中的全局事务处理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

它是一个 Spring 集成应用程序.我有一个要求,我需要坚持到数据库,然后发布到队列/主题.这应该是单个事务的一部分.我打算使用 JTATransactionManager.应用服务器是Tomcat.有人请提供一些此实现所需的示例配置代码.

Its a Spring Integration application.I have a requirement where I need to persist to DB and then post to Queue/Topic. This should be part of a single transaction. I am planning to use the JTATransactionManager. Application Server is Tomcat. Would someone please provide some sample configuration code required for this implementation.

推荐答案

您需要第三方独立的 XA 事务管理器,例如 Atomikos.Tomcat 没有.

You need a third party stand-alone XA transaction manager such as Atomikos. Tomcat doesn't have one.

您也可以考虑 使用成熟的 2pc 的替代方案.

这篇关于Spring集成中的全局事务处理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆