简体   繁体   中英

Impossible to generate java client code from some wsdl

I'm trying with this specific URL:

<plugin>
    <groupId>org.apache.axis2</groupId>
    <artifactId>axis2-wsdl2code-maven-plugin</artifactId>
    <version>1.7.9</version>
    <configuration>
        <wsdlFile>https://web.rbsuat.com/ab/webservices/merchant-ws?wsdl</wsdlFile>
    </configuration>
</plugin>

But got the exception during the plugin execution:

[ERROR] Failed to execute goal org.apache.axis2:axis2-wsdl2code-maven-plugin:1.7.9:wsdl2code (default-cli) on project test: Error parsing WSDL: Connection reset -> [Help 1]

The most likely is that it would be SSLv3 related issue for the newset java when the SSLv3 is disabled and I should enable it by removing the

jdk.tls.disabledAlgorithms=SSLv3

from JRE_HOME/lib/security/java.security , however, I did it and still face the same problem

Actually, the URL https://web.rbsuat.com/ab/webservices/merchant-ws?wsdl can be reached from the browser without any problem.

1 - To generate Java client from a given WSDL file, you can use SoapUI tool to achieve that by following the instructions given in below links. It basically shows you how you can use different code generation tools like Axis 1.X, Axis 2, CXF 2.X, and .NET 2.0 to generate client code.

SOAP Code Generation

Generating Client JAVA code for WSDL using SOAP UI

2 - Once the Java client code is generated you can add the following parameter in your Java client before calling the external service to generate the SSL logs.

System.setProperty("javax.net.debug", "all");

Then by seeing the SSL logs will come to know what is the problem you are facing when trying to call this service.

the IDE didn't picked up my config changes in jre folder until it was restarted, that was the reason. I had to restart my IDE

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM