This article covers various issues experienced when capturing and parsing a WSDL file via URI with both the SOAPSonar and CloudPort products.
HELPFUL TIP: In many cases the WSDL retrieval via URI fails because the URI does not include the ?WSDL syntax. While the service endpoint in the WSDL itself will not show the ?WSDL at the end of the URI, definitely addd the ?WSDL to the end of the URI when attempting to capture the WSDL file via URI.
WSDL Capture Error:
There are two common causes to this error:
1. Network Issue - This error often indicates that SOAPSonar was unable to reach the host and therefore unable to capture of the WSDL. Ensure that SOAPSonar has network access to the server hosting the WSDL file and ensure the network path specified in the URI is correct. If necessary, configure the Proxy Settings on the File>>Settings and Preferences>>Global Proxy Settings screen.
2. Permissions Error - This issue can been caused by permissions / rights issues, even when the user running SOAPSonar is an Admin on the system. When SOAPSonar retrieves the WSDL it writes it locally to disk and lack of the proper permissions can prevent this.
Try closing SOAPSonar and then re-launching with the "run as Administrator" option (right click the shortcut). Then try to import the WSDL again.
If this fixes the issue, look into the permissions on the SOAPSonar install folder and the ability to write to the registry.
WSDL Parsing Error:
While the error syntax may vary, this error typically indicates that SOAPSonar was able to connect to the server hosting the WSDL, but the file retrieved is not a valid WSDL file. Very often the cause of this is the failure to add the ?WSDL syntax to the end of the URI.
If the service is requiring a form of protocol authentication on the HTTP GET for the WSDL retrieval, SOAPSonar will prompt the user to enter the credentials by opening the HTTP Credentials window. If the correct credentials aren't provided, eventually SOAPSonar will show the 401 Unauthorized error.
HELPFUL TIP: If you are unable to load the WSDL via URI into SOAPSonar, try the same URI in a browser on the same system. If the WSDL can be retrieved by a browser, the same URI should work in SOAPSonar. If the WSDL loads in a browser and not in SOAPSonar, check the browser's proxy server settings and configure the same in SOAPSonar. Also try running SOAPSonar with the "run as Administrator" option to check for permissions issues.