<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns="http://www.mulesource.org/schema/mule/core/2.0"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:spring="http://www.springframework.org/schema/beans"
       xmlns:mxml="http://www.mulesource.org/schema/mule/xml/2.0"
       xmlns:vm="http://www.mulesource.org/schema/mule/vm/2.0"
    xsi:schemaLocation="
       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
       http://www.mulesource.org/schema/mule/core/2.0 http://www.mulesource.org/schema/mule/core/2.0/mule.xsd
       http://www.mulesource.org/schema/mule/xml/2.0 http://www.mulesource.org/schema/mule/xml/2.0/mule-xml.xsd
       http://www.mulesource.org/schema/mule/vm/2.0 http://www.mulesource.org/schema/mule/vm/2.0/mule-vm.xsd">

    <vm:connector name="default"/>
    <vm:connector name="queue" queueEvents="true"/>

    <mxml:object-to-xml-transformer name="objectToXml"/>
    <mxml:xml-to-object-transformer name="xmlToObject"/>

    <vm:endpoint name="xml-in" path="xml-in" connector-ref="default"/>
    <vm:endpoint name="object-in" address="vm://object-in" connector-ref="default"/>
    <vm:endpoint name="xml-object-out" address="vm://xml-object-out" connector-ref="queue"/>
    <vm:endpoint name="object-out" path="object-out" connector-ref="queue"/>
    <vm:endpoint name="object-xml-out" address="vm://object-xml-out" connector-ref="queue"/>

    <model name="mule-2136">

        <service name="xml to ...">
            <inbound>
                <inbound-endpoint ref="xml-in"/>
            </inbound>
            <outbound>
                <multicasting-router>
                    <vm:outbound-endpoint ref="xml-object-out" transformer-refs="xmlToObject"/>
                </multicasting-router>
            </outbound>
        </service>

        <service name="object to xml">
            <inbound>
                <inbound-endpoint ref="object-in"/>
            </inbound>
            <outbound>
                <multicasting-router>
                    <vm:outbound-endpoint ref="object-out"/>
                    <vm:outbound-endpoint ref="object-xml-out" transformer-refs="objectToXml"/>
                    <vm:outbound-endpoint ref="xml-in" transformer-refs="objectToXml"/>
                </multicasting-router>
            </outbound>
        </service>

    </model>

</mule>
