4 ms·
I love Go, for many situations, but definitely not for a typical user facing website. The community seems bent on the whole "all you need is net/http", but tha
by joaodlf 8y ago
I love Go, for many situations, but definitely not for a typical user facing website.
The community seems bent on the whole "all you need is net/http", but that just isn't practical in modern web development. People like ORMs, easy to handle html forms, security as a default, easy session/cookie handling etc. In the end, web developers want ease of life.
Go is a great language for many things, but if it's going to take on the web at large (outside of HTTP APIs), the community needs to grow out of this "net/http or nothing" approach.
There is some hope, some frameworks like https://gobuffalo.io/en https://gobuffalo.io/en are showing up, but the Go ecosystem is dying for a Rails/Django solution.
- jimmy1 8y ago> but that just isn't practical in modern web development People always use this modern term as if it implies something significantly different or more "advanced". The web hasn't changed much. It's still data over tcp sockets to a contained runtime -- a web browser. > People like ORMs People in my experience are starting to dislike ORMs. If you have done this for long enough, you realize they are great for getting off the ground, but they inevitably get in your way, and start generating some really bad queries which you have to start one by one replacing with raw SQL statements, at which point you might have well started with raw SQL. Having come from Rails, and PHP frameworks like Symphony and Laravel at my company, using Go I feel almost like I am more intimate with my code. I understand it better, the dependency chain only ever goes one or at most two levels deep. I will admit the the templating and routing is more "batteries included" in these frameworks, but the other parts that I have control of that I consider much more important (such as how my data actually gets stored and other network calls I have to make), I would much rather do those in Go than in PHP
- pier25 8y ago> People in my experience are starting to dislike ORMs That's what I see around me as well.
- davidsawyer 8y agoSpeaking as someone who moved from a company that heavily leaned on an ORM to a company that is using jOOQ (a thin Java wrapper around SQL) for everything, not being able to use an ORM is pretty painful. I greatly miss the nice, clean ORM experience. It's so much better for developer efficiency.
- sacado2 8y agoThis is so true. I love go so much, because deployment is so easy, but using it for end-user web content is a real PITA.
- mbrumlow 8y agoWhat makes it a PITA? I use go for building websites and it was the first time web development really made any sense. All the other systems out there require tons of tools, and lock you into doing things their way. So, what makes GO so much of a pain? Maybe ignorance is bliss for me?
- apta 8y ago> All the other systems out there require tons of tools, and lock you into doing things their way. Nothing is stopping you from writing everything yourself in any other language. You can do the same in Java or .NET. Then you start finding out you need routing, validation, security, DB access, etc. which golang lacks and ends up making it much more verbose than other mature frameworks.
- sacado2 8y agoI made a very simple webapp a few months ago, where students are proposed assignments and can rank them. For that, you need authentication, and DB management: a subject table, a student table, and a ranking table. You have to do all of that manually in go, while other languages have frameworks that take care of it. Still did it in go because it was a very simple webapp and deployment is so easy with go, but for a more complex task I'm not sure I'd have used it.
- mbrumlow 8y agoI hear this argument a lot. I like to ask, are you writing software or using frameworks? I am not saying you need to write all your software but if your app is on the lines of declaring a few statements and running a command to generate the rest then I have to ask what you really are doing. On top of that you have to ask how you will approach changing your program using frameworks to the specs of the task at hand? Also, can you go into what is "manual" about autentication, db management in go? Compared to other languages? Did you mean framework?