Writing Microservices in Go
Glenn Engstrand
Facilitates better, faster, cheaper product delivery from requirements to production deployment
Go is a general purpose programming language from Google. Rob Pike, one of Go’s inventors, gave a presentation about Go in which he said this. “Go is software for the parts that we work on which is mostly infrastructure.” Some of the most modern popular infrastructure services are written in Go. Kubernetes, Docker, Terraform, Etcd, Istio, and Prometheus are some notable examples. According to TIOBE, Go experienced a big jump in popularity back in 2016. According to Stack Overflow trends, Go experienced a big jump of interest in 2018. There are many high profile companies who are developing in Go including; Apple, Uber, Dropbox, BBC, NYT, Medium, and the Economist.
In the world of programming languages, there is usually a trade-off between simplicity and expressiveness. Simpler programming languages are easier to learn and are less likely to be misused but are also not expressive enough to solve more complex problems. What I like about Go is that it does very well in terms of this trade-off. Programs written in Go are pretty simple yet can still solve fairly complex problems.
I am starting to see a lot of coverage from technology blogs on writing business focused microservices in Go. I thought that I would evaluate Go for that purpose. Whenever I evaluate a tech stack for microservice development, I implement the same feature identical service. I put it on a Kubernetes based test lab then capture and analyze the performance results. This is how I can form a basis for comparing the tech stack with other, previously evaluated, tech stacks. The repo for all of these implementations and the test lab is open source available on github.
I documented what I discovered in this blog entitled Writing Microservices in Go.