Chapter 5. WSDL
In Chapter 2, you saw how simple it is to create a
web service using JAX-RPC by starting with a service definition in
the form of a Java interface. Given such definitions and a
configuration file, the wscompile
and
wsdeploy
utilities can generate the Java code
necessary to link both the client and server implementations to the
underlying JAX-RPC infrastructure that ultimately creates or consumes
SOAP messages. Although this is convenient for Java developers, it is
not really acceptable to describe web services—which are
supposed to be platform- and language-independent—using the
type definition system of a programming language. The JAX-RPC book
service created in Chapter 2, for example, uses a
command-line client written in Java. In the real world, the client
might instead need to be written in VB.NET, C#, or C++, or somebody
might want to take the service definition and create an alternative
server-side implementation on a different platform, such as
Microsoft’s .NET. In both of these cases, having the
service defined in terms of Java interfaces is not particularly
helpful.
The Web Service Description Language (WSDL) is an XML vocabulary that can be used to describe web services in both a platform- and programming language-neutral fashion. Web services defined by WSDL documents are published in a registry. Programmers can then either create their own implementations of these services, or develop clients to consume them by obtaining the WSDL definition and interpreting ...
Get Java Web Services in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.