首页 文章

在Mule功能测试中加载的配置会抛出错误,但会在测试之外运行

提问于
浏览
1

我有一个奇怪的情况,在Mule功能测试中加载的Mule配置从vm的流中抛出以下类型的错误 . 令人讨厌的是这个流程完美地作为骡子应用程序,有时通过调整mule工作室我可以让测试运行,几乎随机 .

<flow name="simpleOutBoundFlow">
    <vm:inbound-endpoint path="testV"
        name="test" />
    <logger level="ERROR"
        message="blah #[payload]" />
    <foo:outbound config-ref="fooOutbound" doc:name="baa" />
</flow>

错误发生在vm:行并说出类似的内容

org.mule.api.config.ConfigurationException:来自URL [file:/ D:/config.xml]的XML文档中的第21行无效;嵌套异常是org.xml.sax.SAXParseException; lineNumber:21; columnNumber:18; cvc-complex-type.2.4.a:从元素'vm:inbound-endpoint'开始发现无效内容 . 其中一个'{“http://www.mulesoft.org/schema/mule/core":annotations,"http://www.mulesoft.org/schema/mule/core":description,"http:// www .mulesoft.org / schema / mule / core“:abstract-message-source,”http://www.mulesoft.org/schema/mule/core":abstract-inbound-endpoint,“http://www.mulesoft .org / schema / mule / core“:abstract-message-processor,”http://www.mulesoft.org/schema/mule/core":abstract-outbound-endpoint,“http://www.mulesoft.org / schema / mule / core“:abstract-mixed-content-message-processor,”http://www.mulesoft.org/schema/mule/core":response}'是预期的 . org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:52)中的(org.mule.api.lifecycle.InitialisationException)

有任何想法吗?对我来说真的很奇怪 .

nb:foo:outbound来自我使用maven devkit archtype生成的devKit更新站点

1 回答

  • 2

    这通常发生在项目类路径中缺少 mule-transport-vm JAR时 . 确保它与 pom.xml 范围中的 pom.xml 文件一起出现 .

相关问题