WSDL, UDDI, SOAP, REST: SOA Acronym Soup - PowerPoint PPT Presentation

1 / 28
About This Presentation
Title:

WSDL, UDDI, SOAP, REST: SOA Acronym Soup

Description:

Remote Procedural Style. myVar = foo('hello world', 6) String foo(String s, Integer i) ... g. use SOAP document/literal style. Rules for wsdl:import versus xsd: ... – PowerPoint PPT presentation

Number of Views:457
Avg rating:3.0/5.0
Slides: 29
Provided by: matthew168
Category:
Tags: rest | soa | soap | uddi | wsdl | acronym | soup | style

less

Transcript and Presenter's Notes

Title: WSDL, UDDI, SOAP, REST: SOA Acronym Soup


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

2
WebService Soup The confusion
WS-Addressing
WSDL
WS-Security
WS-Eventing
WS-N
XACML
REST
SOAP
WS-I
SOA
WS-Events
SAML
BPEL
UDDI
WSRF
3
Firstly
  • What is a WebService?
  • Goal is interoperability between enterprises
  • Were getting there but it hasnt been an
    uneventful journey!

4
REST
  • Representational State Transfer
  • 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
  • Underlying philosophy of mapping HTTP verbs to
    the Create/Retrieve/Update/Delete philosophy of
    APIs
  • Discussed in a PhD thesis by Roy Fielding

5
True REST
  • URLs are nouns, not verbs
  • The basic API (verbs) is C.R.U.D
  • Create (HTTP POST)
  • Retrieve (HTTP GET) no side effects
  • Update (HTTP PUT)
  • 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 charsetutf-8
  • ltquerygttitle fishlt/querygt
  • Sort update result set
  • PUT /database/myResultSet HTTP/1.1
  • Content-Type text/xml charsetutf-8
  • ltsortBygtauthorlt/sortBygt
  • Retrieve retrieve result set
  • GET /database/myResultSet HTTP/1.1
  • Content-Type text/xml charsetutf-8
  • ltrecordSetgtltstartRecordgt1lt/startRecordgtltendRecordgt
    10lt/endRecordgtlt/recordSetgt
  • Finish delete result set

7
SOAP
  • Originally Simple Object Access Protocol but now
    SOAP stands for SOAP!
  • (Called XP for XML Protocol for a while)
  • Originates from doing Remote Procedural Calls
    over XML and HTTP
  • Microsoft initiated but moved to W3C
  • Originally a number of competitors
  • 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
  • ltSOAPEnvelope xmlnsSOAP..."gt
  • ltSOAPHeadergt
  • lt/SOAPHeadergt
  • ltSOAPBodygt
  • ltSRWsearchRetrieveRequest xmlnsSRW..."gt
  • ltSRWversiongt1.1lt/SRWversiongt
  • ltSRWquerygt(dc.author exact "jones" and
    dc.title gt
  • "smith")lt/SRWquerygt
  • ltSRWstartRecordgt1lt/SRWstartRecordgt
  • ltSRWmaximumRecordsgt10lt/SRWmaximumRecordsgt
  • ltSRWrecordSchemagtinfo.../modslt/SRWrecordsS
    chemagt
  • lt/SRWsearchRetrieveRequestgt
  • lt/SOAPBodygt
  • lt/SOAPEnvelopegt

12
SOAP Components
  • SOAPHeader
  • Not well used, but designed for messaging and
    relaying purposes
  • e.g. telling proxies to rewrite srubaseUrl
  • SOAPBody
  • XML payload
  • SOAPFaults
  • Error conditions

13
WSDL 1.1
  • Web Service Description Language
  • Describes the SOAP Messages
  • Components
  • Types
  • XML representations of the types (typically XML
    Schema language)
  • e.g. searchRetrieveRequestType
  • Messages
  • XML messages built from types passed from client
    to server and server to client
  • e.g. searchRetrieveRequest, searchRetrieveResponse
  • portTypes
  • 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
  • Bindings
  • How to encode (e.g. SOAP document/literal)
  • How to transport (e.g. HTTP, SMTP)
  • Services
  • Endpoint
  • e.g. http//voyager.loc.gov7090/

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
  • The original spec uses definition by example
  • Early WSDL tools highly incompatible
  • Different interpretations
  • e.g. when to use xsdimport when to use
    wsdlimport
  • Not so bad today (if using the major toolkits)

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

17
SOAP Encoding 2 SOAP versus Literal styles
  • Literal just as plain XML
  • ltstuffgthellolt/stuffgt
  • ltnumbers"gt  ltitemgt10lt/itemgt  ltitemgt20lt/itemgt  lt
    itemgt30lt/itemgt  ltitemgt40lt/itemgt  ltitemgt50lt/itemgt
  • lt/numbersgt
  • SOAP use particular SOAP defined XML constructs
    for arrays etc.
  • ltstuff xsitypexsdstringgthellolt/stuffgt
  • ltnumbers xsitype"SOAP-ENCArray"
    SOAP-ENCarrayType"xsdinteger5"gt  ltitemgt10lt/i
    temgt  ltitemgt20lt/itemgt  ltitemgt30lt/itemgt  ltitemgt4
    0lt/itemgt  ltitemgt50lt/itemgt
  • lt/numbersgt

18
And it gets worse
  • Literal
  • ltDistancegt
  • ltp1gt
  • ltxgt10lt/xgt
  • ltygt20lt/ygt
  • lt/p1gt
  • ltp2gt
  • ltxgt10lt/xgt
  • ltygt20lt/ygt
  • lt/p2gt
  • ltDistancegt
  • SOAP Encoding
  • ltDistancegt
  • ltp1 HREF"id1"/gt
  • ltp2 HREF"id1"/gt
  • lt/Distancegt
  • ltPoint id"id1"gt
  • ltxgt10lt/xgt

19
XML Schema
  • Officially any XML Schema construct is valid in
    WSDL
  • 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. in early stages of SRU the following caused
    headaches
  • xsdpositiveInteger, xsdnonNegativeInteger etc.

20
XML Schema funniessequences and choice
  • ltsequencegt
  • ltelement namefoo typestring /gt
  • ltelement namebar typestring /gt
  • lt/sequencegt
  • Often generates
  • String foo
  • String bar
  • ltchoicegt
  • ltelement namefoo typestring /gt
  • ltelement namebar typestring /gt
  • lt/choicegt
  • Also generates
  • String foo
  • String bar
  • (Although will raise an exception if both are
    non-null at serialization)

21
Consider
  • ltchoicegt
  • ltelement namefoo typestring /gt
  • ltsequencegt
  • ltelement namefoo typestring /gt
  • ltelement namebar typestring /gt
  • lt/sequencegt
  • lt/choicegt
  • Early Axis (until 2005!) generated
  • String foo
  • String foo
  • String bar

22
XML Schema funniesExtension of all groups
  • ltcomplexTypetype1gt
  • ltcomplexContentgt
  • ltallgt
  • ltelement namefoo typestring /gt
  • ltelement namebar typestring /gt
  • ltallgt
  • lt/complexContentgt
  • lt/complexTypegt
  • ltcomplexTypetype2gt
  • ltcomplexContentgt
  • ltextension basetype2"gt
  • ltallgt
  • ltelement namefoo1 typestring /gt
  • ltelement namebar2 typestring /gt
  • ltallgt
  • lt/extensiongt
  • lt/complexContentgt
  • lt/complexTypegt

23
XML Schema funnies Qualified Dublin Core case
  • Health warning complex XML Schema follows!!!
  • ltxscomplexType name"SimpleLiteral"gt
  • ltxscomplexContent mixed"true"gt
  • ltxsrestriction base"xsanyType"gt
  • ltxssequencegt
  • ltxsany processContents"lax"
    minOccurs"0" maxOccurs"0"/gt lt/xssequencegt
  • ltxsattribute ref"xmllang"
    use"optional"/gt
  • lt/xsrestrictiongt
  • lt/xscomplexContentgt
  • lt/xscomplexTypegt
  • ltxscomplexType name"W3CDTF"gt
  • ltxssimpleContentgt
  • ltxsrestriction base"dcSimpleLiteral"gt
  • ltxssimpleTypegt
  • ltxsunion memberTypes"xsgYear
    xsgYearMonth xsdate xsdateTime"/gt
  • lt/xssimpleTypegt
  • lt/xsrestrictiongt

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

25
UDDI (the oft forgotten third part of WS-I)
  • Universal Description, Discovery and Integration
    (of WebServices)
  • Provides a model of organisations and webservices
  • Provides a WebService API for interacting with
    registries of WebServices
  • publishing,
  • searching,
  • retrieving,
  • replicating,
  • subscribing
  • 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
  • Poor open source implementations for version 3.0

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

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

28
Last word
  • Interoperability of WebServices have been a
    difficult road
  • 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
Write a Comment
User Comments (0)
About PowerShow.com