Rent-a-founder

Golang: Append Modifies Underlying Slices

Even after four years of programming in Go, there are still things I didn’t know about the language itself. The following example illustrates behaviour that surprised me. My (false) assumptions actually led to a bug which was very difficult to find as it happened only rarely and repeated reviews of the code didn’t turn up anything unusual. Here it is:

Read more...

My Go Package Reaches 1.4K Stars on GitHub

I was pleasantly surprised when I realized my recently published Go package tview had just passed 1400 stars on GitHub which is quite significant. It seems to have struck a nerve. As mentioned in my previous blog article, there are already a number of Go packages that allow you to create terminal-based user interfaces. But the focus on making it simple seems to have paid off. Naturally, with this popularity come new responsibilities: All of a sudden, I have to respond to feature requests, bug reports, and pull requests. Read more...

Terminal-Based User Interfaces in Go

Recently, a number of Go packages to create terminal-based user interfaces popped up. This is great because it allows you to run semigraphical applications on the server. It’s also more secure than implementing a dedicated admin area in your web app because it reduces the attack surface by hiding behind an ssh login. Here’s an example from Stock Performer where we can monitor the analytics precomputations that happen on the server: Read more...

My Gopher Academy Blog Post on Web Sessions and User Workflows

I’ve released two new Golang packages on GitHub: github.com/rivo/sessions and github.com/rivo/users. They will help you write web apps in Golang.

Read more...

Graceful Server Stop and Restart in Go

A blog post from 2014 explains quite nicely how one can achieve graceful server stops and restarts in Go, that is, how to implement a server process that allows running requests to finish before exiting the application. We will also want to deploy new binaries without interrupting running requests and without any noticeable server downtime. There are tools for this and in the past, I’ve used a combination of manners and goagain, along with some additional code on my end. Read more...

Find Similar Images with Duplo

I’ve released a Go library Github: Duplo. The library can be used to detect image duplicates or to find similars in a set of images. It is an implementation of Fast Multiresolution Image Querying by Jacobs et al. It works surprisingly well if you want to find duplicate images which may have been modified slightly (e.g. colour correction, different compression / file format, watermarks). Applications may include: Recognize copyright violations Save disk space by detecting and removing duplicate images Search for images by similarity The images themselves are not stored in the data structure. Read more...

My Talk at the Golang User Group Berlin Meetup

I gave a talk at Berlin’s Golang User Group (which is supposedly the biggest one in Europe at the moment). It was a quick overview of the duplicate image detection software I wrote in Go for Stock Performer. You can find the slides here. I will put the code on my Github profile very soon. There will also be a more extensive blog post about it.