Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Alpha chat app using streams for communication

branch: master

updated links

latest commit c7f700e8a6
Raynos (Jake Verbaten) authored August 18, 2012
Octocat-spinner-32 static docs August 18, 2012
Octocat-spinner-32 .gitignore first August 03, 2012
Octocat-spinner-32 LICENCE first August 03, 2012
Octocat-spinner-32 Makefile docs August 18, 2012
Octocat-spinner-32 README.md updated links August 18, 2012
Octocat-spinner-32 index.js docs August 18, 2012
Octocat-spinner-32 package.json docs August 18, 2012
README.md

stream-chat

A chat app using streams

Live at: http://raynos.stream-chat.jit.su/

The interesting bits

Demonstrates usage of using discoverynetwork.co to build distributed apps

The server is a static file server

Distributed peer to peer apps are served from static file servers and use a discovery network in the cloud to establish peer to peer connections (through a relay server due to browser limitations)

Connections to the discovery network

Open a connection to a cloud based discovery network. Then simply discover your peers and open connections to them

Open relay streams to a named relay network

Once you have a connection to the discovery network you can open a fresh named connection to a relay network. Each relay network has a unique name and only contains the peers attached to that unique name.

Manipulate direct stream connections to peers

When a peer enters the network you get a direct stream connection to him. Now just talk to him!

Your UI component is a stream

If your UI component is a stream then you can pipe it directly to another peer. Once you get data from that peer simply render it. If you have data to send to the peer simply emit it.

Start building distributed apps on the cloud today!

Contributors

  • Raynos

MIT Licenced

Something went wrong with that request. Please try again.