I often hear that Golang is such a fast language that server costs strive for zero. I was especially stunned when saw Ben Davis's GoLang Review video, where he stated that server costs for his new startup with 'tens of thousands users' (source: https://youtu.be/kUoPdQwyABA?si=d8aCXjTOY4B42uEi&t=204) VIDEO LINK WITH TIMESTAMP WHERE HE SHOWS HIS CLOUD PROVIDER DASHBOARD, NOT PROMOTING ANYONE barely exceed 3 dollars. I did really like that because I am planning on building an app to try my skills and I would very appreciate it if server costs would not exceed a couple of dollars. That sounds like a miracle, but I guess that's why Golang is so popular.
So, my question for the .NET community is - how much worse would be my server billing if I choose .NET Core? I am planning on building an application using htmx + razor pages as a template engine, just because I found it interesting to play with htmx and I do not know javascript and do not really want to. In Golang that would probably be core html/template package?
Keep in mind please that I am living in one of the poorest countries in Europe and even a couple of dollars matter, especially when your project is non-profit.
Videos
Looking for a convincing story to choose Go over .Net for "anything". Yes Go has a great concurrency model - the present state of concurrency/async/etc is not too shabby in .Net. Yes Go has great tooling - like it or not, Visual Studio is pretty damn good, and with the right setup you can be very efficient. I've built some decent CLI tools in Go, but I can do the same in .Net, perhaps not deployed in a single binary (unless you go the route of ILMerge), but still. Roughly equivalent and I can use F# if I want a more functional experience.
I'm asking this sincerely as someone who is trying to convince himself that there is value investing valuable time in Go in the future. I'm always learning new languages and there is major value in just the learning aspect alone. That said, given the current and planned future state with .Net (Core, cross platform, etc), why would you pick Go over .Net?
I'm a student majoring in in CS and I'm interested in golang and learn it a little bit but I don't know what's the real advantage of it.
I think C# or java has better a framework now (for example Spring in java) and speed is fast enough.
and golang's orm isn't good so far.
If you guys work for company and use golang now, I want to know why you choose it.
** recently golang is frequently used in blockchain instead of C++. why?
I have been using Golang for over a year now. I'm in love with it and I've been using it for all my website development needs.
I recently heard about ASP.net Core, which surprisingly I've never even heard of.
Is it worth it for me to learn ASP.net Core, or should I stay with Golang?
Hopefully commenters have insight in both ASP.net Core AND Go.
ASP.NET and languages on the .NET platform have a lot more to them than Go in terms of actual programming paradigms. LINQ for example is a godsend.
If you're planning on building something more complex that may eventually turn into a business, ASP.net has a much larger talent pool associated.
Additionally, if you're going to be looking for a job at some point - unless you're in a high startup density area - there's likely a lot more .NET jobs than Go.
Since the .NET platform has been around decades longer than Go, the community is a lot more mature and library quality tends to reflect that maturity.
Ultimately you have explained what you're looking to do so it's hard to say yes or no.
I do not understand why you have arrowed your choice down to those two. Perhaps if you said why, and what you like about go, and what else you have tried and did not like people could make more useful suggestions.
HiI am a node devBut aiming to consider ASP>NET core vs GO for a backend web app .I read an opposite results of benchmarks.I know that GO yields binary while C# yiels byte codeBut this is not the only thing that affects performance.which is more performant between both for heavy load apps?
does go add Generics till now ?
I'm new to go.
I've been through the tutorials and am comfortable with the language so far. I now want to write a web app (backend api).
But I think using go by itself will be difficult and probably a waste of time.
I typically use C# and ASP.NET Core - in which case there is a difference between the language (c#) and the web framework (asp.net core). ASP.NET does an incredible amount of stuff - config, ioc/di, auth, routing, validation, db work using an ORM, server-side rendering (if you want it), etc.
Is there an ASP.NET Core equivalent in the go world?
I found dozens of options, but can't tell which is the most stable and heavily used by the go community.
Hey guys, I’m trying to decide and convince my superiors that .net is just as performant as Go or Node but I need some help.
SOME CONTEXT AROUND THE PROBLEM: We are trying to decide on a stack on GCP for a set of micro services. I am all for .net and postgresql / alloydb. We are planning to deploy the code on containers using Cloud Run.
The issue here is that my superiors think that .net is not as performant as go or node. IMO and all the research that I’ve done suggest that .net 6 is light years ahead of the previous versions and is completely capable of holding up against go or node.
My concern is also around the fact that code organization is so much better with c# compared to go or node. Simple things like IoC is better in c# vs go or node.
Any help on this is appreciated.
I've been learning C# 10 and the .NET 6 ecosystem, however I feel that despite the large effort to minimize the "framework", an application made with pure .NET BCL (even without ASP.NET Core) is somewhat bloated, slow and hard to configure. C#10 has a lot of new modern features for coding yet still preserve old features from 5 years ago for the sake of backwards compatibility, resulting in a somewhat bloated language that has 10 ways of doing the same thing without being clear which one is the most optimal way.
This is my first impression after learning C# 10 and the .NET 6 BCL for a week, I haven't even gotten to ASP.NET Core yet, but with what I am learning now, I have a feeling that learning this humungous platform will take me years to have enough experience and knowledge for an entry level job as a backend .NET engineer.
Looking at jobs in my local area, Golang seems to also be used a lot for backend development. But it lacks the maturity that ASP.NET Core 6.0 has, the "framework" has a lot of integrated features that are coherent with one another and reduces a lot of the headache that comes with developing backend compared to other frameworks like Node.js. That's the general consensus I got from the community.
What are your thoughts on it? How does ASP.NET Core 6.0 compare to Golang for backend framework? Does Golang have an ORM like .NET has for Entity Framework? I'm absolutely frustrated by the convoluted monster that is .NET, but not sure if I should drop everything that I've learned so far and switch to a completely new language or if I should stick with .NET because I have already been learning it for some time.
EDIT: I should clarify in this post context, I'm not just referring to "GoLang", but rather the GoLang's ecosystem and popular backend framework used in Go. It's not clear to me which backend framework is used in Go, the community seems to be split on this. But on the C# side, there's really only one framework for backend development (ASP.NET Core). It's more easier to refer to ASP.NET Core specifically than it is to refer to C#.
Hi everyone,
I'd appreciate your input. I'm a programmer with about a year of experience in ASP.NET, primarily because it's what my current company uses. However, I'm really interested in Go (Golang) and am considering whether to shift my focus.
Currently, my role isn't fully focused on coding, but more on analysis. While I've delved into ASP.NET over the past year, Go seems to offer better performance for backend development. This has me torn between continuing to master ASP.NET or switching to Go.
I understand that many enterprises use ASP.NET, but I'm also aware of a trend towards Go for its performance, especially in startups and modern companies. I could be wrong, though, so I'd love to hear your thoughts and suggestions on which path might be more beneficial for my future as a developer.
Thanks!
Hi everyone,
I'm new GO learner, I'm so sorry if my question is bad.
Currently, I want to build a backend for an application which is used to listing properties and manage appointments...
I'm consider about building a restful API with ASP.NET CORE 3 or Go. After I review some docs, GO has a powerful thing is Gorountines are functions that run concurrently to resolve request. Instead of ASP.NET CORE, we will have to use Async to resolve requests in a Thread.
Gorountines will be resolved by less code?
Shoul I choose Echo or Gin for this app?
It would be helpful if you could provide suggestions or feedback.
Thank you so much for your time.
What's your question here? You can create a restful API in both languages.
Whichever you want to pick is up to you and your personal preference.
Obviously, in the Golang subreddit people will be more inclined to recommend Go to you, but there is no reason why you couldn't also do this in asp.net
Do you like the async programming model or the sync programming model when writing concurrent programs? For me, being able to write blocking functions and not deal with callbacks and promises is a bit easier to manage.
Gin vs Echo is another personal preference. Many people like each.
In the last two years, I've worked with C# and the ASP.NET Core framework but I'm not happy with it. I feel the .net ecosystem has many abstractions over abstractions to keep the programming easy. But this makes the code poor because it's easy to do something that works but is hard to do something good. After all, the frameworks already made a lot of decisions that we need to conform with it.
During my programming learning, I've focused on learning more about how the technologies work. For example, when I learned about message queues, I focused on understanding the concepts of RabbitMQ and using libraries that are simple/straightforward with little boilerplate code. The same happened with distributed cache, I've learned about Redis strings and hashes without using the Microsoft abstractions, which treat everything as a key-value pair of strings and bytes.
The more I study the .net core more I feel suffocated because I can't make the decisions my software needs. On another side, my brother works with Go (golang), talking to him I feel that on Go side, almost everything is the programmer that studies and decides how to implement. It doesn't have the "Microsoft stuff done" that I need to swallow to work with it.
So I thinking of moving to Go, but I'm afraid of losing my "two years" of experience and not getting a new opportunity with Go. Another thing that worries me, is my age, I'm 28, and I sometimes think I shouldn't start learning another language because I'm an old junior dev.
What do you guys think? Is Go really how I'm seeing? It's worth moving?
I'm not a fan of any language but I know that there are some advantages and disadvantages of languages and framework alongside platforms matter - PHP is slow, yes it is slow comparing to any other languages but if you setup frakenPHP or swoole then is may compare with other languages -
I was just visiting dotnet page and saw that there is benchmark says 6x times faster than go and go even slower than nodejs
Why is it like this ? I'm not saying this is wrong and they are lying but, what is the explanation of this ? What does matter most such test cases?
Sources:
- https://imgur.com/a/Dx5B2kt
- https://dotnet.microsoft.com/en-us/
Hi everyone,
I've been learning front end dev for a while now (done with html/css/js, moving into react+nextjs) and then would really like to focus on backend.
After talking to alot of veterans, here's what I'm hearing:
- Learning node/express/fastify is a good default first step since I've learned JS for frontend, and these frameworks allow for good rapid development
- After growing comfortable with node, I want to learn a solid 2nd backend lang to become future-proof, and develop my projects in tandem using both langs, and this is where I'd appreciate your input. A veteran developer said that alot of companies are moving from java/c# to Go for their infra, (they use Go + NextJS). What do you see in your circles - is the move to Go obvious, or is .net core growing rapidly, or other thoughts?
My intent is to basically have my 2nd lang as Go or C# (really considered Python, but I somehow feel that Go or C# would be a better option for backend dev).
As a side question - postgresql or MSSQL?
In terms of my intent, primarily to develop startup apps that if they gain traction I want to grow.
Heyas,
I wanted to know which framework to consider more seriously for a new backend, but seemed a lot of benchmarks were outdated, so I wrote one today, and I'll be honest: I haven't used either of these frameworks/technologies much at all in any recent years (Go minimally, and I used to be a .NET programmer around 2005).
Anyway, I'm not entirely sure if this test is completely fair or accurate, but I tried to match the code approach for each as closely as possible. For instance, there has been a lot of rave about .NET Core and its performance, but it seems to be waaaay slower than Go. Can anyone with some proficiency in .NET Core (Web APIs) take a quick look at the source code and see if I'm doing something completely wrong here? Is this possibly because .NET Core 5.0 is in RC (I tested both development and production builds), or because I'm running it on a Mac (it's "cross-platform", isn't it? ;p)?
I will probably add some other results to this benchmark soon, for instance .NET Core 3.0 (Stable), and also would like to test Java (with Spring Boot) against them, maybe Rust. I will also add some other concurrencies/max requests once I've confirmed the source code is on par with each other.
If anyone has any suggestions to modify the benchmark, or has questions on setting it up on their own platform, feel free to reply.
Update: Added JSON-only test to avoid hitting the DB/using any DB driver.
Update: Added Rust (actix-web framework) JSON-only test.
Source Code and Results:
https://github.com/rw3iss/Go-vs-.NETCore-5-Benchmark/
TL;DR:
Go (POST - Db Write):
Requests per second: 7475.72 [#/sec] (mean)
Go (GET - Db Read):
Requests per second: 8454.86 [#/sec] (mean)
Go (GET - JSON Only):
Requests per second: 34946.10 [#/sec] (mean)
.NET Core 5.0 RC (production build) (POST - Db Write):
Requests per second: 742.30 [#/sec] (mean)
.NET Core 5.0 RC (production build) (GET - Db Read):
Requests per second: 1172.63 [#/sec] (mean)
.NET Core 5.0 RC (production build) (GET - JSON Only):
Requests per second: 1488.64 [#/sec] (mean)
Update:
I've added a simple Rust - JSON Only read test to do a basic comparison:
Rust 1.42 (actix-web v3) (GET - JSON Only):
Requests per second: 15039.15 [#/sec] (mean)
This is very interesting, but there's a danger that your benchmark is actually comparing the performance of the respective database connectors rather than Go vs .NET.
Would be interesting to see some different benchmarks.
Perhaps one where each end point just returns a hard coded string (Eg "hello world"). This would measure the performance of the respective http stacks.
Another might be where the end points do some kind of cpu intensive calculation. Although it's not the best benchmark, a simple loop counting to say a million would be super-easy to implement and gives you a very crude indicator of relative performance. (I'm aware of how flawed this is as a proper benchmark though)
If you need exausive benchmarks:
https://www.techempower.com/benchmarks/
There are a lot of infos of about how and why benchmarks have been implemented and what they are actually testing.
Nevertheless, you often might like to have a look into the benchmark implementation for your preferred language in order to make a informed decision of "how" its done (like ORM vs. "Plain" filtering for example).