Re:Node v0.10.0 (Stable)
by nashequilibrium on Monday March 11, 2013 @11:42PM
(#5359990)
I really like nodejs as well but i have some concerns, i built an app in tornado and then i wanted to try out node, so i built it in node as well with a postgres backend. I was surprised how much faster my tornado app was: using bcrypt blocking module for tornado with a factor of 8 gives me 42.51ms for login, on node i get 153ms, geting a user profile 6.7ms on tornado and 16ms on nodejs. These results are consistent across the app, where tornado seems to about 3 times faster. I am assuming that maybe this is due to the quality of the libraries, since i assume node is faster. Reading this article,(https://hacks.mozilla.org/2012/11/fully-loaded-node-a-node-j...) helped to understand node more as well as how some of the libraries deal with threading and async.
Re:Node v0.10.0 (Stable)
by jongleberry on Tuesday March 12, 2013 @12:18AM
(#5360122)
1) are you using the synchronous or asynchronous version of bcrypt?
2) cached or uncached templates?
3) throw 1k+ requests per second and tell us which one is faster
Re:Node v0.10.0 (Stable)
by nashequilibrium on Tuesday March 12, 2013 @12:30AM
(#5360181)
I am using the aync bcrypt module for nodejs. I am using it as an api for ios app. I will do the 1k test and let you know.
The pace at which libraries have come up around Node is astounding. Mostly probably the fastest growing eco-system ever.
Yes, quite literally there's more library than we developers/hackers can play with. I've spent a lot of time just browsing through all of them and they are all excellent. But there seems to be 3 types of npm modules on github, 1) active and mature 2)fairly new, stagnating, seldom active 3) abandoned.
Re:Node v0.10.0 (Stable)
by alexpopescu on Tuesday March 12, 2013 @01:19AM
(#5360346)
How is this any different to the status of other projects in other environments?
Nice try, not going to point specific fingers at certain environments out of risk getting flamed.
My first brush with Node was in a class. We chose to try it for a game only about 5 months after Node's initial release. It was cool and fun to work with but ultimately a bit rough. After a year's break, I can now say I love Node. I'm glad your return was just as encouraging.
Pretty much the same case here, I've abandoned LAMP stack completely. There's no need anymore, I am tired of having to google how to setup Apache config on some esoteric distro to see it fail when traffic spikes, I am not getting the best bang for the buck but with NodeJS, everything is so much easier.
(Though, of course, there are plenty of other alternatives to LAMP -- I find Nginx, Postgres, and Ruby or Python preferable in pretty much every way).
I think having NodeJS serve up static content is a waste of time, and that's not its intended use case. So I'm with you. I set my server up with nginx serving up static content, and when an API call is made nginx proxies to my Node app.
Why is it a waste of time? There are plenty of good solutions now like Hipache.
Perhpas he means it's a waste of cpu time :)
But I wanted to make a meeting agenda site, since I don't like any of the ones out there right now. So the last 4 days I worked on one writing it as a JS web app that talks to a Node backend. It was quite painless. Anything I wanted to do (whether generating uuids, date formatting, etc.) there was a module available on npm. Couldn't be easier.
The platform has really matured a lot, and I didn't run into any issues with Node itself.
If you haven't yet, the next time you're doing an experiment, give it a try. I will probably write my next project this way too.