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

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 static
Octocat-spinner-32 .gitignore
Octocat-spinner-32 LICENCE
Octocat-spinner-32 Makefile
Octocat-spinner-32 README.md
Octocat-spinner-32 index.js
Octocat-spinner-32 package.json
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.