4 ms·
In fact, Rails is one of the slowest of the major frameworks. Based on TechEmpower's composite benchmarks: 1. drogon (C++) 92.3 2. actix (Rust)
by culi 4y ago
In fact, Rails is one of the slowest of the major frameworks. Based on TechEmpower's composite benchmarks:
1. drogon (C++) 92.3
2. actix (Rust) 90.7
3. asp.net core (C#) 83.7
~~ mind the gap ~~
4. gin (Go) 23.0
5. spring (Java) 21.8
6. phoenix (Elixir) 8.1
7. express (Nodejs) 7.3
8. laraval (PHP) 4.4
9. rails (Ruby) 4.3
10. django (Python) 3.2
https://www.techempower.com/benchmarks/#section=data-r21&test=composite https://www.techempower.com/benchmarks/#section=data-r21&tes...
- metaltyphoon 4y agoI have no idea why people/companies don't pick asp.net core more often. The amount of headroom you have before bottlenecks is immense. It has world class tooling to boot too.
- brigandish 4y agoIt's been a while since I did C#/dotnet but I imagine the ecosystem (i.e. Windows, SQL Server etc) in terms of cost and, shall we say, inflexibility, would be high in people's minds. That, and the kind of boilerplate required that means people don't start with Java nowadays either. I moved from C# to Ruby, and along the way I read Design Patterns in Ruby[1] (which I highly recommend), and it went through several of the patterns I used to have to apply in C# to make it workable, and it would then show me they weren't needed in Ruby because of the structure of the language. Maybe C# has improved in these kind of things, but things like that matter when developers are also expensive and you want to crank out features. [1] http://designpatternsinruby.com/ http://designpatternsinruby.com/
- Merad 4y agoSpeaking as a C# dev, IME most people are working off of severely outdated views of the .Net ecosystem. .Net has had first class support for Mac and Linux for a good 6-7 years now. Postgres support is every bit as good as SQL Server, and plenty of other db‘s can be used as well. All of the new projects I’ve started in the past 5 years have used Postgres db’s and deployed on Linux. If you don’t like boilerplate then I have good news, nowadays you can make a fully functional Asp.Net API with about 20 LOC.
- culi 4y agoSo what is it then? Is there a quick-start for Asp.Net projects? Is there a canonical "make a blog"-type tutorial project? If I wanted to try making and deploying a couple tiny asp.net apps in order to learn the framework, is there a service that can easily host them like Heroku used to do?
- Merad 4y agoWell bear in mind that Asp.Net is a large framework. The minimal approach I mentioned is for creating APIs [0] which you can use with whatever JS front end you please. If you don't want a JS front end Asp.Net has four different options for building web front ends [1]. The hosting question has me a little confused I guess. You don't need anything special to deploy or run modern .Net code? You can run your app anywhere that the Asp.Net Core runtime is supported [2]. Or bake your app into a container and run it anywhere that understands containers. MS has tutorials for deploying to Azure [3], but I honestly know nothing about it (Azure). Every place I've worked at that had cloud infrastructure has used AWS, and I've never needed to deploy a hobby app. 0: https://learn.microsoft.com/en-us/aspnet/core/tutorials/min-web-api?view=aspnetcore-7.0&tabs=visual-studio https://learn.microsoft.com/en-us/aspnet/core/tutorials/min-... 1: https://learn.microsoft.com/en-us/aspnet/core/tutorials/choose-web-ui?view=aspnetcore-7.0 https://learn.microsoft.com/en-us/aspnet/core/tutorials/choo... 2: https://dotnet.microsoft.com/en-us/download/dotnet/7.0 https://dotnet.microsoft.com/en-us/download/dotnet/7.0 3: https://learn.microsoft.com/en-us/azure/app-service/quickstart-dotnetcore?tabs=net60&pivots=development-environment-vs https://learn.microsoft.com/en-us/azure/app-service/quicksta...
- culi 4y ago> The hosting question has me a little confused I guess. I'm not sure how much you've played with Node, Ruby, etc BE ecosystems but there are plenty of "just `git push` and watch you app automatically deploy" services out there that makes it really easy to get started playing around with the actual framework and not get bogged down in docker files or AWS configuration.. Maybe I'm spoiled, but I'm also... busy. And I'd like to be able to try out a framework first before I decide if I wanna invest a lot of time working on a full-fledged project with it and these sorts of tools are perfect for that Thanks for the links
- dvngnt_ 4y agoconfusing names
- irjustin 4y agoHistorically it was pricing of Windows IIS and that I'm a person completely enveloped by the Apple ecosystem. Not sure if either of those points matter 8+ yrs on since I last looked, but I know I'm not the only developer who has these concepts burned into their soul.
- culi 4y agoGiven that game dev in Unity is also driven by C# I wouldn't actually be against picking it up as a web dev. But it's hard to find any beginner-friendly resources out there. Is there anything like Heroku, Vercel, Fly, etc that lets you really quick build and deploy a full-stack app? My path to learning a new framework and language is full of half-finished project ideas and this process of quick and easy iteration has proven really useful to me being able to learn something quickly Genuinely curious if anyone out there has some wisdom to share about this since I know next to nothing about the ecosystem
- Jataman606 4y agoYou can get similiar process as Heroku (just push to github repo and everything automagically deploys) on Azure using App Services. The problem is there is no free tier anymore, although i didn't really look up exact prices. There are plenty of very basic tutorials in official Microsoft documentation, if you search for stuff like "how to deploy .Net core app on azure" you surely find some tutorials that go through whole process from scaffolding basic project to running it in the cloud.
- bmurray_napaco 4y agoAsp.net core is fully cross-platform and self-hosting, so you do not need to incur Windows/IIS licensing costs. For this site's audience, I would recommend taking a long look at F# over C#. If you aren't aware of it, it's functional-first, OCaml-inspired, but you have access to all the Asp.net core framework you need (similar to accessing Java from Clojure). A batteries-included framework that seems popular is the "SAFE Stack"[0]. [0]https://safe-stack.github.io/docs/overview/ https://safe-stack.github.io/docs/overview/
- irjustin 4y agoGod ASP.Net is incredible. I mean it is what runs StackOverflow on "minimal" hardware. I'm a Rails, Django guy and we run into exactly what you're talking about. The speed we can pump out features is fantastic in both, but once you get to a large number of objects, it's better to drop into pure sql/array handling. This is mostly for data processing, background jobs where we need to work with >1k separate objects.
- steve1977 4y agoMicrosoft highly games this benchmark for ASP.NET core. I’m not disputing it’s faster than Rails, but the actual real-life gap will be much smaller.
- culi 4y agoIt's a large set of benchmarks so I'd be really curious to hear how they can game it. Got any good readings?
- steve1977 4y agoThis article was quite eye-opening: https://dusted.codes/how-fast-is-really-aspnet-core https://dusted.codes/how-fast-is-really-aspnet-core Now please note, this only talks about what Microsoft is doing, maybe others do the same. Edit: I saw the article does in fact look at other frameworks. In the end, it just means these particular benchmarks are pretty much worthless for any kind of real-life comparison.
- culi 4y agoThanks for sharing. From the article, even the worst of asp.net was often still outperforming Go and other major frameworks. And the versions explicitly pointed out as actually fairly realistic still placed in the 73-86 ranges. In addition, you could do the same exercise with gin, rails, etc and find a lot more variation (though rails and django do basically always suck in comparison) It's interesting because even the maker of actix (Rust) was pretty explicit about their goal to optimize for these benchmarks. And it really worked to improve the perception of Rust for web dev applications.[0] The current leader is actually JUST which is a JavaScript based framework that's pretty much solely focused on these benchmarks. I think the strategy for optimizing like this and sometimes even fudging numbers a bit is pretty standard for a new framework or platform trying to make a name for itself (ahembunahem). Actix is new, JUST is more of an experiment, and tbh I've never even heard of drogon. But when it comes to frameworks like ASP.NET core, Laraval, Rails, Express, etc you can at least trust that they've been around for a long time and there are many proven examples of their application to both commercial and hobby projects. IMO the fact that ASP.NET has been around for so long yet can still top benchmarks like these is still a noteworthy feat. And its undeniable that Django, Rails, Laraval, etc are leagues behind in terms of performance [0] https://www.arewewebyet.org/ https://www.arewewebyet.org/