Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[fix] remove and replace example server
  • Loading branch information
jcrugzz committed Apr 9, 2014
1 parent eaa7646 commit 2334cb1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 32 deletions.
26 changes: 6 additions & 20 deletions example/server.js
@@ -1,26 +1,12 @@
/*
* server.js :: An example server with fun reactor things happening
*
* (C) 2013 Nodejits Inc.
*
*/

var godot = require('../lib/godot'),
expire = godot.reactor().expire(5000);
var g = require('../');

//
// This example shows a way to meausre two separate clients on the same
// `reactor` using the power of the `by` reactor. It will create a new reactor
// pipe-chain for each different 'service' in this case to easily assess the
// expiration of two separate `producers`.
//
godot.createServer({
g.createServer({
type: 'tcp',
reactors: [
godot.reactor()
.by('service',
expire
.console()
)
function (socket) {
socket
.pipe(new g.console())
}
]
}).listen(1337);
12 changes: 0 additions & 12 deletions example/simple-server.js

This file was deleted.

0 comments on commit 2334cb1

Please sign in to comment.