4 ms·
C# is only at number 3 in your list. Both Java and Rust are above it in the list. It's also a very "artificial" benchmark and real world code will give differe
by qw 6y ago
C# is only at number 3 in your list. Both Java and Rust are above it in the list.
It's also a very "artificial" benchmark and real world code will give different results (if you have static content, just put it in a CDN and don't worry)
Other benchmarks from the same site:
- JSON Serialization: C# is number 34
- Single query: C# is number 23
- Fortunes: C# is number 7
- nodamage 6y agoIt needs to be emphasized how artificial these benchmarks really are. Here is the source for the Fortunes C# benchmark: https://github.com/TechEmpower/FrameworkBenchmarks/blob/master/frameworks/CSharp/aspnetcore/PlatformBenchmarks/BenchmarkApplication.Fortunes.cs https://github.com/TechEmpower/FrameworkBenchmarks/blob/mast... There's no routing or templating, it just writes a bunch of strings. No one would build an actual web app this way. The only C# benchmarks that are remotely realistic are the mvc variants, starting with aspcore-mvc-ado-pg at number 79.
- infensus 6y agohttps://github.com/TechEmpower/FrameworkBenchmarks/wiki/Project-Information-Framework-Tests-Overview#general-test-requirements https://github.com/TechEmpower/FrameworkBenchmarks/wiki/Proj... Routing is required, but generally the rules allow things to be "reasonable" and "acceptable", which lets all these weird implementations through. Honestly, they should remove the "Implementation approach" column, because basically every implementation is marked as "realistic", making it meaningless.
- nodamage 6y agoThe "routing" implementation is more hard coded string matching: https://github.com/TechEmpower/FrameworkBenchmarks/blob/5b0e00e64b36deb46183f3c5edaa612e086c47f2/frameworks/CSharp/aspnetcore/PlatformBenchmarks/BenchmarkApplication.cs#L78 https://github.com/TechEmpower/FrameworkBenchmarks/blob/5b0e... I mean I guess technically that's routing but it's not remotely realistic. Only the mvc variants use the actual framework's routing system.
- arcturus17 6y agoIt ranks 8 in the composite (which adds a layer of human opinion, since they weigh each of the benchmarks...) Java and Rust are both above, but my takeaway is that it seems to be by far the best-performing batteries-included framework according to the benchmark. It leaves the likes of Rails, Laravel, Django, Phoenix, Spring or Nest.js in the dust. Is there something in the benchmark that favors .net core above all the others? I'm genuinely asking, I've never even tried .net but I like full-batteries frameworks and this catches my attention. [1] https://www.techempower.com/benchmarks/#section=data-r20&hw=ph&test=composite https://www.techempower.com/benchmarks/#section=data-r20&hw=...