[GoLang] Adding FeatureFlags using github repo

Sarvsav Sharma
4 min readApr 17, 2023

What is feature flag?

There is a post by Martin Fowler on feature flag, and can be found here.

By 200degrees

In our last post: Self-Updating binaries for Go, we utilized the github platform to add a functionality in our go application for self update, and today, we will add one more tool in our arsenal of using powerful feature-flags by storing a file in github-repo.

Problem statement: Now, we have developed an application with rich of features, however, we want to test new features for a specific set of users before rolling out for everyone.

Premium services: There are paid services that provide this feature out of the box, like the configcat, launchdarkly, etc.

Opensource solution: gofeatureflag, sourcecode: github

go-feature-flag

How to use the go-feature-flag?

  1. Let’s start with an empty project. Source code for the project

--

--

Sarvsav Sharma

Mostly writes about Go, GitHub, and DevSecOps. Interested in distributed systems. GitHub:sarvsav Maintainer:go-feature-flag/gofeatureflag-lint-action