WebSockets
Dimuthu Nilanka
Software Developer
ISM APAC
ISM APAC TechTalks
What is the WebSockets?
WebSocket is...
● a new feature introduce with HTML5.
● a protocol providing full-duplex communications
channels over a si...
Early days of the Internet?
Internet was so boring like this :)
Early days of the Internet?
What made the Internet more dynamic?
● around 2005 Ajax make it more dynamic.
● but it needed user interaction or periodic...
Little more details about
WebSockets
WebSocket more info...
● Client request:
GET /chat HTTP/1.1
Host: server.example.com
Upgrade: websocket
Connection: Upgrad...
Real world usage of WebSockets
● Chat applications
● Multi-player online games
● Real time tracking and updates
● Collabor...
A really simple demo
● A Mouse tracking demo
● Based on Node.js and Socket.IO
● Download the demo:
https://github.com/dimu...
Other WebSocket implementations
● .NET – SuperWebSocket (http://superwebsocket.codeplex.com/)
● Java – Jetty (http://www.e...
Questions / any comments ?
References
● http://en.wikipedia.org/wiki/WebSocket
● http://www.html5rocks.com/en/tutorials/websockets/basics/
● http://w...
Thank you!
ISM APAC TechTalk - WebSockets Presentation
Upcoming SlideShare
Loading in...5
×

ISM APAC TechTalk - WebSockets Presentation

240

Published on

ISM APAC TechTalk - WebSockets Presentation

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
240
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
3
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

ISM APAC TechTalk - WebSockets Presentation

  1. 1. WebSockets Dimuthu Nilanka Software Developer ISM APAC ISM APAC TechTalks
  2. 2. What is the WebSockets?
  3. 3. WebSocket is... ● a new feature introduce with HTML5. ● a protocol providing full-duplex communications channels over a single TCP connection. ● still being standardized by the W3C. ● implemented on Chrome 14, Firefox 6, Safari 6, Opera 12.10, Internet Explorer 10 and above.
  4. 4. Early days of the Internet?
  5. 5. Internet was so boring like this :) Early days of the Internet?
  6. 6. What made the Internet more dynamic? ● around 2005 Ajax make it more dynamic. ● but it needed user interaction or periodic polling to load new data. ● comet – was around since 2000 but was not so popular. ● around 2006 it's become more popular and used by gmail, AOL, yahoo and Microsoft. ● disadvantages and more info about Comet: http://www.ibm.com/developerworks/library/wa-reverseajax1/
  7. 7. Little more details about WebSockets
  8. 8. WebSocket more info... ● Client request: GET /chat HTTP/1.1 Host: server.example.com Upgrade: websocket Connection: Upgrade Sec-WebSocket-Key: x3JJHMbDL1EzLkh9GBhXDw== Sec-WebSocket-Protocol: chat, superchat Sec-WebSocket-Version: 13 Origin: http://example.com ● Server response: HTTP/1.1 101 Switching Protocols Upgrade: websocket Connection: Upgrade Sec-WebSocket-Accept: HSmrc0sMlYUkAGmm5OPpG2HaGWk= Sec-WebSocket-Protocol: chat ● Has introduce new url scheme ws:// and wss:// ● Work well with proxies and firewalls
  9. 9. Real world usage of WebSockets ● Chat applications ● Multi-player online games ● Real time tracking and updates ● Collaborative editing
  10. 10. A really simple demo ● A Mouse tracking demo ● Based on Node.js and Socket.IO ● Download the demo: https://github.com/dimuthu/websockets-demo.git
  11. 11. Other WebSocket implementations ● .NET – SuperWebSocket (http://superwebsocket.codeplex.com/) ● Java – Jetty (http://www.eclipse.org/jetty/) ● C++ - libwebsockets (http://git.warmcat.com/cgi-bin/cgit/libwebsockets/) ● Python – pywebsocket and Tornado (http://code.google.com/p/pywebsocket/ and https://github.com/tornadoweb/tornado)
  12. 12. Questions / any comments ?
  13. 13. References ● http://en.wikipedia.org/wiki/WebSocket ● http://www.html5rocks.com/en/tutorials/websockets/basics/ ● http://www.websocket.org/aboutwebsocket.html ● http://socket.io/
  14. 14. Thank you!
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×