What might cause a inaccessiblewsdlexception?

2020-07-10 09:06发布

问题:

I'm updating some web service clients into some old java applications to call an axis2 third party web service. I've been provided with a wsdl file, so I've developed a jar containing the client to this service as described in the following (mine) post: JAX-WS client : what's the correct path to access the local WSDL?.

It works on some application but not in others where it throws an inaccessibleWSDLException at the moment of instantiating the proxy class. Below I've posted my jax-ws-catalog file:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog" prefer="system">
    <system systemId="http://localhost/wsdl/SOAService.wsdl" uri="wsdl/SOAService.wsdl"/>
    <system systemId="http://schemas.xmlsoap.org/soap/encoding/" uri="wsdl/schemas.xmlsoap.org/soap/encoding.xsd"/>
    <system systemId="http://www.w3.org/2005/05/xmlmime" uri="wsdl/www.w3.org/2005/05/xmlmime.xsd"/>
</catalog>

It always work inside my development environments (netbeans\ecplise depending on the project I'm updating ) and servers (tomcat \Jboss 4 \ jar with a test class).

It doesn't work when:

  • I launch the jar from command line or
  • I load the jar into a livecycle 8.0 process (runs on jboss 4.0)

In both cases gives the error : "InaccessibleWSDLException", in particular on livecycle I get the following error :

2010-12-01 12:20:47,420 ERROR [com.adobe.workflow.AWS] stalling action-instance: 9989 with message: com.sun.xml.ws.wsdl.parser.InaccessibleWSDLException: 2 counts of InaccessibleWSDLException.

java.net.ConnectException: Connection refused
java.net.ConnectException: Connection refused

        at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.tryWithMex(RuntimeWSDLParser.java:172)
        at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:144)
        at com.sun.xml.ws.client.WSServiceDelegate.parseWSDL(WSServiceDelegate.java:254)
        at com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:217)
        at com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:174)
        at com.sun.xml.ws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:104)
        at javax.xml.ws.Service.<init>(Service.java:56)
        at com.ibm.eci.soaservice.SOAService.<init>(SOAService.java:50)

What does this exception mean? It can't find the wsdl or a piece of it? It can't find some library? It can't access the web (the wsdl contains some import of external xsd )?

回答1:

That means that livecycle 8.0 is not using or not finding jax-ws-catalog.xml, so the jaxws run-time is trying to load the WSDL from the literal location mentioned in the client stub, i.e. from http://localhost/wsdl/SOAService.wsdl instead of looking at the mapping provided in jax-ws-catalog.xml and using the WSDL from your application jar.

The clue is the

java.net.ConnectException: Connection refused java.net.ConnectException: Connection refused

which tells me that jaxws runtime is trying to access the WSDL over http.

Where do you put your jax-ws-catalog.xml ? may be for livecycle it needs to be put somewhere else, besides the JAR's META-INF directory.

I think you need to post this question on livecycle forums .

For not working from the command line, that is a bit strange, how exactly do you run it from the command line.



回答2:

Seems its looking for certificate file, please look in to that which certificate that was. Downloaded that certificate, restart your server and then try.

Regards, Sridhar Goranti