Published on

  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide


  1. 1. Introduction to Web Services Bina Ramamurthy [email_address] This work is partially supported by NSF-DUE-CCLI-A&I Grant 0311473
  2. 2. Topics for Discussion <ul><li>Webservices and Service Oriented Architectures (SOA) </li></ul><ul><li>XML (eXtensible Markup Language) </li></ul><ul><li>SOAP (Simple Object Access Protocol) </li></ul><ul><li>WS (Web Services) </li></ul><ul><li>Summary </li></ul>
  3. 3. Web Services and SOA <ul><li>Web Services is a technology that allows for applications to communicate with each other in a standard format. </li></ul><ul><li>A Web Service exposes an interface that can be accessed through XML messaging. </li></ul><ul><li>A Web service uses XML based protocol to describe an operation or the data exchange with another web service. Ex: SOAP </li></ul><ul><li>A group of web services collaborating accomplish the tasks of an application. The architecture of such an application is called Service-Oriented Architecture (SOA). </li></ul>
  4. 4. SOA in Real World: Report in InfoWorld, May 2, 2005 Issue 18 <ul><li> </li></ul><ul><li>State of Massachusetts uses SOA to deliver healthcare services. With HTML web application it had no control of look and feel and handling many hospitals. With SOAP based messaging they can easily handle different systems, billing systems, medical records systems etc. Use Microsoft-based systems. </li></ul><ul><li>Countrywide financial simplifies lending: IBM Websphere based SOA is used to deliver services. </li></ul><ul><li>Guardian Life Insurance uses SOA: IBM websphere based services. Uses EJB for business logic. </li></ul><ul><li>British Telecom uses combination of BEA systems and Microsoft’s Connected Services Framework. Billing backend and operational support for the organization are web services. Legacy systems are enabled as web services. </li></ul><ul><li> provides WS API for developers to implement applications leveraging their architecture and data. </li></ul>
  5. 5. XML <ul><li>XML is a markup language, developed by W3C (World Wide Web Consortium), mainly to overcome the limitations of HTML. </li></ul><ul><li>But it took a life of its own and has become a very popular part of distributed systems. </li></ul><ul><li>We will examine its definition, associated specifications (DTD, XSLT etc.), Java APIs available to process XML, protocols and services based on XML, and the role XML plays in a distributed computing environment. </li></ul>
  6. 6. First Look at XML <ul><li>It has no predefined tags. </li></ul><ul><ul><li>Such as in HTML </li></ul></ul><ul><ul><li>Domains may specify their own set of standard tags </li></ul></ul><ul><li>It is stricter. </li></ul><ul><ul><li>Most html document have errors and the browser have to built to take care of these. </li></ul></ul><ul><ul><li>On the other hand XML has a strict syntax. </li></ul></ul><ul><ul><li>There is a notion of validity and </li></ul></ul><ul><ul><li>A notion of well-formed. </li></ul></ul>
  7. 7. An Example: Memo <ul><li>See the two documents enclosed: one in html and the other in XML formats. </li></ul><ul><li>Observe the meaningful tags in XML. </li></ul><ul><li>Compare it to a class definition: it looks like a class with data definitions and accessors (tags). </li></ul>
  8. 8. Memo.html vs memo.xml <ul><li><!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;> </li></ul><ul><li><html> </li></ul><ul><li><head> </li></ul><ul><li><meta http-equiv=&quot;content-type&quot; </li></ul><ul><li>content=&quot;text/html; charset=ISO-8859-1&quot;> </li></ul><ul><li><title>memo.html</title> </li></ul><ul><li></head> </li></ul><ul><li><body> </li></ul><ul><li><h3>Hello World</h3> </li></ul><ul><li>Bina<br> </li></ul><ul><li>CSE507 SOA and WS Students <br> </li></ul><ul><li>Wake up everyone<br> </li></ul><ul><li>BR<br> </li></ul><ul><li><br> </li></ul><ul><li></body> </li></ul><ul><li></html> </li></ul><ul><li><?xml version=&quot;1.0&quot; ?> </li></ul><ul><li>  <!DOCTYPE memo (View Source for full doctype...) > </li></ul><ul><li>- <memo> </li></ul><ul><li>  <header> Hello World </header> </li></ul><ul><li>  <from> bina </from> </li></ul><ul><li>  <to> CSE507 SOA and WS Students </to> </li></ul><ul><li>  <body> Wake up everyone </body> </li></ul><ul><li>  <sign> br </sign> </li></ul><ul><li>  </memo> </li></ul>
  9. 9. XML to SOAP <ul><li>Simple xml can facilitate sending message to receive information. </li></ul><ul><li>The message could be operations to be performed on objects. </li></ul><ul><li>Simple Object Access Protocol (SOAP) </li></ul>
  10. 10. SOAP Request <soap:Envelope xmlns:soap=&quot;;> <soap:Body> <getProductDetails xmlns=&quot;;> <productId>827635</productId> </getProductDetails> </soap:Body> </soap:Envelope>
  11. 11. SOAP Reply <soap:Envelope xmlns:soap=&quot;;> <soap:Body> <getProductDetailsResponse xmlns=&quot;;> <getProductDetailsResult> <productName>Toptimate 3-Piece Set</productName> <productId>827635</productId> <description>3-Piece luggage set. Black Polyester.</description> <price>96.50</price> <inStock>true</inStock> </getProductDetailsResult> </getProductDetailsResponse> </soap:Body> </soap:Envelope>
  12. 12. SOAP  Web Services (WS)  SOA <ul><li>Read this paper: </li></ul><ul><li> </li></ul>
  13. 13. WS Stack Network XML-based Messaging Service Description Service Publication Service Discovery Service Flow HTTP, FTP, MQ Email, IIOP SOAP WSDL UDDI UDDI WSFL Security Management Quality of Service
  14. 14. WS Interoperability Infrastructure Network XML Messaging Service Description WSDL SOAP HTTP Do you see any platform or language dependencies here?
  15. 15. Service Oriented Architectures <ul><li>Lets look at some success stories. </li></ul><ul><li> has is data collection available web services developers. </li></ul><ul><li>See these URLs: </li></ul><ul><li> E-Commerce Service ( ECS ) </li></ul><ul><ul><li>A cool application </li></ul></ul>
  16. 16. Summary <ul><li>We looked at foundational concepts supporting web services: XML, SOAP, WSDL and Web Services standards. </li></ul><ul><li>We also illustrated the concepts using sample programs. </li></ul>