The section title has the popular and formerly official name for one of the web services that Amazon hosts. The official name is now Amazon Associates Web Service. The service in question is accessible as SOAP-based or REST-style. The service is free of charge, but it does require registration at http://affiliate-program.amazon.com/gp/associates/join. For the examples in this section, an Amazon access key (as opposed to the secret access key used to generate an authentication token) is required.
Amazon’s E-Commerce service replicates the interactive experience at the Amazon website. For example, the service supports searching for items, bidding on items and putting items up for bid, creating a shopping cart and filling it with items, and so on. The two sample clients illustrate item search.
This section examines two Java clients against the Amazon E-Commerce service. Each client is generated with Java support code from the wsimport utility introduced earlier. The difference between the two clients refines the distinction between the wrapped and unwrapped conventions.
The Java support code for the client can be generated with the command:
% wsimport -keep -p awsClient \ http://ecs.amazonaws.com/AWSECommerceService/AWSECommerceService.wsdl
Recall that the
part of the command generates a package (and, therefore, a
subdirectory) named awsClient.
The source code for the first Amazon client,
AmazonClientW, resides ...