1

我想将文件从我的应用程序发送到 alfresco

我在 jboss 7 工作

但是当我测试我的应用程序和测试附件时,我遇到了这个错误:

10:25:33,684 INFO  [org.directwebremoting.log.accessLog] (http-localhost-127.0.0.1-8080-5) Method execution failed: : java.lang.NoSuchMethodError: org.apache.xml.security.transforms.Transform.init()V
    at org.apache.ws.security.WSSConfig.staticInit(WSSConfig.java:244) [wss4j-1.5.4-patched.jar:]
    at org.apache.ws.security.WSSConfig.<init>(WSSConfig.java:256) [wss4j-1.5.4-patched.jar:]
    at org.apache.ws.security.WSSConfig.getNewInstance(WSSConfig.java:265) [wss4j-1.5.4-patched.jar:]
    at org.apache.ws.security.handler.WSHandler.doSenderAction(WSHandler.java:89) [wss4j-1.5.4-patched.jar:]
    at org.apache.ws.axis.security.WSDoAllSender.invoke(WSDoAllSender.java:170) [wss4j-1.5.4-patched.jar:]
    at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32) [axis-1.4.jar:]
    at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118) [axis-1.4.jar:]
    at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83) [axis-1.4.jar:]
    at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127) [axis-1.4.jar:]
    at org.apache.axis.client.Call.invokeEngine(Call.java:2784) [axis-1.4.jar:]
    at org.apache.axis.client.Call.invoke(Call.java:2767) [axis-1.4.jar:]
    at org.apache.axis.client.Call.invoke(Call.java:2443) [axis-1.4.jar:]
    at org.apache.axis.client.Call.invoke(Call.java:2366) [axis-1.4.jar:]
    at org.apache.axis.client.Call.invoke(Call.java:1812) [axis-1.4.jar:]

我在我的应用程序中使用这个罐子:

alfresco-web-service-client-4.0.d.jar,axis-1.4.jar,axis-saaj-1.2.jar,wsdl4j-1.6.2.jar,wss4j-1.5.4-patched.jar

4

1 回答 1

0

看来您缺少xmlsec-1.4.2.jar,或其他版本。

如果这没有帮助,你可能有类冲突,所以检查

META-INF/jboss-deployment-structure.xml

org.apache.xml.security并排除

<?xml version="1.0" encoding="UTF-8"?>
<jboss-deployment-structure xmlns="urn:jboss:deployment-structure:1.1">
    <ear-subdeployments-isolated>true</ear-subdeployments-isolated>
    <deployment>
        <dependencies>
            <module name="deployment.javaee.api" />
        </dependencies>
        <exclusions>
            <module name="javaee.api" />
        </exclusions>
    </deployment>
    <module name="deployment.javaee.api">
        <dependencies>
            <module name="javaee.api" export="true">
                <imports>
                    <exclude path="org/apache/xml/security/**" />
                </imports>
            </module>
        </dependencies>
    </module>
</jboss-deployment-structure>
于 2013-11-11T12:19:20.780 回答