38 points · by jeffreyrogers · 11y ago · 24 comments
https://ant0ine.github.io/go-json-rest/
Gorilla is useful, but more for its range of standalone components than as a framework.
Then you'll want database-related packages like redigo and gorp.
Writing full-featured web apps in Golang in 2015 is still a lot like writing a Sinatra app was 8 years ago. It feels great at first, but you quickly realize that you're just building a half-assed version of Rails.
I've never been a fan of full-fledged frameworks and prefer the more pragmatic method of only pulling in components that I need though.
The http packages provides the bare minimum. A serious app requires way more features than what is provided,a router than handles route variables, a middleware stack, a proper context, a proper session mechanism if one writes a website...
So it's normal people write their own libraries on top of it ( like mine @ gopkg.in/interactiv/expresso.v0 ,still alpha )
https://github.com/justinas/alice
It's not very much code (only ~90 lines inc. comments), but I think it establishes a pattern that makes everything very straightforward from authentication to logging to runtime analysis. Plays very nicely with gorilla. I think the more you let net/http shine, the better.