简体   繁体   中英

Java WS - Creating client stub using wsimport

I am trying to generate a sample stub by using a open WS URL http://www.webservicex.net/geoipservice.asmx?WSDL

When I try to run the wsimport I get below error

[DEBUG] Authorization file "C:\Users\User Name\\.metro\auth" not
found.

I tried the suggestion from following link How can I use wsimport to generate a webservice client which wsdl requires authentication?

but could not create the folder .metro as it is not a valid name.

How do I generate the stub or create this folder ?

You should download the wsdl and run wsimport on it.

If the wsdl has a WS policy that requires authentication, comment these ws policy elements out to simply generate the wsdl.

You can also test with tools eg soapUI.

BTW what web service framework are you using?

For creating folder with name starting with "." like ".metro" actually name it as ".metro." ( one "." extra in the end), then it will be created. Works for windows 7

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