WEB SERVICES WEB SERVICES DAVIDE ZERBINO DAVIDE ZERBINO
Dec 14, 2015
WEB SERVICESWEB SERVICES
DAVIDE ZERBINODAVIDE ZERBINO
Summary:Summary:
IntroductionIntroduction DefinitionDefinition Web Service ModelWeb Service Model Web Service ArchitectureWeb Service Architecture Web Service in actionWeb Service in action AdvantagesAdvantages Web Service Development LifecycleWeb Service Development Lifecycle ToolsTools ReferencesReferences
IntroductionIntroduction
Is accessible over the webIs accessible over the web Web services are an abbrevation for Web of ServicesWeb services are an abbrevation for Web of Services
A computer application can be thought of as a well-orchestrated set of services
Web ServicesWeb Services are a new breed of software component are a new breed of software component that is a language, platform, and location indipendentthat is a language, platform, and location indipendent
A A Software ServiceSoftware Service is a something that accepts is a something that accepts digital requests and returns digital responses e.g. C digital requests and returns digital responses e.g. C function, a Java Objectfunction, a Java Object
Distributed applications will be assembled Distributed applications will be assembled from a web of software servicesfrom a web of software services
Web ServiceWeb Service
Is registred and can be located through Is registred and can be located through a Web service registry.a Web service registry.
Communicate using XML message over Communicate using XML message over standard Web protocols.standard Web protocols.
Support loosely-coupled connections Support loosely-coupled connections between systems.between systems.
Definition of Web ServiceDefinition of Web Service
““A Web service is an interface that A Web service is an interface that describes a collection of operations that describes a collection of operations that are network-accessibile through are network-accessibile through standardized XML messaging.”standardized XML messaging.”
Heather KregerIBM Software Group
The Web Services ModelThe Web Services Model The Web service architecture is based upon the The Web service architecture is based upon the
interactionsinteractions between three roles: between three roles:
ServiceRequestor
ServiceRegistry
ServiceProvider
application that is looking for and invoking an interaction application that is looking for and invoking an interaction with a servicewith a service owner of the servicesowner of the services
searchable registry where service provider publishtheir service descriptions and where service find service
The Web Services ModelThe Web Services Model Others element are:Others element are:
ServiceRegistry
ServiceRequestor
ServiceProvider
ServiceDescription
ServiceDescription
Service
The Web Services ModelThe Web Services Model Others element are:Others element are:
ServiceDescription
ServiceDescription
Service
Contains details of the interface and implementation of the service
It is a software module deployed on the network-accessible platforms provided by the service provider
The Web Services ModelThe Web Services Model The The interactionsinteractions involve the involve the publishpublish, , findfind and and bindbind operation operation
ServiceRegistry
ServiceRequestor
ServiceProvider
Find Publish
Bind
The Web Service Stack The Web Service Stack
Network
Service Description
XML-Based Messaging
Service publication
Service Discovery
Service Flow
Sec
urit
y
Man
agem
ent
Qua
lity
of
serv
ices
HTTP, FTP, email, MQ, etc
SOAP
WSDL
UDDI
UDDI
WSFL
Standard Tecnologies Requirements
The NetworkThe Network
Web services must be network-accessible
For its ubiquity
HTTP is the standard network protocol for internet-HTTP is the standard network protocol for internet-available Web Servicesavailable Web Services
Others network protocols are SMTP, FTP and for intranet Others network protocols are SMTP, FTP and for intranet domain: MQSeries, CORBAdomain: MQSeries, CORBA
XML-based MessagingXML-based Messaging Represent the use of Represent the use of XML as the basis for the messaging as the basis for the messaging
protocolprotocol The current industry standard for XML messaging is The current industry standard for XML messaging is
SOAPSOAP IBM, Microsoft, Sun and others submitted SOAP to the IBM, Microsoft, Sun and others submitted SOAP to the
W3CW3C SOAP (Simple Object Access Protocol)SOAP (Simple Object Access Protocol)
Is a simple and lightweight XML-based mechanism for Is a simple and lightweight XML-based mechanism for exchanging structured data beetween network exchanging structured data beetween network applicationsapplications
SOAPSOAP
Lightweight communication protocolLightweight communication protocol For communication between applicationsFor communication between applications
one-way, request/response, multicast, etc..one-way, request/response, multicast, etc..
Designed to communicate via HTTPDesigned to communicate via HTTP Not tied to any component technologyNot tied to any component technology Not tied to any programming languageNot tied to any programming language Based on XMLBased on XML Simple and extensibleSimple and extensible
SOAPSOAP
SOAP consists of three parts:SOAP consists of three parts: An An envelopeenvelope that defines a framework for describing that defines a framework for describing
what is in a messagewhat is in a message A A set of encoding rulesset of encoding rules for expressing istances of for expressing istances of
application-defined data typesapplication-defined data types A convention for representing A convention for representing remote procedure calls remote procedure calls
and responsesand responses
SOAPSOAP
Network protocol
SOAP
Network protocol
SOAP
ApplicationApplication web service
Request/Response
1 234
Service Description:Service Description:From XML to Web servicesFrom XML to Web services
The service description combined with SOAP infrastructure hides details as platform, programming language from the service requestror’s application and the service provider’s Web Service
Service provider comunicates all the specifications through service description
Web service uses WSDL for base-level service description
WSDLWSDL
is an XML-based language used to define Web Services and describe how to access them
WSDL: Web Service Definition Language
Industry standard W3C
Service Implementation
Definition
Service Interface
Definition
ServicePort
BindingPortTypeMessage
Type
Discovery and Publication:Discovery and Publication:UDDIUDDI
Stands for Stands for UUniversal niversal DDescription, escription, DDiscovery and iscovery and IIntegration ntegration
Defines a way to publish and discover information Defines a way to publish and discover information about web servicesabout web services
Collaboration between Microsoft, IBM, Ariba that Collaboration between Microsoft, IBM, Ariba that resulted in the creation of web service registryresulted in the creation of web service registry
Not standardNot standard
UDDIUDDI
Defines a data structure standard for representing Defines a data structure standard for representing service description information in XMLservice description information in XML
The core component of the UDDI project is the UDDI The core component of the UDDI project is the UDDI business registrationbusiness registration, an XML file used to describe a , an XML file used to describe a business entity and its Web servicesbusiness entity and its Web services
UDDIUDDI
The UDDI Business Registry can be used at a business The UDDI Business Registry can be used at a business levellevel– To check whether a given partner has particular Web To check whether a given partner has particular Web
service interfaces.service interfaces.– To find companies in a given industry with a given To find companies in a given industry with a given
type of services.type of services.– To locate information about how a partner or To locate information about how a partner or
intended partner has exposed a Web service in order intended partner has exposed a Web service in order to learn the technical details required to interact with to learn the technical details required to interact with that servicethat service
WSFL OverviewWSFL Overview
Web Service Flow Language (WSFL) is an XML language for the description of Web Services Composition
It is possible to produce web services by composing web services Intra-enterprise web services might collaborate to Intra-enterprise web services might collaborate to
present a single Web Service Interface to the publicpresent a single Web Service Interface to the public Web services from different eneterprises might Web services from different eneterprises might
collaborate to perform business to business transactionscollaborate to perform business to business transactions Service Flow described how service-to-service Service Flow described how service-to-service
communications, collaborations and flows are performed.communications, collaborations and flows are performed.
Web Service in Action: B2BWeb Service in Action: B2B
Customer
Supplier Credit Bureau
Warehouse Check validity Service
Account Service
AdvantagesAdvantages InteroperabilityInteroperability::
Any web services can interact with any other web Any web services can interact with any other web serviceservice
UbiquityUbiquity:: Web services communicate using HTTP and XML.Web services communicate using HTTP and XML.
Low Barrier to EntryLow Barrier to Entry:: The concepts behind web services are easy to The concepts behind web services are easy to
understand and toolkits are frely available from understand and toolkits are frely available from many vendorsmany vendors
Industry SupportIndustry Support:: All the major vendor are supporting SOAP and the All the major vendor are supporting SOAP and the
surrounding web services standards surrounding web services standards
Web Services Development Web Services Development LifecycleLifecycle
The development lifecycle can have four phase:The development lifecycle can have four phase:– BUILD : BUILD :
» development and testing of the web service implementationdevelopment and testing of the web service implementation» definition of the services interface descriptiondefinition of the services interface description» definition of the service implementation descriptiondefinition of the service implementation description
– DEPLOYDEPLOY : :» publication of the services interface and service implementationpublication of the services interface and service implementation
– RUNRUN : :» The web service is available for invocationThe web service is available for invocation» The web service is fully deployed, operational and network-The web service is fully deployed, operational and network-
accessible from the services provideraccessible from the services provider» Now the service requestor can perform the find and bind Now the service requestor can perform the find and bind
operationsoperations
– MANAGE MANAGE ::» Covers ongoing management and administration of the web Covers ongoing management and administration of the web
services applicationservices application
ToolsTools
Microsoft SOAP Toolkit 2.0Microsoft SOAP Toolkit 2.0
Microsoft Visual Studio .NET and .NET FrameworkMicrosoft Visual Studio .NET and .NET Framework
Apache SOAP Toolkit and AXISApache SOAP Toolkit and AXIS
IBM Web Services ToolkitIBM Web Services Toolkit
SUN JavaTM 2 Platform, Enterprise Edition (J2EE)SUN JavaTM 2 Platform, Enterprise Edition (J2EE)
Example:Example:Airport Weather ServiceAirport Weather Service
Interface:getLocation()getWind()getTemperature()getSky()getPressure()getHumidity()getSummary()
More informations:Web Interface:
http://live.capescience.com/AirportWeather/index.html
Airport Weather
ReferencesReferences
About SOAP :About SOAP :
http://www.w3c.org/TR/soaphttp://www.w3c.org/TR/soap About WSDL :About WSDL :
http://www.w3c.org/TR/wsdlhttp://www.w3c.org/TR/wsdl About UDDI :About UDDI :
http://www.uddi.orghttp://www.uddi.org About WSFL :About WSFL :
http://www.ibm.com/software/http://www.ibm.com/software/webserviceswebservices
Other PapersOther Papers
About Web service ArchitectureAbout Web service Architecture:: Web Services Conceptual Architecture (WSCA Web Services Conceptual Architecture (WSCA
1.0) -Heather Kreger - IBM SW Group1.0) -Heather Kreger - IBM SW Group About Web service development lifecycleAbout Web service development lifecycle::
Web Services Development Concepts (WSDC Web Services Development Concepts (WSDC 1.0) -Peter Brittenham- IBM SW Group1.0) -Peter Brittenham- IBM SW Group
About Web service modelAbout Web service model:: Web Services : Building Blocks for Distributed Web Services : Building Blocks for Distributed
System -Graham Glass -System -Graham Glass -
The EndThe End
Web Server in Action (2/2)Web Server in Action (2/2)
HTTP
WSDL
SOAP
Application
Interoperability
XMLXML
A version of HTML that allows any kind of data to be A version of HTML that allows any kind of data to be represented in a simple and portable wayrepresented in a simple and portable way
XML: eXtensible Markup LanguagesXML: eXtensible Markup Languages
<giocatore id = 212> <nome> Davide <\nome> <cognome> Zerbino <\cognome>
<\giocatore>