Presentation is loading. Please wait.

Presentation is loading. Please wait.

WSDL, UDDI, SOAP, REST: SOA Acronym Soup Matthew J. Dovey Oxford University.

Similar presentations


Presentation on theme: "WSDL, UDDI, SOAP, REST: SOA Acronym Soup Matthew J. Dovey Oxford University."— Presentation transcript:

1 WSDL, UDDI, SOAP, REST: SOA Acronym Soup Matthew J. Dovey Oxford University

2 WebService Soup: The confusion RESTSOAP WSDL UDDI WS-Addressing WSRF SOA WS-N WS-Events WS-Eventing BPEL WS-Security SAML XACML WS-I

3 Firstly… What is a WebService? Goal is interoperability between enterprises Goal is interoperability between enterprises We’re getting there but it hasn’t been an uneventful journey! We’re getting there but it hasn’t been an uneventful journey!

4 REST Representational State Transfer Representational State Transfer SRU, OpenSearch etc. are NOT REST WebServices SRU, OpenSearch etc. are NOT REST WebServices But rather “REST-like” in that they use XML and HTTP but not the underlying philosophy of REST But rather “REST-like” in that they use XML and HTTP but not the underlying philosophy of REST Underlying philosophy of mapping HTTP verbs to the Create/Retrieve/Update/Delete philosophy of APIs Underlying philosophy of mapping HTTP verbs to the Create/Retrieve/Update/Delete philosophy of APIs Discussed in a PhD thesis by Roy Fielding Discussed in a PhD thesis by Roy Fielding

5 True REST URLs are nouns, not verbs URLs are nouns, not verbs The basic API (verbs) is C.R.U.D The basic API (verbs) is C.R.U.D Create (HTTP POST) Create (HTTP POST) Retrieve (HTTP GET) [no side effects] Retrieve (HTTP GET) [no side effects] Update (HTTP PUT) Update (HTTP PUT) Delete (HTTP DELETE) Delete (HTTP DELETE)

6 SRU – REST style Noun: http://www.server/database/myResultSet Verbs: Search – create result set POST /database/myResultSet HTTP/1.1 Content-Type: text/xml; charset=utf-8 title = fish title = fish Sort – update result set PUT /database/myResultSet HTTP/1.1 Content-Type: text/xml; charset=utf-8 <sortBy>author</sortBy> Retrieve – retrieve result set GET /database/myResultSet HTTP/1.1 Content-Type: text/xml; charset=utf-8 <recordSet><startRecord>1</startRecord><endRecord>10</endRecord></recordSet> Finish – delete result set DELETE /database/myResultSet HTTP/1.1 Content-Type: text/xml; charset=utf-8

7 SOAP Originally Simple Object Access Protocol but now SOAP stands for SOAP! Originally Simple Object Access Protocol but now SOAP stands for SOAP! (Called XP for XML Protocol for a while) (Called XP for XML Protocol for a while) Originates from doing Remote Procedural Calls over XML and HTTP Originates from doing Remote Procedural Calls over XML and HTTP Microsoft initiated but moved to W3C Microsoft initiated but moved to W3C Originally a number of competitors Originally a number of competitors XML-RPC etc… XML-RPC etc…

8 Remote Procedural Style … myVar = foo(“hello world”, 6) String foo(String s, Integer i) { … return result; }

9 Remote Procedural Style … myVar = foo(“hello world”, 6) String foo(String s, Integer i) { … return result; } LAN

10 Remote Procedural Style … myVar = foo(“hello world”, 6) String foo(String s, Integer i) { … return result; } Internet

11 More SOAP … … 1.1 1.1 (dc.author exact "jones" and dc.title >= (dc.author exact "jones" and dc.title >= "smith") "smith") 1 1 10 10 info:.../mods info:.../mods </SOAP:Envelope>

12 SOAP Components SOAP:Header SOAP:Header Not well used, but designed for messaging and relaying purposes Not well used, but designed for messaging and relaying purposes e.g. telling proxies to rewrite sru:baseUrl e.g. telling proxies to rewrite sru:baseUrl SOAP:Body SOAP:Body XML payload XML payload SOAP:Faults SOAP:Faults Error conditions Error conditions

13 WSDL 1.1 Web Service Description Language Web Service Description Language Describes the SOAP Messages Describes the SOAP Messages Components Components Types Types XML representations of the types (typically XML Schema language) XML representations of the types (typically XML Schema language) e.g. searchRetrieveRequestType e.g. searchRetrieveRequestType Messages Messages XML messages built from types passed from client to server and server to client XML messages built from types passed from client to server and server to client e.g. searchRetrieveRequest, searchRetrieveResponse e.g. searchRetrieveRequest, searchRetrieveResponse portTypes portTypes Which messages are sent in which direction, and what the response is Which messages are sent in which direction, and what the response is e.g. searchRetrieveRequest is sent client to server, and a searchRetrieveResponse sent back e.g. searchRetrieveRequest is sent client to server, and a searchRetrieveResponse sent back Bindings Bindings How to encode (e.g. SOAP document/literal) How to encode (e.g. SOAP document/literal) How to transport (e.g. HTTP, SMTP) How to transport (e.g. HTTP, SMTP) Services Services Endpoint Endpoint e.g. http://voyager.loc.gov:7090/ e.g. http://voyager.loc.gov:7090/

14 Invisible WSDL String foo(String s, Integer i) {…}… myVar = foo(“hello world”, 6) … WSDL Document

15 Not so invisible WSDL WSDL not well defined/described WSDL not well defined/described The original spec uses definition by example The original spec uses definition by example Early WSDL tools highly incompatible Early WSDL tools highly incompatible Different interpretations Different interpretations e.g. when to use xsd:import; when to use wsdl:import e.g. when to use xsd:import; when to use wsdl:import Not so bad today (if using the major toolkits) Not so bad today (if using the major toolkits)

16 Early SOAP/WSDL Toolkits Issues SOAP Encoding 1 SOAP Encoding 1 rpc versus document rpc versus document RPC Style: RPC Style: String foo(String s, Integer i) Document Style Document Style Class foo { String s; Integer I; } String foobar(foo);

17 SOAP Encoding 2 – SOAP versus Literal styles Literal – just as plain XML Literal – just as plain XML<stuff>hello</stuff> 10 20 30 40 50 10 20 30 40 50 </numbers> SOAP – use particular SOAP defined XML constructs for arrays etc. SOAP – use particular SOAP defined XML constructs for arrays etc. hello hello 10 20 30 40 50 10 20 30 40 50 </numbers>

18 And it gets worse Literal:<Distance> 10 10 20 20 10 10 20 20 <Distance> SOAP Encoding: <Distance> </Distance> 10 10 20 20 </Point>

19 XML Schema Officially any XML Schema construct is valid in WSDL Officially any XML Schema construct is valid in WSDL In practice… In practice… e.g. for a long time Java tools were defined by JAX- RPC which defined a subset of valid XML Schema e.g. for a long time Java tools were defined by JAX- RPC which defined a subset of valid XML Schema e.g. in early stages of SRU the following caused headaches: e.g. in early stages of SRU the following caused headaches: xsd:positiveInteger, xsd:nonNegativeInteger etc. xsd:positiveInteger, xsd:nonNegativeInteger etc.

20 XML Schema funnies sequences and choice <sequence> </sequence> Often generates String foo; String foo; String bar; String bar;<choice> </choice> Also generates String foo; String foo; String bar; String bar; (Although will raise an exception if both are non-null at serialization)

21 Consider <choice> <sequence> </sequence></choice> Early Axis (until 2005!) generated String foo; String foo; String bar; String bar;

22 XML Schema funnies: Extension of all groups <complexType=“type1”> </complexType><complexType=“type2”> </complexType> Passes most XML parsers – but is invalid!

23 XML Schema funnies: Qualified Dublin Core case Health warning – complex XML Schema follows!!! </xs:complexType> </xs:complexType> Valid but will not get past many parsers

24 Enter WS-I Web Service Interoperability profile Web Service Interoperability profile Key components: SOAP, WSDL, UDDI Key components: SOAP, WSDL, UDDI Defines a set of rules for interoperable WebServices Defines a set of rules for interoperable WebServices e.g. use SOAP document/literal style e.g. use SOAP document/literal style Rules for wsdl:import versus xsd:import Rules for wsdl:import versus xsd:import Still defines any XML Schema as valid etc. Still defines any XML Schema as valid etc. Compliant toolsets much better at interoperating today Compliant toolsets much better at interoperating today

25 UDDI (the oft forgotten third part of WS-I) Universal Description, Discovery and Integration (of WebServices) Universal Description, Discovery and Integration (of WebServices) Provides a model of organisations and webservices Provides a model of organisations and webservices Provides a WebService API for interacting with registries of WebServices Provides a WebService API for interacting with registries of WebServices publishing, publishing, searching, searching, retrieving, retrieving, replicating, replicating, subscribing subscribing Template based searching (still issues to be resolved) Template based searching (still issues to be resolved) Not well used outside of enterprise due to out of band contractual negotiations needed for inter-enterprise web services Not well used outside of enterprise due to out of band contractual negotiations needed for inter-enterprise web services Poor open source implementations for version 3.0 Poor open source implementations for version 3.0

26 And the rest WSDL 2.0 WSDL 2.0 WS-Addressing: indirection via server EPR (End Point References) WS-Addressing: indirection via server EPR (End Point References) WS-N, WS-Events, WS-Evening: Notification publish/subscribe WS-N, WS-Events, WS-Evening: Notification publish/subscribe BPEL: WebService Workflow/Choreography BPEL: WebService Workflow/Choreography WSRF: Representing resources through WebServices WSRF: Representing resources through WebServices WS-Security: SAML, XACML, etc. for encryption, signing/validation and credential delegation WS-Security: SAML, XACML, etc. for encryption, signing/validation and credential delegation ebXML-BP, OWL-S, Semantic Framework etc. for policy/contractural negotiations ebXML-BP, OWL-S, Semantic Framework etc. for policy/contractural negotiations etc… etc… Compatibility declines as you go further up the stack… Compatibility declines as you go further up the stack… Straying from WS-I can be dangerous Straying from WS-I can be dangerous

27 And finally retro-fitting Service Oriented Architecture Reference Model Service Oriented Architecture Reference Model Attempting to retro fit a definition onto SOA Attempting to retro fit a definition onto SOA Service Oriented Architecture Blueprints Service Oriented Architecture Blueprints Attempting to retro fit a methodology Attempting to retro fit a methodology

28 Last word Interoperability of WebServices have been a difficult road Interoperability of WebServices have been a difficult road For more complex tasks (security, messaging, asynchronous etc.) there is still some difficulties ahead For more complex tasks (security, messaging, asynchronous etc.) there is still some difficulties ahead But we do have interoperability at the basic level and it is getting better But we do have interoperability at the basic level and it is getting better


Download ppt "WSDL, UDDI, SOAP, REST: SOA Acronym Soup Matthew J. Dovey Oxford University."

Similar presentations


Ads by Google