【问题标题】:Mule Can not start XA transactionMule 无法启动 XA 事务
【发布时间】:2017-01-31 07:57:05
【问题描述】:

您好,我设置了三个流来接受来自 http 入站端点的消息、发送到 VM 端点并再次发送到各种其他 VM 端点,最终发送到 JMS 出站端点。

我需要在这些连接器之间配置事务性,并且我正在使用 xa-transaction 操作和具有<jms:transaction action="ALWAYS_JOIN" />configured 的 JMS 端点。当消息进入 http 入站端点并转到我得到的第一个 VM 端点时,这似乎不起作用


消息:无法启动 XA 事务

代码:MULE_ERROR-95

异常堆栈是: 1. 名称为“Transaction Manager”的“javax.transaction.TransactionManager”类型的对象在注册表中不可用(java.lang.IllegalStateExcep 化) org.mule.transaction.XaTransaction:56(空) 2.无法启动XA事务(org.mule.api.transaction.TransactionException) org.mule.transaction.XaTransactionFactory:37 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/api/transaction/TransactionException.html)


根异常堆栈跟踪: java.lang.IllegalStateException:名称为“Transaction Manager”的“javax.transaction.TransactionManager”类型的对象在注册表中不可用 是的 在 org.mule.transaction.XaTransaction.doBegin(XaTransaction.java:56) 在 org.mule.transaction.AbstractTransaction.begin(AbstractTransaction.java:65) 在 org.mule.transaction.XaTransactionFactory.beginTransaction(XaTransactionFactory.java:32) + 3 个以上(设置调试级别日志记录或 '-Dmule.verbose.exceptions=true' 为所有内容)


我的流程定义如下。

    <http:inbound-endpoint address="${test.service.proxy}"
                           transformer-refs="xmlToDom">
    </http:inbound-endpoint>
    <logger level="INFO" message="#[flow.name]: #[payload] #[message]" doc:name="Logger"/>
    <vm:outbound-endpoint path="receiveMessageStage2VM">
        <xa-transaction action="ALWAYS_BEGIN"/>
    </vm:outbound-endpoint>
</flow>

<flow name="ReceiveMessageStage2Idempotency">
    <vm:inbound-endpoint path="receiveMessageStage2VM">
        <xa-transaction action="ALWAYS_JOIN"/>
    </vm:inbound-endpoint>
    <pooled-component>
        <spring-object bean="receiveMessageIdempotentComponent"/>
        <binding interface="en.test.mf.doc.components.SyncSender">
            <vm:outbound-endpoint path="receiveMessageStage3VM">
                <xa-transaction action="ALWAYS_JOIN"/>
            </vm:outbound-endpoint>
        </binding>
    </pooled-component>
</flow>

<flow name="ReceiveMessageStage3Idempotency">

    <vm:inbound-endpoint path="receiveEVRMessageStage3VM"
                         responseTransformer-refs="jmsToString">
        <xa-transaction action="ALWAYS_JOIN"/>
    </vm:inbound-endpoint>
    <component>
        <spring-object bean="zipFileMessageHandler"/>
    </component>
    <logger level="INFO" message="#[flow.name]: #[payload] #[message]" doc:name="Logger"/>
    <outbound-endpoint ref="JMS_outbound_endpoint"
                       doc:name="JMS_outbound_endpoint"/>
</flow>

有人知道我如何实现这个功能吗?

【问题讨论】:

    标签: mule


    【解决方案1】:

    【讨论】:

      猜你喜欢
      • 2015-10-01
      • 1970-01-01
      • 1970-01-01
      • 2011-09-07
      • 1970-01-01
      • 2013-01-21
      • 1970-01-01
      • 1970-01-01
      • 2021-01-18
      相关资源
      最近更新 更多