<?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: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/vm/2.0 http://www.mulesource.org/schema/mule/vm/2.0/mule-vm.xsd">

    <vm:connector name="vm" queueEvents="true">
        <default-connector-exception-strategy>
            <vm:outbound-endpoint path="error"/>
        </default-connector-exception-strategy>
    </vm:connector>

    <custom-transformer name="fail" class="org.mule.test.transformers.FailingTransformer"/>

    <model name="test">

        <service name="with-router">
            <inbound>
                <vm:inbound-endpoint path="with-router-in" transformer-refs="fail"/>
                <forwarding-router/>
            </inbound>
            <outbound>
                <outbound-pass-through-router>
                    <vm:outbound-endpoint path="with-router-out"/>
                </outbound-pass-through-router>
            </outbound>
        </service>

        <service name="without-router">
            <inbound>
                <vm:inbound-endpoint path="without-router-in" transformer-refs="fail"/>
            </inbound>
            <outbound>
                <outbound-pass-through-router>
                    <vm:outbound-endpoint path="without-router-out"/>
                </outbound-pass-through-router>
            </outbound>
            <!-- need this instead -->
            <default-service-exception-strategy>
                <vm:outbound-endpoint path="error"/>
            </default-service-exception-strategy>
        </service>

    </model>
    
</mule>
