Java Reference
In-Depth Information
ment,adigitizedvideo,awebpage,orevenanapplication.Theseresourcescan
be accessed via standard Internet protocols (e.g., HTTP or SMTP).
Service : A server-based application or software component that exposes a re-
source to clients via an exchange of messages according to a message ex-
change pattern (MEP)—see http://en.wikipedia.org/wiki/Mes-
sage_Exchange_Pattern . The request-response MEP is typical.
Giventhesedefinitions,wecandefine web service asaserver-basedapplication/soft-
warecomponentthatexposesaWeb-basedresourcetoclientsviaanexchangeofmes-
sages. These messages may or may not be based on XML, and can be thought of as
invokingwebservicefunctionsandreceivinginvocationresults. Figure11-1 illustrates
this message exchange.
Figure 11-1. A client exchanges messages with a web service to access a resource.
Note Web services are an implementation of Service-Oriented Architecture (SOA)
—see http://www.xml.com/lpt/a/1292 . Think of SOA as a set of design
principlesoraframeworkforimplementingbusinesslogicasreusableservicesthatcan
be combined in different ways to meet evolving business requirements. SOA is con-
cerned with specification and is not concerned with implementation.
Webservicescanbeclassifiedassimpleorcomplex.Simplewebservicesdon'tinter-
act with other web services; for example, a standalone server-based application with a
singlefunctionthatreturnsthecurrenttimeforaspecifiedtimezone.Incontrast,com-
plex web services often interact with other web services. For example, a generalized
social network web service might interact with Twitter and Facebook web services to
obtainandreturntoitsclientallTwitterandallFacebookinformationforaspecificindi-
vidual.Complexwebservicesarealsoknownas mashups becausethey mash (combine)
data from multiple web services.
THE RATIONALE FOR WEB SERVICES
Companieshavehistoricallyreliedonclient/serversystemswhereclientapplications
communicatewithserver-basedbackendsoftwarethroughserver-basedmiddleware
software sandwiched between them. Traditional middleware has been plagued by
various problems such as being expensive to obtain and maintain, being unable to
Search WWH ::




Custom Search