Re: [nodejs] Writing 500kb of JSON

2012-10-29 Thread Ben Noordhuis
On Sun, Oct 28, 2012 at 4:02 AM, P. Douglas Reeder wrote: > One of the things my app needs to do is write a large JSON file to disk. > Currently, it's implemented naively: > > writeStream = fs.createWriteStream(process.cwd() + "/staticRoot/album.json", > {"encoding": "utf8"}); > > writeStream.addL

Re: [nodejs] Writing 500kb of JSON

2012-10-28 Thread P. Douglas Reeder
Thanks! I'll give JSONStream a try. On Sunday, October 28, 2012 1:30:24 AM UTC-4, Boris Egorov wrote: > > Check https://github.com/dominictarr/JSONStream > > > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You recei

Re: [nodejs] Writing 500kb of JSON

2012-10-27 Thread dolphin278
Check https://github.com/dominictarr/JSONStream On 28.10.2012, at 7:02, "P. Douglas Reeder" wrote: > One of the things my app needs to do is write a large JSON file to disk. > Currently, it's implemented naively: > > writeStream = fs.createWriteStream(process.cwd() + > "/staticRoot/alb

[nodejs] Writing 500kb of JSON

2012-10-27 Thread P. Douglas Reeder
One of the things my app needs to do is write a large JSON file to disk. Currently, it's implemented naively: writeStream = fs.createWriteStream(process.cwd() + "/staticRoot/album.json", {"encoding": "utf8"}); writeStream.addListener("error", function (error) { console.error("album.json:", er