Hacker News new | ask | show | jobs
by scandox 3315 days ago
> when we started to look at .NET Core in early 2016, it became quite obvious that being able to asynchronously hand off to our queuing service greatly improved throughput. Unfortunately, at the time, Node.js didn’t provide an easy mechanism to do this, while .NET Core had great concurrency capabilities from day one.

This is a mildly maddening article - not because I have any emotional attachment to either platform - but because it never really gets to the heart of the matter. It's like they can tell us, but they'd have to kill us afterwards.

2 comments

I'm with ya. All hype, no details.

A 20X improvement cannot be attributed to .NET core, it must attributed substantially to some implementation/algorithmic issue that they resolved once they got to the .NET core platform. There's a big problem somewhere with node.js if it is 20X slower. If true, then its simply a bug or series of bugs to be fixed in node.js.

Just a basic request/response with barely anything thing in it, shows the .NET core is faster than node.

https://stackoverflow.com/questions/43920942/unexpected-outc...

Obviously this isn't very scientific without a benchmark suite.

It's not 30 times faster. Also, it doesn't matter which one is faster unless there is. Huge speed improvement. Your web server is not the bottleneck.
>It's not 30 times faster.

That's because the empty request doesn't do much. Start adding real work and the statically typed JIT compiled .NET code shows its real teeth.

"Your web server is not the bottleneck." - Highly depends on your setup.

But removing any 3rd party libraries, and external requests. Generally .NET core is faster.

Actually 3rd party libraries and application code is where .NET is likely to be faster unless node lib is wrapping a C library - .NET can easily beat JS an order of magnitude simply by having control of memory layouts and high performance/specialized data structures. Meanwhile JS has crap structures (doesn't even have primitive arrays) and everything is it's dynamic object where you pray the JIT eventually figures out a constant structure and tries to optimize.
Just to nitpick a bit, JS does have primitive arrays using TypedArray.
Yes, but if your going to compare(Badly in this case). You probably want to test it in isolation.
> But removing any 3rd party libraries, and external requests. Generally .NET core is faster.

Is that with reference to "faster than .Net regular" or "faster than node.js"?

You're right either way but I'm not sure that "it's just faster" is all that relevant. The "Just a basic request/response with barely anything thing in it" case removes anything of interest.

For any normal non-trivial, non-demo setup, the web server is fine. I would look at the performance of data stores and other backends. The performance of "asynchronously hand off to our queuing service" is most likely the overriding factor in a 20 or 30x increase.

Some have already optimised the heck out of their data retrieval and writes.
Honestly, add another machine and the problem is solved. youll be able to afford a team of programmers to rewrite your app in any language of your choosing by the time you feel the slow down.

I'm using .NET core for a production app now. Team of 16. It's working beautifully. The data access is the bottleneck in 99% of what I have ever worked on, not the web framework. That is why Rails is so popular.

> Honestly, add another machine and the problem is solved. youll be able to afford a team of programmers to rewrite your app in any language of your choosing by the time you feel the slow down.

I understand your point, but your statement isn't true in all circumstances. It depends on your business model. Performance begins to matter more when the economics demand it. Say you're working on a game that has a free tier, or a service that offers some things for free and some things paid. Every customer hour costs you a certain amount, and you can expect a certain amount of revenue per customer hour on average. With this kind of a balance, a 20x performance difference can mean a fundamental shift in what kinds of business models can be profitable.

So for something like enterprise software, yeah, add another server. But for something like an MMO or 4Chan performance can be make or break. It's all about cost per user hour vs. revenue per user hour.

It may also be that it's easier to write in performance issues or bugs unintentionally with Node.
I agree with you. A bold claim with very vague explanations makes it a bit hard to believe. I'd love to have more details on how they pulled that off.
this is yet the "more detailed" post. Here is the original story https://customers.microsoft.com/en-US/story/raygun which I objected to https://twitter.com/aliostad/status/849186214045528064