3 ms·
Large, "real-world" companies such as ngmoco have slashed their hardware requirements by an order of magnitude by moving away from the standard stacks people ha
by pyrotechnick 15y ago
Large, "real-world" companies such as ngmoco have slashed their hardware requirements by an order of magnitude by moving away from the standard stacks people have been "programming for 8 years thank you very much". Before you make another contribution to a discussion, about a technology you obviously know very little about, do some homework.
P.S. picking on a technology because it has some flaws (typeof(NaN) returns "number") is sign of someone who reads books by their covers and fails to see the benefits of an otherwise more suitable solution. You will find in many languages the NaN constant is an instance of some kind of Number type. I'm interested in knowing "the way [you've] been programming for 8 years". I'm certain we could begin tearing it to pieces as you're so fond of doing.
Please, in the future, the moment you begin contributing your FUD to a thread such as this, just say it, and look away.
- ansy 15y agoBoth of you, typeof NaN == number is not a language flaw! It's part of the IEEE 754 floating point specification. https://secure.wikimedia.org/wikipedia/en/wiki/IEEE_754 https://secure.wikimedia.org/wikipedia/en/wiki/IEEE_754 Look, a big "system language" like Java also defines NaN, +inf, -inf as values of double (see Field Summary). http://download.oracle.com/javase/6/docs/api/java/lang/Double.html http://download.oracle.com/javase/6/docs/api/java/lang/Doubl... As in double mathError = Double.NaN; Any other standards conformant language supports NaN for floating point numerical values. I would even argue an absence of NaN should be perceived as a language flaw. EDIT: I realize the above might not actually be sufficiently explanatory. "Not a number" is used to specify the class of numbers that cannot be represented in floating point notation. This includes the undefined like 0 / 0 and imaginary numbers (e.g. square root of a negative value). It can also be used for missing values in a large computation. Any operator with a NaN results in a NaN. So 1 + NaN = NaN. Most NaNs are quiet, as in they do not throw an exception and allow the operation to continue. This allows large batch computations to continue without stopping the entire process for one bad record. Instead there will be a NaN for that record and the rest of the data will be processed correctly. You can see why this might be useful when dealing with large amounts of scientific data and hopefully why the IEEE would introduce such a feature.
- wyuenho 15y agoGood to know. Thank you.
- arturadib 15y agoHi, I'm interested in learning more about ngmoco's use of Node - particularly how they have lowered hardware costs with it. Can you please offer a link?
- wyuenho 15y agoCalm down man. Jeez. I don't know anything about the ngmoco case but I would like to see how their operational costs compare to before. And yes, a link would be helpful. typeof(NaN) returns "number" is obviously a bad example, but how about this? 1 + "1" * 1 == 2 // returns true You really wouldn't know why until you dig into the language spec. There are lots of little things here and there that trips you up on a daily basis in JS I've never really understood why anyone would use it to write large systems on the server-side. It's a language that you have to deal with pretty much everyday when you are using NodeJS, I don't see how using JS can make the people using NodeJS more productive. But maybe that's not the point. But maybe it is, given that on it's website it openly admits that it takes inspiration from Python's Twisted and Ruby's Event Machine. V8 is essentially single threaded. That's common knowledge, but then again, Python isn't much better either. So let's look at it's other selling point - Event driven programming/networking. Is that something new? No. Is that something proven? Yes, as it seems to work very well for Ericsson. Are callbacks necessary in EDP? No. Are they everywhere in NodeJS? Yes. Are they easy to read and manage? Obviously No. For argument's sake, let's say event-driven programming/networking is a very good idea that it warrants slapping on a terrible language and programming practices on it. What about the eco-system? Well, there isn't much to say, or we wouldn't be reading this thread. I don't know man, I don't see the merit in having yet another event-driven programming platform and marrying it on a terrible programming language. It doesn't even have bindings for other languages. I don't really understand the hype, but maybe you can enlighten me because I really haven't been able to find any in depth analysis of NodeJS.
- drgath 15y agoIn the world of software, the best doesn't always win. What wins is; ubiquity, ease of use, & random market factors. x86 isn't the best architecture out there, Linux isn't the greatest kernel ever developed, PHP can be pretty horrible when used incorrectly, Wordpress's code is complete crap, and yes, JavaScript has some quirks. Some really really smart people at Microsoft, Sun, and Google have all attempted to add another language to the browser, and all have failed so far. The only language that has been successful is something that was created in a few weeks at Netscape. And now, that language is invading the server, and it's going to win. Every single big company on the web is toying with Node right now. During 2011, HP is going to ship tens of millions of computers and phones that has Node as a core component of the OS. The performance goals that the Node dev team are aspiring towards are mind-blowing, and you know what? I think they are going to get there. So, to answer your question, what are the merits of Node? The "Ease of use" vs "Performance" ratio is going to be off the charts. You may feel more productive in another language. But there are millions of people who are going to enjoy the ease of use to fire up a high performing HTTP server in 3 lines of code.