
Feature flags API in Go - antoineaugusti
https://github.com/AntoineAugusti/feature-flags
======
mitchellh
Hootsuite wrote a blog post on doing this sort of thing with Consul:
[http://code.hootsuite.com/distributed-configuration-
manageme...](http://code.hootsuite.com/distributed-configuration-management-
and-dark-launching-using-consul/) (The post itself is over a year old but the
concepts still apply today)

You can use the Go API client[1] to make this possible from Go. I'm biased as
I work for HashiCorp but just wanted to add a server-based option to the mix
if a local BoltDB won't work for you.

[1]:
[https://github.com/hashicorp/consul/tree/master/api](https://github.com/hashicorp/consul/tree/master/api)

------
enterprize2
The API usage is very inefficent when using it for every feature-flag in an
app. If you could call the API with user-ID and group and it returns all the
feature-flags active there would be a far greater use-case.

~~~
ares2012
Agreed. Launch Darkly has some interesting Feature Flag SDKs that do local
caching and other optimizations to reduce overhead.
[https://github.com/launchdarkly](https://github.com/launchdarkly)

~~~
mh-
first I'd seen LaunchDarkly.. looks very nice.

o/t, was checking out your blog and saw that you launched Outlier; congrats! I
was a big fan (and heavy user) of Flurry.. excited to see what comes of this.

~~~
UK-AL
Never heard of launch darkly either. Looks very nice for feature toggles.

------
collinvandyck76
Rollout flags are IMHO best implemented when they are pushed to the machines
that need to read them by a technology like zookeeper. Pushed updates are then
cached in memory by the machines receiving the updates and can be queried in
the hotpath without having to worry about cache invalidation and the extra
overhead of network calls.

~~~
justicezyx
This is so wrong. Flags should be treated as code.

------
jacobsimon
We've been working on something very similar at work. I don't know if this
solution scales very well, as others have mentioned here. One thing that seems
unusual to me is the decision to use a POST request instead of GET for the
/access endpoint.

~~~
antoineaugusti
Please look at this PR [https://github.com/AntoineAugusti/feature-
flags/pull/4](https://github.com/AntoineAugusti/feature-flags/pull/4)

