http://tick.rem.io doc.write('console.log("start of the stream...")'); var timer = setInterval(function () { doc.write('console.log("and more...")'); }, 2000);
http://tick.rem.io doc.write('console.log("start of the stream...")'); var timer = setInterval(function () { doc.write('console.log("and more...")'); }, 2000);
var http = require('http'); var server = http.createServer(function (req, res) { res.writeHead(200, { 'content-type': 'text/html' }); res.write('console.log("start of the stream...")'); var timer = setInterval(function () { if (res.connection.writable) { // keep sending a script with logging res.write('console.log("and more...")'); } else { // else connection has closed, and we can't write anymore // so clear this interval, and *attempt* to end the response clearInterval(timer); res.end(); } }, 2000); }); server.listen(8080); http://tick.rem.io
$ npm install primus emit - named events metroplex - use redis to lookup servers & spark locations omega-supreme - allow broadcasting to server or sparks