[Opensim-dev] Node.js, anyone?

Meadhbh Hamrick (Infinity Linden) infinity at lindenlab.com
Sat Nov 28 00:33:47 UTC 2009


Yup. I'm using it to do some VWRAP tests, but not the UDP stuff.

Daniel Smith <javajoint at gmail.com> wrote:

>Am wondering if anyone in the OpenSim realm is using Node.js (server side
>JavaScript)
>to do event-based I/O:
>
>http://nodejs.org/
>
>The more I look at it, the more I see great potential in using it as a
>gateway to handle
>daabase calls, a proxy to external web sites, and much more.  It's a very
>simple means
>of writing all manner of tcp servers.  The big deal is.. no threads.. it
>doesn't block...
>(in other words.. many scripts in a sim could hit this all at once and it
>wont need
>a ton of threads waiting around for disk or network i/o, etc..)
>
>An example of a web server written with Node which responds with "Hello
>World" after waiting two seconds:
>
>var sys = require('sys'),
>   http = require('http');
>http.createServer(function (req, res) {
>  setTimeout(function () {
>    res.sendHeader(200, {'Content-Type': 'text/plain'});
>    res.sendBody('Hello World');
>    res.finish();
>  }, 2000);
>}).listen(8000);
>sys.puts('Server running at http://127.0.0.1:8000/');
>
>Just some food for thought!
>
>cheers,
>
>Daniel
>
>
>
>
>-- 
>Daniel Smith - Sonoma County, California
>http://daniel.org/resume
>_______________________________________________
>Opensim-dev mailing list
>Opensim-dev at lists.berlios.de
>https://lists.berlios.de/mailman/listinfo/opensim-dev


More information about the Opensim-dev mailing list