Note that there are some explanatory texts on larger screens.

plurals
  1. POUsing CXF web service from java web start
    primarykey
    data
    text
    <p>UPDATE: I have submitted my question to the CXF User's mailing list, <del>here</del>.</p> <p>UPDATE: I have currently signed all of my jars. I still can't seem to get CXF setup in a way that it can find the WSDL. My last attempt was to place the WSDL inside of my WAr file so I can access it through a web browser. I set the wsdllocation inside of the client to the URL (<a href="http://www.example.com/app/example.wsdl" rel="nofollow noreferrer">http://www.example.com/app/example.wsdl</a>). I am now getting the following exception:</p> <pre><code>Exception in thread "AWT-EventQueue-0" java.lang.ExceptionInInitializerError at com.sun.xml.internal.ws.util.xml.XmlUtil.createDefaultCatalogResolver(Unknown Source) at com.sun.xml.internal.ws.client.WSServiceDelegate.parseWSDL(Unknown Source) at com.sun.xml.internal.ws.client.WSServiceDelegate.&lt;init&gt;(Unknown Source) at com.sun.xml.internal.ws.client.WSServiceDelegate.&lt;init&gt;(Unknown Source) at com.sun.xml.internal.ws.spi.ProviderImpl.createServiceDelegate(Unknown Source) at javax.xml.ws.Service.&lt;init&gt;(Unknown Source) </code></pre> <p>Googling has turned up pretty much nothing on this.</p> <p>I am creating a web service client from a given WSDL using <a href="http://en.wikipedia.org/wiki/Apache_CXF" rel="nofollow noreferrer">Apache CXF</a>. I am running into problems however when trying to access the service, I get this exception:</p> <pre><code>Can not initialize the default wsdl from ../resource/example.wsdl Exception in thread "AWT-EventQueue-0" java.security.AccessControlException: access denied (java.util.PropertyPermission user.dir read) at java.security.AccessControlContext.checkPermission(Unknown Source) at java.security.AccessController.checkPermission(Unknown Source) at java.lang.SecurityManager.checkPermission(Unknown Source) at java.lang.SecurityManager.checkPropertyAccess(Unknown Source) </code></pre> <p>I am not signing my web start application, and would prefer not to since I am not accessing any resources from the client's machine. The <a href="http://en.wikipedia.org/wiki/Web_Services_Description_Language" rel="nofollow noreferrer">WSDL</a> mentioned is packaged within my jar. The problem is caused by this from the CXF generated client code:</p> <pre><code> URL url = null; try { url = new URL("../resource/example.wsdl"); } catch (MalformedURLException e) { System.err.println("Can not initialize the default wsdl from ../resource/example.wsdl"); // e.printStackTrace(); } WSDL_LOCATION = url; </code></pre> <p>How can I correctly point CXF to this WSDL? I am also worried about the WebService annotation on the class:</p> <pre><code>@WebServiceClient(name = "Example", wsdlLocation = "../resource/example.wsdl", targetNamespace = "http://services.example.com/") </code></pre> <p>Do I also need to change this?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload