32
Web Services Presented by Ammar M. Zerouk [email protected] - @kaptainzero

Webservice intro

Embed Size (px)

Citation preview

Page 1: Webservice intro

Web ServicesPresented by

Ammar M. Zerouk

[email protected] - @kaptainzero

Page 2: Webservice intro

•Models

••SOAP

•WSDL

•UDDI

Page 3: Webservice intro

•functionURIHTTP

API

•WWWalways-onUtility Computing

Page 4: Webservice intro

Page 5: Webservice intro

•RPCORPC(DCOM, COBRA, and JAVA RMI)

••Interoperability

•Firewall Traversal

•Complexity

Page 6: Webservice intro

Interoperability

Page 7: Webservice intro

Firewall Traversal

•COBRADCOM

•HTTP80

Page 8: Webservice intro

Complexity

•developer-friendly

•HTTPCOM, RMI, COBRA

Page 9: Webservice intro

••API

•SOAPWSDLUDDIXML

•RESTfulAPISOAP

FacebookYahooIMDB

Page 10: Webservice intro
Page 11: Webservice intro

••Service Provider

•Service Requestor•

•Service Registry•

Page 12: Webservice intro

••Publish

•Find•

•Bind•

Page 13: Webservice intro
Page 14: Webservice intro

SOAP: Simple Object Access Protocol

•SOAP•

•Platform Independent

•Language Independent

•XML

•Extensible

•W3C

Page 15: Webservice intro

SOAP: Simple Object Access Protocol

• SOAP 1.0: Microsoft, Userland, DevelopMentor.• Specific to COM and HTTP.

• SOAP 1.1: include contributions from IBM and Lotus.• Substitutable transport binding (not just HTTP).

• Substitutable language binding (e.g. java).

• Substitutable data encoding (not only ANSI).

• Completely vendor-neutral (by W3C).

• Independent of: programming language, object model, operating system, or platform.

• SOAP 1.2: w3.org “XML Protocol” working group.

Page 16: Webservice intro

SOAP

•Request and Response Messages•remote object

•SOAPenvelop•

•namespace

SOAP

Page 17: Webservice intro

• <?xml version="1.0"?>

• <soap:Envelope

• xmlns:soap="http://www.w3.org/2001/12/soap-envelope"

• soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding">

• <soap:Body xmlns:m="http://www.stock.org/stock">

• </soap:Body>

• </soap:Envelope>

SOAP

<m:GetStockPrice>

<m:StockName>IBM</m:StockName>

</m:GetStockPrice>

Message

NamespaceSOAP Envelope

SOAP Envelope

Namespace

Message

Page 18: Webservice intro

SOAP

• <?xml version="1.0"?>

• <soap:Envelope

• xmlns:soap="http://www.w3.org/2001/12/soap-envelope"

• soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding">

• <soap:Body xmlns:m="http://www.stock.org/stock">

• </soap:Body>

• </soap:Envelope>

<m:GetStockPriceResponse>

<m:Price>34.5</m:Price>

</m:GetStockPriceResponse> Message

SOAP EnvelopeResult

returned in

Body

Page 19: Webservice intro

SOAP

••Unix RPC–

•COBRA–ORB

•RMI–java

•DCOM–Windows

•SOAP

•XML

Page 20: Webservice intro

SOAP

•RPC (Remote Procedure Call)•

•SOAP•XML

••

Page 21: Webservice intro

WSDL: Web Service Description Language

•WSDL•XML

•XML

••

•implementationservice interface

Page 22: Webservice intro

WSDL

•<portType>•

•<message>•

•<types>•

•XML Schema

•<binding>•

Page 23: Webservice intro

WSDL

• <message name="getTermRequest">

• <part name="term" type="xs:string"/>

• </message>

• <message name="getTermResponse">

• <part name="value" type="xs:string"/>

• </message>

• <portType name="glossaryTerms">

• <operation name="getTerm">

• <input message="getTermRequest"/>

• <output message="getTermResponse"/>

• </operation>

• </portType>

Page 24: Webservice intro

<message name="getTermRequest">

<part name="term" type="xs:string"/>

</message>

<message name="getTermResponse">

<part name="value" type="xs:string"/>

</message>

<portType name="glossaryTerms">

<operation name="getTerm">

<input message="getTermRequest"/>

<output message="getTermResponse"/>

</operation>

</portType>

<binding type="glossaryTerms" name="b1">

<soap:binding style="document"

transport="http://schemas.xmlsoap.org/soap/http" />

<operation>

<soap:operation

soapAction="http://example.com/getTerm"/>

<input>

<soap:body use="literal"/>

</input>

<output>

<soap:body use="literal"/>

</output>

</operation>

</binding>

Binding to SOAP

Page 25: Webservice intro

UDDI: Universal Description, Discovery, and Integration

•UDDI•Directory Service

•WSDL

•UDDISOAP

•UDDI•W3CXML, HTTP, DNS

•WSDL

Page 26: Webservice intro

UDDI

•Service Registry•

•Service Provider•

•Service Requestor•Service Broker

Page 27: Webservice intro

UDDI

Page 28: Webservice intro

UDDI

•business

•business

Page 29: Webservice intro

NodesUDDI

•Internal Enterprise ApplicationUDDI•

•Firewall

•PortalUDDI•

Page 30: Webservice intro

NodesUDDI

•Partner CatalogUDDI•

•E-MarketplaceUDDI•

Page 31: Webservice intro

•RPCCOBRA

•e-Business•Security

•Transaction Management

•QOS

Page 32: Webservice intro