unleash 3.2.2 → 3.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/README.md +1 -1
- data/examples/simple.rb +2 -2
- data/lib/unleash/client.rb +1 -1
- data/lib/unleash/configuration.rb +2 -2
- data/lib/unleash/toggle_fetcher.rb +1 -1
- data/lib/unleash/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f1535ef477a380d94767952c3d4a660ab029bf78100f7d30246ff211517172f2
|
4
|
+
data.tar.gz: b357d2bda18a9b1378988d4467b78cbe02129b519578272da7fd0259cada97d0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e1fe0ae8b8ff86fdbe3c0d9a68b0d559112a9d568bcb8762f946d191b33ee8bdcd25bad63983d6b507269534309690fc2f858c5989b287004e5df2a3b8755e36
|
7
|
+
data.tar.gz: 8e05aeb05427eaa6e0391703aa524902c3094be21c176a374093ec5263b2a2fcc4b9bce4ab2fb9627d18ecf822dfbd1f8cfecaaba8a9517ae96f9efd687ab1a8
|
data/.gitignore
CHANGED
data/README.md
CHANGED
data/examples/simple.rb
CHANGED
@@ -17,13 +17,13 @@ puts ">> START simple.rb"
|
|
17
17
|
# or:
|
18
18
|
|
19
19
|
@unleash = Unleash::Client.new(
|
20
|
-
url: '
|
20
|
+
url: 'https://app.unleash-hosted.com/demo/api',
|
21
21
|
app_name: 'simple-test',
|
22
22
|
instance_id: 'local-test-cli',
|
23
23
|
refresh_interval: 2,
|
24
24
|
metrics_interval: 2,
|
25
25
|
retry_limit: 2,
|
26
|
-
|
26
|
+
custom_http_headers: {'Authorization': '943ca9171e2c884c545c5d82417a655fb77cec970cc3b78a8ff87f4406b495d0'},
|
27
27
|
)
|
28
28
|
|
29
29
|
# feature_name = "AwesomeFeature"
|
data/lib/unleash/client.rb
CHANGED
@@ -60,7 +60,7 @@ module Unleash
|
|
60
60
|
Unleash.logger.debug "Unleash::Client.get_variant for feature: #{feature} with context #{context}"
|
61
61
|
|
62
62
|
if Unleash.configuration.disable_client
|
63
|
-
Unleash.logger.debug "unleash_client is disabled! Always returning #{
|
63
|
+
Unleash.logger.debug "unleash_client is disabled! Always returning #{fallback_variant} for feature #{feature}!"
|
64
64
|
return fallback_variant || Unleash::FeatureToggle.disabled_variant
|
65
65
|
end
|
66
66
|
|
@@ -78,8 +78,8 @@ module Unleash
|
|
78
78
|
self.instance_id = SecureRandom.uuid
|
79
79
|
self.disable_client = false
|
80
80
|
self.disable_metrics = false
|
81
|
-
self.refresh_interval =
|
82
|
-
self.metrics_interval =
|
81
|
+
self.refresh_interval = 10
|
82
|
+
self.metrics_interval = 30
|
83
83
|
self.timeout = 30
|
84
84
|
self.retry_limit = 1
|
85
85
|
self.backup_file = nil
|
@@ -48,7 +48,7 @@ module Unleash
|
|
48
48
|
self.etag = response['ETag']
|
49
49
|
response_hash = JSON.parse(response.body)
|
50
50
|
|
51
|
-
if response_hash['version']
|
51
|
+
if response_hash['version'] >= 1
|
52
52
|
features = response_hash['features']
|
53
53
|
else
|
54
54
|
raise NotImplemented, "Version of features provided by unleash server" \
|
data/lib/unleash/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: unleash
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.2.
|
4
|
+
version: 3.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Renato Arruda
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-10-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: murmurhash3
|
@@ -175,7 +175,7 @@ homepage: https://github.com/unleash/unleash-client-ruby
|
|
175
175
|
licenses:
|
176
176
|
- Apache-2.0
|
177
177
|
metadata: {}
|
178
|
-
post_install_message:
|
178
|
+
post_install_message:
|
179
179
|
rdoc_options: []
|
180
180
|
require_paths:
|
181
181
|
- lib
|
@@ -191,7 +191,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
191
191
|
version: '0'
|
192
192
|
requirements: []
|
193
193
|
rubygems_version: 3.2.3
|
194
|
-
signing_key:
|
194
|
+
signing_key:
|
195
195
|
specification_version: 4
|
196
196
|
summary: Unleash feature toggle client.
|
197
197
|
test_files: []
|