Better HN
topnewbestaskshowjobs
Log inSign up

thinknlive

4 karma · joined Apr 6, 2012 (14y ago) · 2 submissions

Submissions

comment 9y ago · link · parent

sqlite 'all the things!'. Seriously. One of the best tools ever. So many data, and related performance challenges, in almost any app can be solved efficiently with this (for what it does) tiny little library.

comment 14y ago · link · parent

// response : http response stream // filename : the static file we want to serve

response.writeHead(200 /, ...set http header info (mime, length etc).../ ); stream = fs.createReadStream( filename, { flags: 'r', start: start, end: end }); stream.pipe(response);