1 / 23

Web Services

Web Services. Members Troy Tony Ellen Vincent. Web Services. What is it Why is it useful What have been solved Demo Alternative technologies Question. What is Web Service.

charo
Télécharger la présentation

Web Services

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. Web Services Members Troy Tony Ellen Vincent

  2. Web Services • What is it • Why is it useful • What have been solved • Demo • Alternative technologies • Question

  3. What is Web Service • An XML technology which allows an application to access a remote/local application’s services with very little code customization using ubiquitous and standard communication protocols. • Standard Package: • WSDL • UDDI • SOAP

  4. How Does It Work?

  5. How Does It Work?

  6. Why Web Service Useful • “you can exchange data between different applications and different platforms” (quoted from W3Schools.com) for the following reasons: • It is platform independent • It is language independent • It uses one of the most popular ways for data communication – XML • Enabling the reuse of software components • Delivers a loosely coupled architecture (e.g. SOA)

  7. What have been solved? • Technical point of view: Platforms / development languages conflict • Business point of view: enabling data exchange among different business partners while each one of them may use different types of servers/languages

  8. Web Service in the Real World • LiveJournal - Blog Management • Google Map / Geocoding • PayPal • Protein Data Bank

  9. Limitations of Web Service • Draw Back: • Once implemented, no control in response time of the service • XML (SOAP, WSDL) is easy for human (programmers) to read but have poor processing performance • Have no way to know how the clients will use the result from the web service. This limits the type of the data analysis/mining that can be performed.

  10. Demo • Python (install fpconst, SOAPpy) • Perl

  11. Web Services Demo Perl use SOAP::Transport::HTTP; use strict; SOAP::Transport::HTTP::CGI -> dispatch_to(‘Lottery') -> handle; package Lottery; sub lotteryNumbers { my ( $val, $seed) = @_; $seed ? srand $seed : srand; my @pools = ( 1 .. 49 ); my @numbers; while ( @numbers < 6 ) { my $n = int rand @pools; ( $pools[0], $pools[$n] ) = ( $pools[$n], $pools[0] ); push @numbers, shift @pools; } return (@numbers); } Python import SOAPpy import random server = SOAPpy.SOAPServer(('localhost', 8080)) server.registerFunction(numberGenerator) def numberGenerator(): list = range(1,50) lo_nums = [] i = 0 while i < 6: number = random.choice(list) if (number != -1): lo_nums = lo_nums + [number] list[number-1] = -1 i = i + 1 return lo_nums server.serve_forever() Link to Demo

  12. Alternative Technologies • MQ Series (from IBM) • Multi-platform and multi-language message queuing service • Asynchronus • One program queues messages • Another program processes messages • Managed by a Queue Manager; actions are event triggered • Two types of queue connections (called channels) • 1) Unidirectional and 2) Bidirectional • Applications can be loosely coupled with MQ Series but they must be contained within a cooperating system since connections are pre-established and static.

  13. Alternative Technologies

  14. Alternative Technologies • MQ Series (continued) • Strengths • Support for multiple platforms • Well tested and generally considered stable • Simplifies inter-application communications • Workflow management and load balancing • Queuing • Weaknesses • Message based rather than object based • Not stateful or persistent • Hard wired channels (communication links between apps) • Location is not transparent requiring more management

  15. Alternative Technologies • CORBA (Common Object Request Broker Architecture) • Platform and language independent • Object oriented component architecture • Stateful & persistent • Flexible features to decouple the client and object implementation • Performance is good enough for real-time applications • Support for transactions, security and events notification. • E.g. Linux Gnome – a network centric graphical user interface.

  16. Alternative Technologies

  17. Alternative Technologies • CORBA (continued) • Stengths • Platform independent (as long as there is vendor support) with multi-language support • Stateful and persistent objects • Widely deployed today • Integrated security services including its own naming service that minimizes the risk of spoofing, etc. • Service discovery • Weaknesses • Fairly complex to configure and implement • Not standardized for today’s network security issues. • Not organized for easy integration with web apps

  18. Alternative Technologies • DCOM (Distributed Components) • Object oriented • Objects are stateful, persistent, can pass data, event driven, … • Seamlessly connects local and remote COM objects into a running process (e.g. transparent use of remote objects) • Tightly interacts with ActiveX for web deployment and OLE. • Primarily Windows. • Microsoft support for MacOS and third party support for some UNIX (although UNIX COM not supported by developers thus very limited services) • Early issues regarding security, complexity, load balancing and others making it unsuitable for enterprise deployment. • COM+ and Microsoft Transaction Server (MTS) attempted to fix

  19. Alternative Technologies • COM Object Access

  20. Alternative Technologies • COM (continued) • Strengths • Multi-language support (kind of) • It doesn’t care where the object is sourced from • Statefulness, persistence, native data transfer and event capabilities (e.g. exceptions) • Relatively mature technology • Weaknesses • Platform dependent (platform must understand binary format) • Supports COM-aware languages only • Considered by many complex to develop and maintain

  21. Our Comments • What is cool… Troy: “Loosely coupled architecture” Vincent: “Free” Tony: “Code Reuse” Ellen: “Compatible”

  22. References http://www-128.ibm.com/developerworks/websphere/library/techarticles/0202_balani/balani.html http://www.sei.cmu.edu/str/descriptions/com.html http://www-128.ibm.com/developerworks/webservices/library/ws-exploring-corba/ http://www2002.org/CDROM/alternate/395/ http://www.cs.wustl.edu/~schmidt/corba-overview.html

  23. Questions?

More Related