wood burning stoves 2.0*
The moose likes Web Services and the fly likes WSimport of Amazon Webservices Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "WSimport of Amazon Webservices" Watch "WSimport of Amazon Webservices" New topic
Author

WSimport of Amazon Webservices

yogesh.lr kumar
Greenhorn

Joined: Jul 15, 2008
Posts: 18
Hello,

I am studying Webservices up and running and trying to execute the exmaples which involve Amazon's e-commerce webservice.
I am using the following command to import the wsdl:
java -Xmx1024M -cp "C:\Program Files\Java\jdk1.7.0_21\lib\tools.jar" com.sun.tools.internal.ws.WsImport -keep -p awsClient / http://ecs.amazonaws.com/AWSECommerceService/AWSECommerceService.wsdl

but when i execute the command i get the following error:
parsing WSDL...


[ERROR] com.sun.istack.internal.SAXParseException2; ecs.amazonaws.com

Failed to read the WSDL document: http://ecs.amazonaws.com/AWSECommerceService/A
WSECommerceService.wsdl, because 1) could not find the document; /2) the documen
t could not be read; 3) the root element of the document is not <wsdl:definition
s>.


[ERROR] duplicate "message" entity: "CreatePartyRequest"
line 232 of file:/C:/Documents%20and%20Settings/***/****/****/wsdl/Party.wsdl
This is the wsdl folder of another project on my computer.

The project is not even loaded in Eclipse when i am executing the command.

Can someone please help me to get rid of this error message.

Thanks.
yogesh.lr kumar
Greenhorn

Joined: Jul 15, 2008
Posts: 18
Can someone please provide a response , i still dont have any luck after trying few options.
Steven Taylor
Greenhorn

Joined: Nov 24, 2008
Posts: 2
I am able to generate the code using the below command

wsimport -d c:\ws http://ecs.amazonaws.com/AWSECommerceService/AWSECommerceService.wsdl
yogesh.lr kumar
Greenhorn

Joined: Jul 15, 2008
Posts: 18
Steven Taylor wrote:I am able to generate the code using the below command

wsimport -d c:\ws http://ecs.amazonaws.com/AWSECommerceService/AWSECommerceService.wsdl


Thanks for the response Steve, but my issue is the command is searching for other wsdls that are present on my machine and thorwing the above error
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41601
    
  55
Have you actually tried the command Steven posted? It's quite different from what you did.


Ping & DNS - my free Android networking tools app
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: WSimport of Amazon Webservices