Project

rollout-zk

0.0
No commit activity in last 3 years
No release in over 3 years
A ZooKeeper storage adapter for rollout.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

>= 2.0
>= 0
 Project Readme

Zookeeper storage adapter for rollout

I've implemented a zookeeper-based storage adapter for rollout that does not require any network roundtrips to check if a feature is active for a user.

It uses zookeeper watches to store the entire dataset in memory (which will generally be very small) and updates the local cache as soon as anything changes.

If you haven't migrated to rollout v2, you can just use this :legacy_storage option and things will migrate to redis. If you have alerady migrated, it would take some manual work (that I think could be fairly easy to automate).

Usage

    $rollout = Rollout.new(
      Rollout::Zookeeper::Storage.new($zookeeper, "/rollout/users"),
      :legacy_storage => $redis, :migrate => true)

Items of note

  • it uses the zk gem
  • all settings are stored is a single znode
  • this will automatically migrate everything properly if you haven't migrated to rollout v2 yet