使用mule-restlet传输时,在mule-config.xml中找到无效内容元素'或'

时间:2011-12-17 06:03:57

标签: restlet mule

首先,请查看mule-config.xml中的摘录:

<model name="userModel">
        <service name="userService">
            <inbound>
                <inbound-endpoint address="http://localhost:63080"/>
            </inbound>
            <outbound>
                <filtering-router>
                    <outbound-endpoint address="vm://userController"/>
                    <or>
                        <restlet:uri-template-filter pattern="/users/{userId}" verbs="GET"/>
                        <restlet:uri-template-filter pattern="/users" verbs="POST"/>
                        <restlet:uri-template-filter pattern="/users" verbs="PUT"/>
                        <restlet:uri-template-filter pattern="/users/{userId}" verbs="DELETE"/>
                    </or>
                </filtering-router>
            </outbound>
        </service>
        <service name="userController">
            <inbound>
                <inbound-endpoint address="vm://userController"/>
            </inbound>
            <!-- TODO: How to implement UserController -->
            <component class="com.ggd543.mulerestletdemo.user.UserController"/>
        </service>
    </model>

当我将其部署到$MULE_HOME/apps时,mule抱怨: enter image description here

PS:我的骡子版本是3.1.2,我正在使用mule-transport-restlet-2.0.jar

我的mule-config.xml有什么问题吗?

1 个答案:

答案 0 :(得分:1)

<or>更改为<or-filter>即可。 doument(http://www.mulesoft.org/documentation/display/RESTLET/User%27s+Guide#User%27sGuide-URITemplateRouting)太旧了。 WTF