1/ november 2008 / eds internal web push technology dušan chromý soa integration consulting...
Post on 19-Dec-2015
216 views
TRANSCRIPT
1 / November 2008 / EDS Internal
Web Push Technology
Dušan Chromý
SOA Integration Consulting
Reverse Ajax/Comet Explained
2 / November 2008 / EDS InternalWeb Push Technology
Agenda
•Why Comet, first?
•How to Comet?
•Relation to Ajax
•Comet by Example: ODI Showcase
3 / November 2008 / EDS InternalWeb Push Technology
Why Comet?
•The web interaction model is characterized by a client requesting information from the web server– Even Ajax, however novel, follows this model
•A web server cannot choose when to send updated information to a web browser– This makes development of a whole class of applications
difficult for the web, including:• Stock Price Tickers (and event monitoring applications in
general)• Chat & Instant Messaging• Online Multiplayer Games• Online Collaboration
•How to notify the web browser timely of server events?– Frequent polling used to be the only option…before Comet
The Challenge
4 / November 2008 / EDS InternalWeb Push Technology
How to Comet?
1. HTTP Streaming• Never-ending stream of JavaScript tags
2. Long Polling• Slowly answered server request• via XMLHttpRequest or dynamic script tag• “Hang on - I’ll see if I have news for you”
3. HTML5 Server-Sent Events• HTTP Streaming standardized, cleaned
4. HTML5 WebSocket• Brave new upgrade of the HTTP protocol
The Approaches
5 / November 2008 / EDS InternalWeb Push Technology
•Comet is to Ajax as– Java is to .NET
– Audi is to Mercedes
– Coke is to Pepsi
•The name “Comet” is a play on “Ajax”
•Both Ajax and Comet are umbrella terms for groups of techniques addressing different needs– Ajax enables interactive web applications
– Comet enables web applications to receive events from the server
•The Comet concept is known by several other names– Ajax Push, Reverse Ajax, Two-way-web, and others
Relation to Ajax
6 / November 2008 / EDS InternalWeb Push Technology
Comet by Example: ODI Showcase
•The Showcase lets the user submit a file to ODI through a web page and shows the progress of the running ODI process
•Server-side Technology– ODI sends JMS progress messages
– Java Servlet delivers the messages to the client
– Oracle ADF Faces web application with JSP display technology
•Client-side Technology– Dojo Toolkit to simplify JavaScript development
•Let’s see it in action!
7 / November 2008 / EDS InternalWeb Push Technology
Links and References
(1) Wikipedia: Comet
(2) http://cometdaily.com
(3) XML.com: JSON Dynamic Script Tags
(4) Opera Labs: Server-Sent Events
(5) My Tech Rantings: HTML5 WebSocket
8 / November 2008 / EDS InternalWeb Push Technology
EDS and the EDS logo are registered trademarks of Electronic Data Systems Corporation. EDS is an equal opportunity employer and values the diversity of its people. © 2007 Electronic Data Systems Corporation. All rights reserved.
Dušan Chromý SOA Integration ConsultingEDS Operations Services GmbH Eisenstraße 56 65428 Rüsselsheim Germany Phone:+49-(0)6142 80 5431 mailto:[email protected]