<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE mule-configuration PUBLIC "-//MuleSource //DTD mule-configuration XML V1.0//EN"
                                "http://mule.mulesource.org/dtds/mule-configuration.dtd">

<mule-configuration id="test" version="1.0">
    
    <!-- Container context -->
    <container-context name="spring" className="org.mule.module.spring.SpringContainerContext">
        <properties>
            <property name="configFile" value="org/mule/test/integration/transaction/xatransaction-with-spring-datasource.xml"/>
        </properties>
    </container-context>

    <transaction-manager factory="org.mule.module.jotm.JotmTransactionManagerFactory"/>

    <connector name="jmsXAConnector" className="org.mule.transport.jms.activemq.ActiveMqJmsConnector">
        <properties>
            <container-property name="connectionFactory" reference="jmsConnectionFactory"/>
            <property name="specification" value="1.1"/>
        </properties>
    </connector>

    <connector name="VMQueue" className="org.mule.transport.vm.VMConnector">
        <properties>
            <property value="true" name="queueEvents"/>
        </properties>
    </connector>

    <model name="model">

        <mule-descriptor name="JmsToJdbc" implementation="MyComponent" singleton="true">
            <inbound-router>
                <endpoint address="jms://my.queue" connector="jmsXAConnector" remoteSync="true">
                    <transaction action="ALWAYS_BEGIN" factory="org.mule.transaction.XaTransactionFactory"/>
                </endpoint>
            </inbound-router>
            <outbound-router>
                <router className="org.mule.routing.outbound.OutboundPassThroughRouter">
                    <endpoint address="vm://output"/>
                </router>
            </outbound-router>
            <properties>
                <container-property name="library" reference="libraryDao"/>
            </properties>
        </mule-descriptor>
    </model>
</mule-configuration>