4 ms·
I've been watching the Go "web framework" scene over the past year, and more and more I'm inclined to think that the Rails/Django/Sinatra paradigm simply isn't
by gtrubetskoy 12y ago
I've been watching the Go "web framework" scene over the past year, and more and more I'm inclined to think that the Rails/Django/Sinatra paradigm simply isn't going to work with Go and pursuing it is futile. There is an interesting article on why ORM (ORM's and web frameworks tend to go together) does not work in Go http://www.hydrogen18.com/blog/golang-orms-and-why-im-still-not-using-one.html http://www.hydrogen18.com/blog/golang-orms-and-why-im-still-..., lots of interesting points in it. Especially regarding how some people start out thinking in terms of objects, while others think in terms of database schema. Go is geared towards the latter kind, people who prefer to think at the low level, and the idea of a very high level tool that provides you web abstractions and ORM is foreign to that. In this respect it's not all that different from the C world, where there aren't any web/orm frameworks either and nobody misses them.
- bpicolo 12y agoI've tried out a number of new-fangled languages from a web development perspective (Rust, Go with gorilla, primarily) and in my opinion don't really provide the same set of tools for this sort of web development as higher-level languages like python, ruby, js w/node. That's not to say they don't have important use cases, they just aren't designed with this sort of web development in mind. And of course, it's totally valid to prefer the different paradigm that these provide! Hasn't been ideal for me, though. Services though? Totally an appropriate time to fire up Go, in my opinion. And, even then, Python (which I'm most familiar with) has downsides for JSON services. Translating from an ORM (sqlalchemy) to formatted JSON is something you have to relegate to some magical methods or do one by one, neither is a great solution.
- j_mcnally 12y agoPerhaps I should revise with more of a focus on JSON/Services. I was trying to stick to a common pattern across languages. But that might not be the best approach.
- gtrubetskoy 12y agoYes, services is where Go has a huge advantage over Python and Ruby in particular because of their inability to leverage SMP due to the GIL. With Go you don't need to run a whole bunch of processes behind haproxy or whatever which makes life much easier.
- dragonwriter 12y ago> Yes, services is where Go has a huge advantage over Python and Ruby in particular because of their inability to leverage SMP due to the GIL. That would be an advantage of Go-as-a-language over Ruby-as-a-language in a world where JRuby didn't exist.