Web Services are an interesting new technology that is used to process XML documents and perform XML RPC techniques. Using Web Services makes it possible to build a more sophisticated distributed processing architecture that can cope with the old and the new techniques. This chapter is only the beginning; you are strongly urged to read more information about Web Services and what they offer.
Wow! You have almost made it to the end of this book. This means you have digested all of the software engineering principles and programming techniques presented. It also means that our discussion of Axis ends our discussion of programming.
The sources to the concepts presented in
this chapter are located under the directories
10.1: Define a WSDL file that corresponds to the same method and parameter signature as the calculator extensions defined in previous questions. The trick in this question is that not only should the extension be defined, but a mechanism of connecting to a specific Web Service extension implementation also has to be defined. Consider this extra trick as being some type of factory method for Web Services. The objective of the WSDL definition is to be able to use the Web Service as if it were a calculator, where a properly programmed client could assemble and execute the questions dynamically, like the calculator application currently can. The difference is that a network exists between the consumer and implementation.
10.2: Implement the WSDL file defined in question 10.1. For the time being, keep the different operations simple, like adding and subtracting.
10.3: Generate the client stubs of the WSDL file defined in question 10.1. Of all questions in the entire book, this is the trickiest. If the WSDL is properly defined, then the generated stubs should be identical to the extensions defined in the calculator application. The objective of this question is to structure the calculator application such that whenever a calculation is to be performed, the extension is dynamically retrieved.
The application will have a configuration, batch file processing, etc., that stays the same. What changes is how the implementation of the calculator operation is executed. In this question, the implementation could be local, it could be a library that needs to be defined remotely, or it could be based on a Web Service defined remotely. In the configuration file, the ability to define a factory for other Web Services is then dynamically assigned.
It is important that you
If these exercises are part of a bigger