Lets Begin
- <- Me
Lets Begin
- <- Me
- About You
- eXtensible Messaging and Presence Protocol (XMPP)
- eXtensible Messaging and Presence Protocol (XMPP)
- Asynchronous Real-Time Messaging
- eXtensible Messaging and Presence Protocol (XMPP)
- Asynchronous Real-Time Messaging
- Snippets of XML
- eXtensible Messaging and Presence Protocol (XMPP)
- Asynchronous Real-Time Messaging
- Snippets of XML
- Jabber
- Open Protocol - RFC 3920, 3921
- Open Protocol - RFC 3920, 3921
- XEP - XMPP Extension Protocols
- Open Protocol - RFC 3920, 3921
- XEP - XMPP Extension Protocols
- http://xmpp.org/extensions/
- Decentralized (federated)
- Strong security (tls)
- Open Protocol - RFC 3920, 3921
- XEP - XMPP Extension Protocols
- http://xmpp.org/extensions/
- Decentralized (federated)
- Strong security (tls)
- Open Source
- Open Protocol - RFC 3920, 3921
- XEP - XMPP Extension Protocols
- http://xmpp.org/extensions/
- Decentralized (federated)
- Strong security (tls)
- Open Source
- Open Community
XMPP Architecture
- client to server
- server to server
What can you do with XMPP?
What can you do with XMPP?
- Instant Messaging
- Google Talk, Facebook, Apple, Many others
What can you do with XMPP?
What can you do with XMPP?
- Mobile Apps/Geolocation
- Buddycloud, Cabulous, Others
What can you do with XMPP?
- Video Conferencing, Shared Editing, Whiteboards
What can you do with XMPP?
- Video Conferencing, Shared Editing, Whiteboards
- Google, others
What can you do with XMPP?
What can you do with XMPP?
- Games
- Chesspark, id Software, others
What can you do with XMPP?
- Real-time Web Applications
What can you do with XMPP?
- Real-time Web Applications
- Insert Your Idea
What can you do with XMPP?
- Real-time Web Applications
- Insert Your Idea
- This presentation!
XMPP Addressing
- JID - Jabber IDentifier
- tofu@thetofu.com/presentation
XMPP Addressing
- JID - Jabber IDentifier
- tofu@thetofu.com/presentation
XMPP Addressing
- JID - Jabber IDentifier
- tofu@thetofu.com/presentation
XMPP Addressing
- JID - Jabber IDentifier
- tofu@thetofu.com/presentation
XMPP Protocol
- XML
- XML Streams
- <message/>
XMPP Protocol
- XML
- XML Streams
- <message/>
- <presence/>
XMPP Protocol
- XML
- XML Streams
- <message/>
- <presence/>
- <iq/>
Streaming XML
SEND: <?xml version='1.0'?>
<stream:stream xmlns='jabber:client'
xmlns:stream='http://etherx.jabber.org/streams'
from='thetofu.com'
version='1.0'>
RECV: <?xml version='1.0'?>
<stream:stream xmlns='jabber:client'
xmlns:stream='http://etherx.jabber.org/streams'
id='1'
from='thetofu.com'
version='1.0'>
SEND: </stream:stream>
RECV: </stream:stream>
presence
<presence type="away" >
<show>away</show>
<status>Talking at Posscon</status>
</presence>
presence
<presence type="away" >
<show>away</show>
<status>Talking at Posscon</status>
</presence>
presence
<presence type="away" >
<show>away</show>
<status>Talking at Posscon</status>
</presence>
presence
<presence type="away" >
<show>away</show>
<status>Talking at Posscon</status>
</presence>
message
<message to="tofu@thetofu.com" type="chat" >
<body>This is an example<body>
</message>
message
<message to="tofu@thetofu.com" type="chat" >
<body>This is an example<body>
</message>
message
<message to="tofu@thetofu.com" type="chat" >
<body>This is an example<body>
</message>
message
<message to="tofu@thetofu.com" type="chat" >
<body>This is an example<body>
</message>
iq
<iq
xmlns="jabber:client"
to="thetofu.com"
type="get"
id="4445" >
<query
xmlns="http://jabber.org/protocol/disco#items" />
</iq>
iq
<iq
xmlns="jabber:client"
to="thetofu.com"
type="get"
id="4445" >
<query xmlns="http://jabber.org/protocol/disco#items" />
</iq>
iq
<iq
xmlns="jabber:client"
to="thetofu.com"
type="get"
id="4445" >
<query xmlns="http://jabber.org/protocol/disco#items" />
</iq>
iq
<iq
xmlns="jabber:client"
to="thetofu.com"
type="get"
id="4445" >
<query xmlns="http://jabber.org/protocol/disco#items" />
</iq>
iq
<iq
xmlns="jabber:client"
to="thetofu.com"
type="get"
id="4445">
<query xmlns="http://jabber.org/protocol/disco#items" />
</iq>
XMPP and the Web
- HTPP APIs are good
- Polling sucks
XMPP and the Web
- HTPP APIs are good
- Polling sucks
- BOSH - Bidirectional-streams Over Synchronous HTTP
XMPP and the Web
- HTPP APIs are good
- Polling sucks
- BOSH - Bidirectional-streams Over Synchronous HTTP
- XMPP Over BOSH
How does this work?
- HTML, CSS, Javascript
- s5 - HTML Simple Slide Show
How does this work?
- HTML, CSS, Javascript
- s5 - HTML Simple Slide Show
- PubSub
How does this work?
- HTML, CSS, Javascript
- s5 - HTML Simple Slide Show
- PubSub
- BOSH
How does this work?
- HTML, CSS, Javascript
- s5 - HTML Simple Slide Show
- PubSub
- BOSH
- Strophe.js