A first impression of Rust from the perspective of a Go developer

In these uncertain times and multiple months of remote work, at least we have some more time to dive into something new. I have been developing in Go since 2017, learned some TypeScript in the meantime, but few days ago I wanted to get into Rust once again. First time, approximately a year ago I gave up very quickly, realizing that Rust requires lot of time to learn and I didn’t have that much time at the moment....

2020-12-26 · 3 min · Boban Acimovic

Changes in Go implementation of the new protobuf and gRPC

If you don’t know yet, there were major changes by Google in protobuf and gRPC implementation for Go. New version should be better in all means so you should switch as soon as possible, if you are already using these technologies. In this article I am going to focus on Linux variant, but the upgrade procedure should be quite similar on OSX or Windows. In order to use protobuf compiler or generator, if you wish, you had to install protoc compiler....

2020-11-15 · 2 min · Boban Acimovic

Develop Kubernetes native applications in Golang with auto-recompile and auto-restart

Do you develop or plan to develop a Kubernetes native application in Golang, controller or operator? Such application strongly depends on being inside Kubernetes and development outside of Kubernetes may be a real hassle. Usually you have to build an image over and over again and restart the pod (with imagePullPolicy set to Always). This is very boring and time consuming procedure. Two years ago I developed an image to auto-recompile and auto-restart Go application, named go-reflex , but it was intented to be used by docker-compose....

2020-08-28 · 2 min · Boban Acimovic

Serving Single-Page Applications in Go

Someone may ask what is so special about serving single-page applications? Well, if you use hash (#) based URL’s like <em>https://yourdomain.com/#/yourroute</em> , there is no problem because browser recognize that this is a default page with some parameters and doesn’t make another request to the server. However, if you want to use non-hash based routes, there is a problem if you try to refresh a non-default route. In this case browser’s default action is to load such URL from the server and there is no such document on the server....

2020-05-03 · 3 min · Boban Acimovic

Generators, wait groups and closures in Golang

This is the first step of my intention to write a series of articles where I would explain some common patterns used in Golang. Let’s start with generator pattern : 1type Generator func() <-chan int Generator is a function or method which returns a sequence of values. In Golang, this usually means returning a channel of values of desired type. In our example, we will return a channel of integers. Let’s see an implementation of this:...

2019-10-04 · 5 min · Boban Acimovic