1 / 17

CSE 636 Data Integration

CSE 636 Data Integration. Web Services. What is a Web Service. A web service is a network accessible interface to application functionality Application interoperability across different platforms Built using standard Internet technologies

kylar
Download Presentation

CSE 636 Data Integration

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CSE 636Data Integration Web Services

  2. What is a Web Service • A web service is a network accessible interface to application functionality • Application interoperability across different platforms • Built using standard Internet technologies • Clients of web services do NOTneed to know how they are implemented Network Web Service   Application Client Application Code

  3. Web Services Related Standards • Web Services Description Language (WSDL) 1.1 • http://www.w3.org/TR/wsdl (03/01) • Version 2.0 under development • Simple Object Access Protocol (SOAP) • http://www.w3.org/TR/soap/ • Universal Description, Discovery and Integration (UDDI) • http://www.uddi.org/

  4. Web Service Technology Stack Web Service Client Discovery Shopping web service? UDDI WSDL URIs Web Service Description WSDL WSDL SOAP/HTTP request Proxy Messaging SOAP/HTTP response Transport HyperText Transfer Protocol (HTTP)

  5. Part 1: Web Service Methods Web Service Client Discovery Shopping web service? UDDI WSDL URIs Web Service Description WSDL WSDL SOAP/HTTP request Proxy Messaging SOAP/HTTP response Transport HyperText Transfer Protocol (HTTP)

  6. Part 2: Web Service Description Web Service Client Discovery Shopping web service? UDDI WSDL URIs Web Service Description WSDL WSDL SOAP/HTTP request Proxy Messaging SOAP/HTTP response Transport HyperText Transfer Protocol (HTTP)

  7. Part 3: Proxy to Access Web Service Web Service Client Discovery Shopping web service? UDDI WSDL URIs Web Service Description WSDL WSDL SOAP/HTTP request Proxy Messaging SOAP/HTTP response Transport HyperText Transfer Protocol (HTTP)

  8. Part 4: Client to Invoke Proxy Web Service Client Discovery Shopping web service? UDDI WSDL URIs Web Service Description WSDL WSDL SOAP/HTTP request Proxy Messaging SOAP/HTTP response Transport HyperText Transfer Protocol (HTTP)

  9. Data Services Architecture Web Application Server Web Service Web Service Client WSDL WSDL Parameterized XQuery Expressions ParameterInstantiation SOAP/HTTP request SOAP/HTTP response QueryResult QueryExecution XML Database XML Schema XML File

  10. Web Services Definition Language (WSDL) • Defines services as collections of network endpoints • Consists of abstract definitions • Types • Messages • Port Types & Operations • and concrete implementations • Bindings • Services & Ports • Broken into pieces for reuse purposes

  11. Port Types & Operations Port Type: An abstract set of operations supported Operation: An abstract description of an action supported <portTypename="AddressBook"> <operationname="addEntry"> <inputmessage="tns:AddEntryRequest"/> <outputmessage="tns:empty"/> </operation> <operationname="getAddressFromName"> <inputmessage="tns:GetAddressFromNameRequest"/> <outputmessage="tns:GetAddressFromNameResponse"/> </operation> </portType> • Programming languages refer to a port type as a class, and to an operation as a method

  12. Messages • Abstract, typed definitions of the data being communicated <messagename="empty"/> <messagename="AddEntryRequest"> <partname="address" type="tns:address"/> </message> <messagename="GetAddressFromNameRequest"> <partname="name" element="tns:entryName"/> </message> <messagename="GetAddressFromNameResponse"> <partname="address" type="tns:address"/> </message>

  13. Types • Data type definitions using the XML Schema type system <types> <xs:schematargetNamespace="urn:AddressFetcher" xmlns:xs="http://www.w3.org/1999/XMLSchema"> <xs:elementname="entryName" type="xs:string"/> <xs:complexTypename="address"> <xs:all> <xs:elementname="streetNum" type="xs:int"/> <xs:elementname="streetName" type="xs:string"/> <xs:elementname="city" type="xs:string"/> <xs:elementname="state" type="xs:string"/> <xs:elementname="zip" type="xs:int"/> <xs:elementname="phoneNumber" type="xs:int"/> </xs:all> </xs:complexType> </xs:schema> </types>

  14. WSDL File Structure <definitionsname="urn:AddressFetcher" targetNamespace="urn:AddressFetcher" xmlns:tns="urn:AddressFetcher" xmlns:xs="http://www.w3.org/1999/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns="http://schemas.xmlsoap.org/wsdl/"> <types>…</types> <messagename="AddEntryRequest">…</message> … <portTypename="AddressBook">…</portType> <binding>…</binding> <service>…</service> </definitions> Type Definitions Message Declarations Port Type Declarations Binding Declarations Service Declaration

  15. Bindings • Concrete protocol and data format specifications for a particular port type <bindingname="AddressBookSOAPBinding" type="tns:AddressBook"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operationname="getAddressFromName"> <soap:operationsoapAction=""/> <input> <soap:bodyuse="literal"/> </input> <output> <soap:bodyuse="literal"/> </output> </operation> … </binding>

  16. Services & Ports • Port: a single endpoint defined as a combination of a binding and a network address • Service: a collection of related endpoints <service name="AddressBookService"> <portname="AddressBook" binding="tns:AddressBookSOAPBinding"> <soap:addresslocation="http://localhost:8080/axis/services/AddressBook"/> </port> </service>

  17. Not Discussed • Types of operations: • One-way: The endpoint receives a message • Request-response: The endpoint receives a message, and sends a correlated message • Solicit-response: The endpoint sends a message, and receives a correlated message • Notification: The endpoint sends a message • Alternative Bindings: • HTTP: Using GET and POST • MIME • SOAP • RPC-Style Web Services • UDDI

More Related