Going back to Go: A series
· 2 min read
Revisit basic of Go (Golang) and new features with runnable examples.
Background
I haven't used Go extensively for a while, and I am not keeping up with recent releases of Go. I think it is a good time to recap frequently used features and explore new features and write some simple projects to practice them.
Plan
NOTE: Subject to change, link to blogs will be updated when they are published (if ever).
Language features
- goroutine, channel, concurrency (concurrency is not parallelism), error group, singleflight etc. context.
- generic, never used it directly after release ...
- reflection e.g. struct tag
- iterator, yield? https://go.dev/blog/range-functions
- embed asset
- mod and the new workspace?
Patterns and Libraries
- logging, there is a new interface for structured log
- error handling, error wrapping is the last update I looked into
Network
- basic usage of standard library, net, net/http
- implement application protocols, e.g. http 1, websocket on top of low level network.
- a high level wrapper for quick http client/server scripts
Database
database/sql
already forgot it ... don't use it often TBH- sqlite? cgo or write a pure go reader
Projects to practice
- Update https://github.com/dyweb/gommon with latest language features
- A cli to show time in different timezones, the old
pm tm
port to standalone app. - Tennis racket price crawler, we can compare cursor code and human written code
- DB? Workflow, data analysis etc.?
- ? LLM related projects?