首页 文章

在Mule配置文件上运行测试时抛出异常

提问于
浏览
0

在包含的配置文件上运行测试时抛出异常以下异常 . 任何想法可能是什么原因?

Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name '_muleNotificationManager': FactoryBean threw exception on object creation; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'muleTxMgr' defined in URL [src/test/resources/com/thrivent/em/db/config/xa-transaction-test.xml]: Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: org.mule.util.NetworkUtils.getLocalHost()Ljava/net/InetAddress;

引起:org.springframework.beans.factory.BeanCreationException:创建名为'muleTxMgr'的bean在URL [/src/test/resources/com/sma/edb/config/xa-transaction-test.xml]中定义时出错:调用init方法失败;嵌套异常是java.lang.NoSuchMethodError:org.mule.util.NetworkUtils.getLocalHost()Ljava / net / InetAddress;引起:java.lang.NoSuchMethodError:org.mule.util.NetworkUtils.getLocalHost()Ljava / net / InetAddress;

http://www.mulesoft.org/schema/mule/vm/current/mule-vm.xsd

Blockquote

http://www.mulesoft.org/schema/mule/jms http://www.mulesoft.org/schema/mule/jms/current/mule-jms.xsd 
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-current.xsd 
    http://www.mulesoft.org/schema/mule/jdbc http://www.mulesoft.org/schema/mule/jdbc/current/mule-jdbc.xsd
http://www.mulesoft.org/schema/mule/ee/bti http://www.mulesoft.org/schema/mule/ee/bti/current/mule-bti-ee.xsd 
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd  
http://www.mulesoft.org/schema/mule/jbossts http://www.mulesoft.org/schema/mule/jbossts/current/mule-jbossts.xsd  
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd">
 <context:property-placeholder location="com/sma/edb/config/hsql.database.properties"></context:property-placeholder>
 <jbossts:transaction-manager></jbossts:transaction-manager>
 <spring:beans> 
      <spring:bean class="org.mule.config.spring.factories.MuleTransactionManagerFactoryBean" id="muleTxMgr"></spring:bean> 
      <spring:bean id="hsqlDataSource" class="org.enhydra.jdbc.standard.StandardXADataSource"> 
         <spring:property name="driverName" value="${jdbc.driverClassName}"></spring:property>  
         <spring:property name="url" value="${jdbc.url}"></spring:property>  
       <spring:property name="transactionManager" ref="muleTxMgr"></spring:property>  
        <spring:property name="user" value="${jdbc.username}"></spring:property>  
         <spring:property name="password" value="${jdbc.password}"></spring:property>  
     </spring:bean>  
     <spring:bean id="dbQuerySql" class="java.lang.String"> 
         <spring:constructor-arg> 
             <spring:value>SELECT 1</spring:value>  
         </spring:constructor-arg>  
     </spring:bean>  
 </spring:beans>

1 回答

  • 1

    看起来版本与我发生冲突,因为版本 3.6 中引入了 org.mule.util.NetworkUtils.getLocalHost() .

相关问题