我已经使用mule Studio 3.2.1来开发Mule应用程序。在该应用程序中,我已经使用了org.springframework.ws.client.core.webserviceTemptemptemptex将WebService请求发送到另一个应用程序。 我使用了以下配置

 <bean id="myWsTemplate"  clsass="org.springframework.ws.client.core.WebServiceTemplate">
    <constructor-arg ref="messageFactory" />
    <property name="defaultUri" value="${my.soap.endpoint}" />
    <property name="interceptors">
        <list>
            <ref bean="acqSecurityInterceptor" />
        </list>
    </property> 
.

 <bean id="acqSecurityInterceptor" class="org.springframework.ws.soap.security.wss4j.Wss4jSecurityInterceptor">
    <property name="validationActions" value="NoSecurity"/>
    <property name="securementActions" value="NoSecurity" />
</bean>
.

我使用了的maven依赖

    <dependency>
        <groupId>org.springframework.ws</groupId>
        <artifactId>spring-ws-security</artifactId>
        <version>2.1.0.RELEASE</version>
    </dependency>
.

这将使用wss4j-1.6.5.jar作为依赖项。 现在,当我在mule 3.2.0中部署应用程序时,它会抛出以下错误

  PropertyAccessException 1: org.springframework.beans.MethodInvocationException: Property 'validationActions' threw exception; nested exception is java.lang.NoSuchMethodError: org.apache.ws.security.util.WSSecurityUtil.decodeAction(Ljava/lang/String;Ljava/util/List;)I
  PropertyAccessException 2: org.springframework.beans.MethodInvocationException: Property 'securementActions' threw exception; nested exception is java.lang.NoSuchMethodError: org.apache.ws.security.util.WSSecurityUtil.decodeAction(Ljava/lang/String;Ljava/util/List;)I
. 现在,mule 3.2.0的lib / opt目录配有wss4j-1.5.8-osgi.jar,wssecurityutil上的方法签名是公共静态int解码(字符串操作,矢量动作) 虽然被尝试的那个是 解码(Ljava / Lang / String; ljava / util / list;),它在wss4j.1.6.5中存在

我的问题是甚至我的应用程序有wss4j-1.6.5.jar为什么类加载器仍然尝试在mule / lib / opt中使用一个。应用程序中的那个不覆盖优先级吗? 如果没有有办法让它的工作方式

有帮助吗?

解决方案

确定在mule-deploy.properties中使用以下配置有助于 loader.override= -org.apache.ws.security.util.wssecurity util. 裁判 http://www.mesoft.org/documentation/display/mule3user/ ClassLoader + Control + In + mule

但仍然加载jars的jars,在Mule Studio中构建为插件,然后尝试在独立骡子中部署。将在另一个线程中创建各种各样的此类问题列表。

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top