News for hackers. Stuff that matters.
Re:JavaScript is Eating the World by falcolas on Thursday August 24, 2017 @09:43AM (#15090026)
Using non-blocking IO is a very old trick. Even nginx does exactly this, and it's written in C. The ability to use non-blocking IO does not make a language unique in any real fashion.
Re:JavaScript is Eating the World by alayek on Thursday August 24, 2017 @10:02AM (#15090169)
I have never claimed that it's unique. In fact, most ideas in tech is just old wine in a new bottle.

However, I guess what made it appealing initially, was that it uses a syntax known to a lot of web developers. The callback pattern helped.

Although these days, we have been moving away to generators or async-await.

Re:JavaScript is Eating the World by falcolas on Thursday August 24, 2017 @10:18AM (#15090278)
> a syntax known to a lot of web developers

This is the key. And it reflects poorly on them for that. Syntax is the easiest part of a language to learn. The nuances of behavior is the hard part - and those nuances change as you move from the browser to the server; what makes good browser code will not make good server code.

In reality they shunned a ton of knowledge and community support to keep a particular (and particularly mediocre) syntax. Even today, years after Node has reached popularity and many lessons have been learned, developers with no experience outside the browser think they can write perfectly good server code, simply because they know the syntax. Never mind that all of the design patterns change. Never mind that the core libraries they use change. Never mind that they suddenly have to be cognizant of how much CPU time their code takes.

Re:JavaScript is Eating the World by flavio81 on Thursday August 24, 2017 @11:38AM (#15090975)
> Even today, years after Node has reached popularity and many lessons have been learned, developers with no experience outside the browser think they can write perfectly good server code, simply because they know the syntax (...)

This is really true and it's sad, because it leads to more security problems on everyday software.

Re:JavaScript is Eating the World by tim333 on Thursday August 24, 2017 @11:43AM (#15091027)
Beyond the syntax, an event loop is conceptually simple in a way that other models often are not. (For example https://news.ycombinator.com/item?id=11555866 had a how to Python async and I found it a bit confusing compared to js).
Re:JavaScript is Eating the World by jdc0589 on Thursday August 24, 2017 @10:51AM (#15090542)
It has nothing to do with the language, there were other serverside javascript frameworks before node; they didn't take off (e.g. Narwhal).

Node's success has everything to do with the environment itself in combination with the language. The node runtime, the associated stdlib, and most open source/3rd party modules have been written for a non-blocking runtime from day #1. The same stuff can be achieved in plenty of other languages/stacks (e.g. Python + Twisted), but you have much more work to do validating that every single library you use plays nice with async io, sometimes you have more event loop housekeeping responsibilities, etc...

Re:JavaScript is Eating the World by gaius on Thursday August 24, 2017 @10:55AM (#15090583)
Node's success has everything to do with the environment itself in combination with the language.

Let's be honest: it is nothing to do with either of those and purely a matter of fashion. In a couple of years at most there will be a new new thing and everything will revert to version 0.1, keeping everyone busy but making no actual progress. Gotta soak up those CPU cycles the hardware people are giving us somehow right? Can't let the users get any of that speed for themselves!

Re:JavaScript is Eating the World by vim_user on Thursday August 24, 2017 @12:01PM (#15091208)
After two decades in this industry, I've come to the same conclusion. Developers may use logic in coding, but trend-wise, we're bunch of herds following whatever others are doing. We forget whatever lessons we learned previously whenever something new comes out. It's good to see there are others who see insanity in it as well.
Re:JavaScript is Eating the World by kolanos on Thursday August 24, 2017 @12:54PM (#15091774)
There is a logic to following trends, but it has nothing to do with the problems being solved and everything to do with remaining relevant in the workforce.
Re:JavaScript is Eating the World by fundabulousrIII on Thursday August 24, 2017 @12:34PM (#15091551)
I agree with this. I've seen the same but the core problem is we don't learn from others mistakes: we prefer to rely on our own tool-making skills to demonstrate increased facility while making similar mistakes.

The thing missing in developers that I have decried over and over in this devop/agile movement is that SAs had discipline and an ordered idea and that developers exist to perturb the norm to better effect. The two ideas are not readily reconcilable.

Re:JavaScript is Eating the World by coldtea on Thursday August 24, 2017 @11:29AM (#15090886)
>Let's be honest: it is nothing to do with either of those and purely a matter of fashion.

Let's be honest: if you need "fashion" or "idiocy" etc to explain a trend in tech, you don't have an explanation.

Your explanation wouldn't even explain why it was Node+JS that got to be "in fashion" and not something else from the 20000 options.

Re:JavaScript is Eating the World by gaius on Thursday August 24, 2017 @11:32AM (#15090909)
Your explanation wouldn't even explain why it was Node+JS that got to be "in fashion" and not something else from the 20000 options

That's the point. There is no explanation, other than the same reason that bellbottoms are in again this year. Or out, I don't actually know.

We pretend like we're "engineers" or "scientists" but there's nothing objective about what we do...

Re:JavaScript is Eating the World by coldtea on Thursday August 24, 2017 @11:37AM (#15090964)
>That's the point. There is no explanation, other than the same reason that bellbottoms are in again this year. Or out, I don't actually know.

You mean you can't come up with one. Because for me, which followed the scene for 20+ years, there is a perfect explanation.

Re:JavaScript is Eating the World by gaius on Thursday August 24, 2017 @12:02PM (#15091212)
which followed the scene for 20+ years

I had a homepage in 1994. I've seen them all come and go. This one's no different.

Re:JavaScript is Eating the World by abritinthebay on Thursday August 24, 2017 @12:08PM (#15091275)
Mhmmm 1994 here also. Your take is shallow, pointless, and meaningless.

It’s as relevant as saying we don’t write apps in COBOL or Modula2 anymore.

Re:JavaScript is Eating the World by RugnirViking on Thursday August 24, 2017 @12:15PM (#15091353)
I have no horse in this race; Care to share the perfect explanation?
Re:JavaScript is Eating the World by jessaustin on Thursday August 24, 2017 @01:20PM (#15092045)
Re:JavaScript is Eating the World by abritinthebay on Thursday August 24, 2017 @12:06PM (#15091252)
Your personal lack of imagination and insight doesn’t mean there isn’t a reason (there are several, some extremely obvious).
Re:JavaScript is Eating the World by dasil003 on Thursday August 24, 2017 @11:58AM (#15091177)
You have it all backwards. Fashion is the reason you hate it, but before it was fashionable it was not. I get that you're bitter and angry, but you do yourself no service by sticking your head in the sand and willfully ignoring the forces that drive popularity.

I'm frustrated that better stuff doesn't win in the market as well, but I've been a web developer 20 years and Node's appeal was pretty obvious and exactly as the GP states. Without that it would not have gained traction to become fashionable.

Re:JavaScript is Eating the World by thehardsphere on Thursday August 24, 2017 @02:25PM (#15092653)
And nobody really wanted to do these message passing single threaded event loops in other languages, because they could just learn how to use threads instead.

The real innovation that the Node environment and the Javascript language offered is one of marketing to developers who did not know better. Because there were no I/O paradigms in Javascript, one could be created to support this way of doing things, and there was no competing paradigm that people could point to in Javascript to say "Why would I do this when I could just use threads? It's not that hard."

With that out of the way, the floodgates opened, because once the first few people started adopting it because they did not understand threads, it was only a matter of time when "front end" people adopted it, because they did not know any languages other than Javascript. And thus, the current fad was born.

Re:JavaScript is Eating the World by yxhuvud on Thursday August 24, 2017 @01:40PM (#15092249)
Even nginx? Nginx is fairly new compared to all the really old C code.