flipper 0.17.1 → 0.21.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +57 -0
- data/Changelog.md +114 -1
- data/Dockerfile +1 -1
- data/Gemfile +3 -6
- data/README.md +103 -47
- data/Rakefile +1 -4
- data/docs/Adapters.md +9 -9
- data/docs/Caveats.md +2 -2
- data/docs/DockerCompose.md +0 -1
- data/docs/Gates.md +74 -74
- data/docs/Optimization.md +70 -47
- data/docs/http/README.md +12 -11
- data/docs/images/banner.jpg +0 -0
- data/docs/read-only/README.md +8 -5
- data/examples/basic.rb +1 -12
- data/examples/configuring_default.rb +2 -5
- data/examples/dsl.rb +13 -24
- data/examples/enabled_for_actor.rb +8 -15
- data/examples/group.rb +3 -6
- data/examples/group_dynamic_lookup.rb +5 -19
- data/examples/group_with_members.rb +4 -14
- data/examples/importing.rb +1 -1
- data/examples/individual_actor.rb +2 -5
- data/examples/instrumentation.rb +1 -2
- data/examples/memoizing.rb +35 -0
- data/examples/percentage_of_actors.rb +6 -16
- data/examples/percentage_of_actors_enabled_check.rb +7 -10
- data/examples/percentage_of_actors_group.rb +5 -18
- data/examples/percentage_of_time.rb +3 -6
- data/flipper.gemspec +3 -4
- data/lib/flipper.rb +7 -3
- data/lib/flipper/adapters/dual_write.rb +67 -0
- data/lib/flipper/adapters/http.rb +32 -28
- data/lib/flipper/adapters/memory.rb +23 -94
- data/lib/flipper/adapters/operation_logger.rb +5 -0
- data/lib/flipper/adapters/pstore.rb +8 -1
- data/lib/flipper/adapters/sync.rb +7 -7
- data/lib/flipper/adapters/sync/interval_synchronizer.rb +1 -1
- data/lib/flipper/adapters/sync/synchronizer.rb +1 -0
- data/lib/flipper/configuration.rb +33 -7
- data/lib/flipper/dsl.rb +8 -0
- data/lib/flipper/errors.rb +2 -3
- data/lib/flipper/feature.rb +2 -2
- data/lib/flipper/identifier.rb +17 -0
- data/lib/flipper/middleware/memoizer.rb +30 -15
- data/lib/flipper/middleware/setup_env.rb +13 -3
- data/lib/flipper/railtie.rb +38 -0
- data/lib/flipper/spec/shared_adapter_specs.rb +15 -0
- data/lib/flipper/test/shared_adapter_test.rb +16 -1
- data/lib/flipper/version.rb +1 -1
- data/spec/flipper/adapter_spec.rb +2 -2
- data/spec/flipper/adapters/dual_write_spec.rb +71 -0
- data/spec/flipper/adapters/http_spec.rb +74 -8
- data/spec/flipper/adapters/memory_spec.rb +21 -1
- data/spec/flipper/adapters/operation_logger_spec.rb +9 -0
- data/spec/flipper/adapters/sync_spec.rb +4 -4
- data/spec/flipper/configuration_spec.rb +20 -2
- data/spec/flipper/feature_spec.rb +5 -5
- data/spec/flipper/identifier_spec.rb +14 -0
- data/spec/flipper/middleware/memoizer_spec.rb +95 -35
- data/spec/flipper/middleware/setup_env_spec.rb +23 -3
- data/spec/flipper/railtie_spec.rb +69 -0
- data/spec/{integration_spec.rb → flipper_integration_spec.rb} +0 -0
- data/spec/flipper_spec.rb +26 -0
- data/spec/helper.rb +3 -3
- data/spec/support/descriptions.yml +1 -0
- data/spec/support/spec_helpers.rb +25 -0
- data/test/test_helper.rb +2 -1
- metadata +19 -10
- data/.rubocop.yml +0 -52
- data/.rubocop_todo.yml +0 -562
- data/examples/example_setup.rb +0 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 25b07936734df32fbd0331822a97059e76ee9919db287e1073c15b338afc5924
|
4
|
+
data.tar.gz: 221fbb5002318b366d022365b7597f23094d2b50215e9545d3e1c2435faa03ec
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4529f945a2c71a3c776940cc091e48280e5088e080c203d478aca91e94e52855d4b5c912bae8aad2b7ca95248f42cabf62599a67f307fc98c34faf46c6361bf1
|
7
|
+
data.tar.gz: 3fed3febaf673456551dea59b13b01777f9f59f9ee267424547b495b4d7f06a7cc5c50521431ef29260585c01f93e05f2c1c30c4e55d5833cfb1cb40fccfb7c3
|
@@ -0,0 +1,57 @@
|
|
1
|
+
name: CI
|
2
|
+
on:
|
3
|
+
push:
|
4
|
+
branches: [master]
|
5
|
+
pull_request:
|
6
|
+
jobs:
|
7
|
+
build:
|
8
|
+
runs-on: ubuntu-latest
|
9
|
+
services:
|
10
|
+
redis:
|
11
|
+
image: redis
|
12
|
+
ports: ['6379:6379']
|
13
|
+
options: >-
|
14
|
+
--health-cmd "redis-cli ping"
|
15
|
+
--health-interval 10s
|
16
|
+
--health-timeout 5s
|
17
|
+
--health-retries 5
|
18
|
+
strategy:
|
19
|
+
matrix:
|
20
|
+
ruby: ['2.5', '2.6', '2.7']
|
21
|
+
env:
|
22
|
+
RAILS_VERSION: 6.0.0
|
23
|
+
SQLITE3_VERSION: 1.4.1
|
24
|
+
REDIS_URL: redis://localhost:6379/0
|
25
|
+
CI: true
|
26
|
+
steps:
|
27
|
+
- name: Setup memcached
|
28
|
+
uses: KeisukeYamashita/memcached-actions@v1
|
29
|
+
- name: Start MongoDB
|
30
|
+
uses: supercharge/mongodb-github-action@1.3.0
|
31
|
+
with:
|
32
|
+
mongodb-version: 4.0
|
33
|
+
- name: Check out repository code
|
34
|
+
uses: actions/checkout@v2
|
35
|
+
- name: Do some action caching
|
36
|
+
uses: actions/cache@v1
|
37
|
+
with:
|
38
|
+
path: vendor/bundle
|
39
|
+
key: ${{ runner.os }}-gem-${{ hashFiles('**/Gemfile.lock') }}
|
40
|
+
restore-keys: |
|
41
|
+
${{ runner.os }}-gem-
|
42
|
+
- name: Set up Ruby
|
43
|
+
uses: actions/setup-ruby@v1
|
44
|
+
with:
|
45
|
+
ruby-version: ${{ matrix.ruby }}
|
46
|
+
- name: Install libpq-dev
|
47
|
+
run: sudo apt-get -yqq install libpq-dev
|
48
|
+
- name: Install bundler
|
49
|
+
run: gem install bundler
|
50
|
+
- name: Run bundler
|
51
|
+
run: bundle install --jobs 4 --retry 3
|
52
|
+
- name: Run Rake
|
53
|
+
run: bundle exec rake
|
54
|
+
- name: Run Examples
|
55
|
+
env:
|
56
|
+
FLIPPER_CLOUD_TOKEN: ${{ secrets.FLIPPER_CLOUD_TOKEN }}
|
57
|
+
run: script/examples
|
data/Changelog.md
CHANGED
@@ -1,3 +1,116 @@
|
|
1
|
+
## 0.21.0
|
2
|
+
|
3
|
+
### Additions/Changes
|
4
|
+
|
5
|
+
* Default to using memory adapter (https://github.com/jnunemaker/flipper/pull/501)
|
6
|
+
* Adapters now configured on require when possible (https://github.com/jnunemaker/flipper/pull/502)
|
7
|
+
* Added cloud recommendation to flipper-ui. Can be disabled with `Flipper::UI.configure { |config| config.cloud_recommendation = false }`. Just want to raise awareness that more is available if people want it (https://github.com/jnunemaker/flipper/pull/504)
|
8
|
+
* Added default `flipper_id` implementation via `Flipper::Identifier` and automatically included it in ActiveRecord and Sequel models (https://github.com/jnunemaker/flipper/pull/505)
|
9
|
+
* Deprecate superflous sync_method setting (https://github.com/jnunemaker/flipper/pull/511)
|
10
|
+
* Flipper is now pre-configured when used with Rails. By default, it will [memoize and preload all features for each request](docs/Optimization.md#memoization). (https://github.com/jnunemaker/flipper/pull/506)
|
11
|
+
|
12
|
+
### Upgrading
|
13
|
+
|
14
|
+
You should be able to upgrade to 0.21 without any breaking changes. However, if you want to simplify your setup, you can remove some configuration that is now handled automatically:
|
15
|
+
|
16
|
+
1. Adapters are configured when on require, so unless you are using caching or other customizations, you can remove adapter configuration.
|
17
|
+
|
18
|
+
```diff
|
19
|
+
# config/initializers/flipper.rb
|
20
|
+
- Flipper.configure do |config|
|
21
|
+
- config.default { Flipper.new(Flipper::Adapters::ActiveRecord.new) }
|
22
|
+
- end
|
23
|
+
```
|
24
|
+
|
25
|
+
2. `Flipper::Middleware::Memoizer` will be enabled by default.
|
26
|
+
|
27
|
+
```diff
|
28
|
+
# config/initializers/flipper.rb
|
29
|
+
- Rails.configuration.middleware.use Flipper::Middleware::Memoizer,
|
30
|
+
- preload: [:stats, :search, :some_feature]
|
31
|
+
+ Rails.application.configure do
|
32
|
+
+ # Uncomment to configure which features to preload on all requests
|
33
|
+
+ # config.flipper.preload = [:stats, :search, :some_feature]
|
34
|
+
+ end
|
35
|
+
```
|
36
|
+
|
37
|
+
3. `#flipper_id`, which is used to enable features for specific actors, is now defined by [Flipper::Identifier](lib/flipper/identifier.rb) on all ActiveRecord and Sequel models. You can remove your implementation if it is in the form of `ModelName;id`.
|
38
|
+
|
39
|
+
4. When using `flipper-cloud`, The `Flipper::Cloud.app` webhook receiver is now mounted at `/_flipper` by default.
|
40
|
+
|
41
|
+
```diff
|
42
|
+
# config/routes.rb
|
43
|
+
- mount Flipper::Cloud.app, at: "/_flipper"
|
44
|
+
```
|
45
|
+
|
46
|
+
## 0.20.4
|
47
|
+
|
48
|
+
### Additions/Changes
|
49
|
+
|
50
|
+
* Allow actors and time gates to deal with decimal percentages (https://github.com/jnunemaker/flipper/pull/492)
|
51
|
+
* Change Flipper::Cloud::Middleware to receive webhooks at / in addition to /webhooks.
|
52
|
+
* Add `write_through` option to ActiveSupportCacheStore adapter to support write-through caching (https://github.com/jnunemaker/flipper/pull/512)
|
53
|
+
|
54
|
+
## 0.20.3
|
55
|
+
|
56
|
+
### Additions/Changes
|
57
|
+
|
58
|
+
* Changed the internal structure of how the memory adapter stores things.
|
59
|
+
|
60
|
+
## 0.20.2
|
61
|
+
|
62
|
+
### Additions/Changes
|
63
|
+
|
64
|
+
* Http adapter now raises error when enable/disable/add/remove/clear fail.
|
65
|
+
* Cloud adapter sends some extra info like hostname, ruby version, etc. for debugging and decision making.
|
66
|
+
|
67
|
+
## 0.20.1
|
68
|
+
|
69
|
+
### Additions/Changes
|
70
|
+
|
71
|
+
* Just a minor tweak to cloud webhook middleware to provide more debugging information about why a hook wasn't successful.
|
72
|
+
|
73
|
+
## 0.20.0
|
74
|
+
|
75
|
+
### Additions/Changes
|
76
|
+
|
77
|
+
* Add support for webhooks to `Flipper::Cloud` (https://github.com/jnunemaker/flipper/pull/489).
|
78
|
+
|
79
|
+
## 0.19.1
|
80
|
+
|
81
|
+
### Additions/Changes
|
82
|
+
|
83
|
+
* Bump rack-protection version to < 2.2 (https://github.com/jnunemaker/flipper/pull/487)
|
84
|
+
* Add memoizer_options to Flipper::Api.app (https://github.com/jnunemaker/flipper/commit/174ad4bb94046a25c432d3c53fe1ff9f5a76d838)
|
85
|
+
|
86
|
+
## 0.19.0
|
87
|
+
|
88
|
+
### Additions/Changes
|
89
|
+
|
90
|
+
* 100% of actors is now considered conditional. Feature#on?, Feature#conditional?, Feature#state would all be affected. See https://github.com/jnunemaker/flipper/issues/463 for more.
|
91
|
+
* Several doc updates.
|
92
|
+
|
93
|
+
## 0.18.0
|
94
|
+
|
95
|
+
### Additions/Changes
|
96
|
+
|
97
|
+
* Add support for feature descriptions to flipper-ui (https://github.com/jnunemaker/flipper/pull/461).
|
98
|
+
* Remove rubocop (https://github.com/jnunemaker/flipper/pull/469).
|
99
|
+
* flipper-ui redesign (https://github.com/jnunemaker/flipper/pull/470).
|
100
|
+
* Removed support for ruby 2.4.
|
101
|
+
* Added support for ruby 2.7.
|
102
|
+
* Removed support for Rails 4.x.x.
|
103
|
+
* Removed support for customizing actors, groups, % of actors and % of time text in flipper-ui in favor of automatic and more descriptive text.
|
104
|
+
|
105
|
+
## 0.17.2
|
106
|
+
|
107
|
+
### Additions/Changes
|
108
|
+
|
109
|
+
* Avoid errors on import when there are no features and shared specs/tests for get all with no features (https://github.com/jnunemaker/flipper/pull/441 and https://github.com/jnunemaker/flipper/pull/442)
|
110
|
+
* ::ActiveRecord::RecordNotUnique > ActiveRecord::RecordNotUnique (https://github.com/jnunemaker/flipper/pull/444)
|
111
|
+
* Clear gate values on enable (https://github.com/jnunemaker/flipper/pull/454)
|
112
|
+
* Remove use of multi from redis adapter (https://github.com/jnunemaker/flipper/pull/451)
|
113
|
+
|
1
114
|
## 0.17.1
|
2
115
|
|
3
116
|
* Fix require in flipper-active_record (https://github.com/jnunemaker/flipper/pull/437)
|
@@ -81,7 +194,7 @@
|
|
81
194
|
|
82
195
|
### Additions/Changes
|
83
196
|
|
84
|
-
* Added rollout adapter documentation (https://github.com/jnunemaker/flipper/pull/328).
|
197
|
+
* Added rollout adapter documentation (https://github.com/jnunemaker/flipper/pull/328).
|
85
198
|
|
86
199
|
### Bug Fixes
|
87
200
|
|
data/Dockerfile
CHANGED
data/Gemfile
CHANGED
@@ -12,20 +12,17 @@ gem 'shotgun', '~> 0.9'
|
|
12
12
|
gem 'statsd-ruby', '~> 1.2.1'
|
13
13
|
gem 'rspec', '~> 3.0'
|
14
14
|
gem 'rack-test', '~> 0.6.3'
|
15
|
-
gem 'sqlite3', "~> #{ENV['SQLITE3_VERSION'] || '1.
|
15
|
+
gem 'sqlite3', "~> #{ENV['SQLITE3_VERSION'] || '1.4.1'}"
|
16
16
|
gem 'rails', "~> #{ENV['RAILS_VERSION'] || '6.0.0'}"
|
17
17
|
gem 'minitest', '~> 5.8'
|
18
18
|
gem 'minitest-documentation'
|
19
|
-
gem 'rubocop'
|
20
|
-
gem 'rubocop-rspec'
|
21
19
|
gem 'webmock', '~> 3.0'
|
20
|
+
gem 'climate_control'
|
21
|
+
gem 'redis-namespace'
|
22
22
|
|
23
23
|
group(:guard) do
|
24
24
|
gem 'guard', '~> 2.15'
|
25
|
-
gem 'guard-rubocop', '~> 1.3'
|
26
25
|
gem 'guard-rspec', '~> 4.5'
|
27
26
|
gem 'guard-bundler', '~> 2.2'
|
28
|
-
gem 'guard-coffeescript', '~> 2.0'
|
29
|
-
gem 'guard-sass', '~> 1.6'
|
30
27
|
gem 'rb-fsevent', '~> 0.9'
|
31
28
|
end
|
data/README.md
CHANGED
@@ -1,23 +1,17 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
~---~~~~----~~~~ ~~
|
16
|
-
</pre>
|
17
|
-
|
18
|
-
Feature flipping is the act of enabling or disabling features or parts of your application, ideally without re-deploying or changing anything in your code base.
|
19
|
-
|
20
|
-
The goal of this gem is to make turning features on or off so easy that everyone does it. Whatever your data store, throughput, or experience, feature flipping should be easy and have minimal impact on your application.
|
1
|
+
[![Flipper Mark](docs/images/banner.jpg)](https://www.flippercloud.io)
|
2
|
+
|
3
|
+
# Flipper
|
4
|
+
|
5
|
+
> Beautiful, performant feature flags for Ruby.
|
6
|
+
|
7
|
+
Flipper gives you control over who has access to features in your app.
|
8
|
+
|
9
|
+
* Enable or disable features for everyone, specific actors, groups of actors, a percentage of actors, or a percentage of time.
|
10
|
+
* Configure your feature flags from the console or a web UI.
|
11
|
+
* Regardless of what data store you are using, Flipper can performantly store your feature flags.
|
12
|
+
* Use [Flipper Cloud](#flipper-cloud) to cascade features from multiple environments, share settings with your team, control permissions, keep an audit history, and rollback.
|
13
|
+
|
14
|
+
Control your software — don't let it control you.
|
21
15
|
|
22
16
|
## Installation
|
23
17
|
|
@@ -25,6 +19,10 @@ Add this line to your application's Gemfile:
|
|
25
19
|
|
26
20
|
gem 'flipper'
|
27
21
|
|
22
|
+
You'll also want to pick a storage [adapter](#adapters), for example:
|
23
|
+
|
24
|
+
gem 'flipper-active_record'
|
25
|
+
|
28
26
|
And then execute:
|
29
27
|
|
30
28
|
$ bundle
|
@@ -33,50 +31,108 @@ Or install it yourself with:
|
|
33
31
|
|
34
32
|
$ gem install flipper
|
35
33
|
|
36
|
-
##
|
34
|
+
## Getting Started
|
37
35
|
|
38
|
-
|
36
|
+
Use `Flipper#enabled?` in your app to check if a feature is enabled.
|
39
37
|
|
40
38
|
```ruby
|
41
|
-
require 'flipper'
|
42
|
-
|
43
|
-
Flipper.configure do |config|
|
44
|
-
config.default do
|
45
|
-
# pick an adapter, this uses memory, any will do
|
46
|
-
adapter = Flipper::Adapters::Memory.new
|
47
|
-
|
48
|
-
# pass adapter to handy DSL instance
|
49
|
-
Flipper.new(adapter)
|
50
|
-
end
|
51
|
-
end
|
52
|
-
|
53
39
|
# check if search is enabled
|
54
|
-
if Flipper.enabled?
|
40
|
+
if Flipper.enabled? :search, current_user
|
55
41
|
puts 'Search away!'
|
56
42
|
else
|
57
43
|
puts 'No search for you!'
|
58
44
|
end
|
45
|
+
```
|
59
46
|
|
60
|
-
|
61
|
-
Flipper.enable(:search)
|
47
|
+
All features are disabled by default, so you'll need to explicitly enable them.
|
62
48
|
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
49
|
+
#### Enable a feature for everyone
|
50
|
+
|
51
|
+
```ruby
|
52
|
+
Flipper.enable :search
|
53
|
+
```
|
54
|
+
|
55
|
+
#### Enable a feature for a specific actor
|
56
|
+
|
57
|
+
```ruby
|
58
|
+
Flipper.enable_actor :search, current_user
|
59
|
+
```
|
60
|
+
|
61
|
+
#### Enable a feature for a group of actors
|
62
|
+
|
63
|
+
First tell Flipper about your groups:
|
64
|
+
|
65
|
+
```ruby
|
66
|
+
# config/initializers/flipper.rb
|
67
|
+
Flipper.register(:admin) do |actor|
|
68
|
+
actor.respond_to?(:admin?) && actor.admin?
|
68
69
|
end
|
69
70
|
```
|
70
71
|
|
71
|
-
|
72
|
+
Then enable the feature for that group:
|
73
|
+
|
74
|
+
```ruby
|
75
|
+
Flipper.enable_group :search, :admin
|
76
|
+
```
|
77
|
+
|
78
|
+
#### Enable a feature for a percentage of actors
|
79
|
+
|
80
|
+
```ruby
|
81
|
+
Flipper.enable_percentage_of_actors :search, 2
|
82
|
+
```
|
83
|
+
|
84
|
+
|
85
|
+
Read more about enabling and disabling features with [Gates](docs/Gates.md). Check out the [examples directory](examples/) for more, and take a peek at the [DSL](lib/flipper/dsl.rb) and [Feature](lib/flipper/feature.rb) classes for code/docs.
|
86
|
+
|
87
|
+
## Adapters
|
88
|
+
|
89
|
+
Flipper is built on adapters for maximum flexibility. Regardless of what data store you are using, Flipper can performantly store data in it.
|
90
|
+
|
91
|
+
Pick one of our [supported adapters](docs/Adapters.md#officially-supported) and follow the installation instructions:
|
92
|
+
|
93
|
+
* [Active Record](docs/active_record/README.md)
|
94
|
+
* [Sequel](docs/sequel/README.md)
|
95
|
+
* [Redis](docs/redis/README.md)
|
96
|
+
* [Mongo](docs/mongo/README.md)
|
97
|
+
* [Moneta](docs/moneta/README.md)
|
98
|
+
* [Rollout](docs/rollout/README.md)
|
99
|
+
|
100
|
+
Or [roll your own](docs/Adapters.md#roll-your-own). We even provide automatic (rspec and minitest) tests for you, so you know you've built your custom adapter correctly.
|
101
|
+
|
102
|
+
Read more about [Adapters](docs/Adapters.md).
|
103
|
+
|
104
|
+
## Flipper UI
|
105
|
+
|
106
|
+
If you prefer a web UI to an IRB console, you can setup the [Flipper UI](docs/ui/README.md).
|
107
|
+
|
108
|
+
It's simple and pretty.
|
109
|
+
|
110
|
+
![Flipper UI Screenshot](docs/ui/images/feature.png)
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
## Flipper Cloud
|
115
|
+
|
116
|
+
Or, (even better than OSS + UI) use [Flipper Cloud](https://www.flippercloud.io) which comes with:
|
117
|
+
|
118
|
+
* **everything in one place** — no need to bounce around from different application UIs or IRB consoles.
|
119
|
+
* **permissions** — grant access to everyone in your organization or lockdown each project to particular people.
|
120
|
+
* **multiple environments** — production, staging, enterprise, by continent, whatever you need.
|
121
|
+
* **personal environments** — no more rake scripts or manual enable/disable to get your laptop to look like production. Every developer gets a personal environment that inherits from production that they can override as they please ([read more](https://www.johnnunemaker.com/flipper-cloud-environments/)).
|
122
|
+
* **no maintenance** — we'll keep the lights on for you. We also have handy webhooks for keeping your app in sync with Cloud, so **our availability won't affect yours**. All your feature flag reads are local to your app.
|
123
|
+
* **audit history** — every feature change and who made it.
|
124
|
+
* **rollbacks** — enable or disable a feature accidentally? No problem. You can roll back to any point in the audit history with a single click.
|
125
|
+
|
126
|
+
[![Flipper Cloud Screenshot](docs/images/flipper_cloud.png)](https://www.flippercloud.io)
|
127
|
+
|
128
|
+
Cloud is super simple to integrate with Rails ([demo app](https://github.com/fewerandfaster/flipper-rails-demo)), Sinatra or any other framework.
|
129
|
+
|
130
|
+
## Advanced
|
72
131
|
|
73
|
-
|
132
|
+
A few miscellaneous docs with more info for the hungry.
|
74
133
|
|
75
|
-
* [Gates](docs/Gates.md) - Boolean, Groups, Actors, % of Actors, and % of Time
|
76
|
-
* [Adapters](docs/Adapters.md) - Mongo, Redis, Cassandra, Active Record...
|
77
134
|
* [Instrumentation](docs/Instrumentation.md) - ActiveSupport::Notifications and Statsd
|
78
135
|
* [Optimization](docs/Optimization.md) - Memoization middleware and Cache adapters
|
79
|
-
* [Web Interface](docs/ui/README.md) - Point and click...
|
80
136
|
* [API](docs/api/README.md) - HTTP API interface
|
81
137
|
* [Caveats](docs/Caveats.md) - Flipper beware! (see what I did there)
|
82
138
|
* [Docker-Compose](docs/DockerCompose.md) - Using docker-compose in contributing
|
data/Rakefile
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
#!/usr/bin/env rake
|
2
2
|
$LOAD_PATH.push File.expand_path('../lib', __FILE__)
|
3
3
|
require 'rake/testtask'
|
4
|
-
require 'rubocop/rake_task'
|
5
4
|
require 'flipper/version'
|
6
5
|
|
7
6
|
# gem install pkg/*.gem
|
@@ -50,6 +49,4 @@ Rake::TestTask.new(:test_rails) do |t|
|
|
50
49
|
t.warning = false
|
51
50
|
end
|
52
51
|
|
53
|
-
|
54
|
-
|
55
|
-
task default: [:spec, :test, :test_rails, :rubocop]
|
52
|
+
task default: [:spec, :test, :test_rails]
|
data/docs/Adapters.md
CHANGED
@@ -4,17 +4,17 @@ I plan on supporting the adapters in the flipper repo. Other adapters are welcom
|
|
4
4
|
|
5
5
|
## Officially Supported
|
6
6
|
|
7
|
-
* [ActiveRecord adapter](https://github.com/jnunemaker/flipper/blob/master/docs/active_record) - Rails
|
8
|
-
* [
|
9
|
-
* [
|
10
|
-
* [Http adapter](https://github.com/jnunemaker/flipper/blob/master/docs/http)
|
11
|
-
* [memory adapter](https://github.com/jnunemaker/flipper/blob/master/lib/flipper/adapters/memory.rb) – great for tests
|
12
|
-
* [Moneta adapter](https://github.com/jnunemaker/flipper/blob/master/docs/moneta)
|
7
|
+
* [ActiveRecord adapter](https://github.com/jnunemaker/flipper/blob/master/docs/active_record) - Rails 5 and 6.
|
8
|
+
* [Sequel adapter](https://github.com/jnunemaker/flipper/blob/master/docs/sequel)
|
9
|
+
* [Redis adapter](https://github.com/jnunemaker/flipper/blob/master/docs/redis)
|
13
10
|
* [Mongo adapter](https://github.com/jnunemaker/flipper/blob/master/docs/mongo)
|
14
11
|
* [PStore adapter](https://github.com/jnunemaker/flipper/blob/master/lib/flipper/adapters/pstore.rb) – great for when a local file is enough
|
15
|
-
* [
|
16
|
-
* [
|
17
|
-
* [
|
12
|
+
* [Http adapter](https://github.com/jnunemaker/flipper/blob/master/docs/http) - great for using with `Flipper::Api`
|
13
|
+
* [Moneta adapter](https://github.com/jnunemaker/flipper/blob/master/docs/moneta) - great for a variety of data stores
|
14
|
+
* [ActiveSupportCacheStore adapter](https://github.com/jnunemaker/flipper/blob/master/docs/active_support_cache_store) - great for Rails caching
|
15
|
+
* [Memory adapter](https://github.com/jnunemaker/flipper/blob/master/lib/flipper/adapters/memory.rb) – great for tests
|
16
|
+
* [Read-only adapter](https://github.com/jnunemaker/flipper/blob/master/docs/read-only) - great for preventing writes from production console
|
17
|
+
* [Rollout adapter](rollout/README.md) - great for switching from rollout to flipper
|
18
18
|
|
19
19
|
## Community Supported
|
20
20
|
|