Live data from Hacker News

Ask HN: What GO web framework do you use?

news.ycombinator.com

11–20 of 26 posts

Re: Ask HN: What GO web framework do you use?

#15
post #8

I use the standard library. My entire business runs on it, html/css all through the standard library (templates package). I use embed to embed all assets in the binary itself. "go build" and then "scp" the binary to the production server and "systemctl restart appserver"

What about scheduled jobs (cron), email notifications, database etc?

Re: Ask HN: What GO web framework do you use?

#17
you can use standard library unlike other langauages golang has built in support for db[1], timer to schedule tasks[2], emails[3], templates[4] etc. and your application would be fairly upgrade proof. If you insist on using framework you can use echo or gofiber. There is also pockebase.io it uses echo internally but comes with user management etc. built in.

[1] https://pkg.go.dev/database/sql [2] https://pkg.go.dev/time [3] https://pkg.go.dev/net/smtp [4] https://pkg.go.dev/text/template [3]

Re: Ask HN: What GO web framework do you use?

#18
post #15
post #8

I use the standard library. My entire business runs on it, html/css all through the standard library (templates package). I use embed to embed all assets in the binary itself. "go build" and then "scp" the binary to the production server and "systemctl restart appserver"

What about scheduled jobs (cron), email notifications, database etc?

My server's binary is more than a server, it can execute one off tasks, etc. For example I can execute the server binary with special arguments, ex "server --task admin-reports" in a cron job.

For the database I use Postgresql with the standard library's database/sql package (using lib/pq as the driver).

For scheduled emails and tasks, I store them in Postgres and I have a task that is run through my server binary every few hours (ex: "server --task scheduled-tasks").

Re: Ask HN: What GO web framework do you use?

#19
post #16

Why do most Go framework websites look like they were made by uni students for their side projects? https://gin-gonic.com/ https://echo.labstack.com/ https://gobuffalo.io/ Compare that to Laravel for example: https://laravel.com/

engineering design, not design design

Re: Ask HN: What GO web framework do you use?

#20
We've got a mix of a few but are recommending use of https://github.com/gorilla/mux due to it using the net/http interfaces and types, great performance and some configurability which can be handy.

In particular, my team is using it in conjunction with generated code https://deliveroo.engineering/2022/06/27/openapi-design-firs...

Post reply on HN