Next level Go testing

Go makes it very easy to write tests. In fact, the test tool is built in the standard toolchain, and you can just run go test to run your tests, without installing extra dependencies or anything else. The testing package is part of the standard library, and it’s use, I’m happy to observe, is pretty wide spread.

Read more

A love song for Bash

There isn’t a day where I don’t see some kind of DevOps article that advocates some sort of higher order programming language for performing shell tasks, most recently one that uses Python to issue a POST request on a Discord Webhook API, when ever somebody logs into your server.

Read more

Error handling and where Go2 gets it wrong

This is an article which I’ve struggled with for the past few weeks. It started plainly enough trying to write about unit testing in go, but there was a lot of overlap with error handling and a significant portion of that was taking a hard look at the Go2 error handling draft. I’ve written and re-written this article many times, where it morphed from advocating simple assertions in tests to make unit testing easier, to actually having a detailed look at where Go2 error handling falls short.

Read more

Basic monitoring of Go apps with the runtime package

You might be wondering - especially if you’re just beginning to work with Go, how you might add monitoring to your microservice application. As people with some sort of track record will tell you - monitoring is hard. And what I’m telling you - at least basic monitoring doesn’t need to be. You don’t need to set up a Prometheus cluster to get reporting for your simple applications, in fact, you might not even need external services to add a simple printout of your apps statistics.

Read more