Wsdl parsing error - the system cannot find the specified path

My wsdl is located at http://localhost:9999/ws/hello?wsdl .
I use the wsimport tool to analyze the published wsdl file and create the necessary client files (stubs) to access the published web service.

I can not parse this wsdl, enter image description here

How can i solve this?

HelloWorld.java is an interface , and - HelloWorldImpl.java Both of them are in the directory below,
 C:\Users\ANSARI\Desktop\Lexicon\WorkSpaceLuna\WebServices\RPCStyle\src\com\farhan\ws 

wsdl file: enter image description here

+7
java wsdl web-services
source share
1 answer

The wsimport command is wsimport from the working directory, the path of which contains space characters ( Program Files ). This is a likely source of problems for generating code (JAXB binding objects, WS fragments) in wsimport .

If the output folders for the generated files are not explicitly specified using the -d or -s options, the current working directory will be used as the default value. It seems that wsimport does not surround the directory parameter in quotation marks when it internally invokes the JAX-WS / JAXB code generation tools.

To fix the problem, you can run this command from a directory that does not have a space in the path. You also need to surround the path to wsimport quotation marks when invoking the command:

 cd C:\temp "C:\Program Files\Java\jdk1.8.0_25\bin\wsimport" -keep http://localhost:9999/ws/hello?wsdl 
+11
source share

All Articles