Re: [nodejs] Node.js native cluster load balancing and memory snapshot

2012-03-30 Thread Wan Li
> > 1. Some processes utilized far more CPU time than others, but I'd expect > > they should be have similar load. No? > > Load balancing is done by the operating system. The nodes in the > cluster listen on a single socket, it's the OS that decides which node > gets the connection. I've observed o

[nodejs] Node.js native cluster load balancing and memory snapshot

2012-03-30 Thread Wan Li
Hi everyone, My node@v0.6.6 web server runs in production for over one month without any problem. Thank you, node. I noticed some strange things after long run. ps ux | grep node op 23356 0.0 0.0 659632 10268 pts/5Sl+ Feb24 7:28 node app.js op 23358 0.1 0.1 734888 17372 pts/5

Re: [nodejs] Re: Streaming parser for XML and JSON

2012-03-02 Thread Wan Li
On Fri, Mar 2, 2012 at 7:04 PM, fent wrote: > Have a look at https://github.com/isaacs/sax-js xml2js is built on top of sax-js. I even hacked version to utilize the streaming API provided by sax-js, but doesn't help too much. -- >: ~ -- Job Board: http://jobs.nodejs.org/ Posting guidelines:

[nodejs] Streaming parser for XML and JSON

2012-03-02 Thread Wan Li
Hi Gurus, I'm trying to convert some related large XML files (~30MB) to JSON format. I've tried some out of box solutions such as xml2js, xml2json. All of them consumes a lot of memory (200~300MB) ,so I'm wondering if there are modules that are less memory hungry. After the JSON string is construc