splitclient-rb 8.1.1.pre.rc1 → 8.1.1.pre.rc3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES.txt +5 -0
- data/lib/splitclient-rb/cache/adapters/redis_adapter.rb +1 -1
- data/lib/splitclient-rb/cache/senders/impressions_adapter/redis_sender.rb +15 -6
- data/lib/splitclient-rb/split_config.rb +1 -1
- data/lib/splitclient-rb/telemetry/domain/structs.rb +4 -3
- data/lib/splitclient-rb/telemetry/memory/memory_synchronizer.rb +2 -1
- data/lib/splitclient-rb/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bd080651012addd19857407fc736636f9efe6a63dc81bf729d1fee4476ffc378
|
4
|
+
data.tar.gz: c2f7567e89777d23a950f25dfe67948858226c5ebbe0e497afcde48150440997
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 22a8b4aae91df29d09a9a6c0b71f198a0997e2b5c237ae3f3963d922dcd9874a4cea1ed52d85707bd733501c77968a515c9e435ac77340f72480cc5cf0da316c
|
7
|
+
data.tar.gz: '0569443f03eeff1c21f44cbdae8d238a8162584fe36f5e62144cddd3abd134d80f96ae4e27375f551df27b8437f838fabf427a35dea192ee7f64cba50f47544d'
|
data/CHANGES.txt
CHANGED
@@ -1,5 +1,10 @@
|
|
1
1
|
CHANGES
|
2
2
|
|
3
|
+
8.1.1 (Mar 17, 2023)
|
4
|
+
- Added retries with backoff when the sdk tries to connect to the Streaming service and it is not available.
|
5
|
+
- Updated the way that the sdk write mtks in redis.
|
6
|
+
- Fixed calculation of timeUntilReady in telemetry.
|
7
|
+
|
3
8
|
8.1.0 (Oct 5, 2022)
|
4
9
|
- Added a new impressions mode for the SDK called NONE , to be used in factory when there is no desire to capture impressions on an SDK factory to feed Split's analytics engine. Running NONE mode, the SDK will only capture unique keys evaluated for a particular feature flag instead of full blown impressions.
|
5
10
|
|
@@ -12,14 +12,11 @@ module SplitIoClient
|
|
12
12
|
end
|
13
13
|
|
14
14
|
def record_uniques_key(uniques)
|
15
|
-
return if uniques.nil? || uniques
|
15
|
+
return if uniques.nil? || uniques.empty?
|
16
16
|
|
17
|
-
size =
|
18
|
-
uniques.each do |key, value|
|
19
|
-
size = @adapter.add_to_queue(unique_keys_key, { f: key, ks: value.to_a }.to_json)
|
20
|
-
end
|
17
|
+
size = @adapter.add_to_queue(unique_keys_key, uniques_formatter(uniques))
|
21
18
|
|
22
|
-
@adapter.expire(unique_keys_key, EXPIRE_SECONDS) if uniques.length == size
|
19
|
+
@adapter.expire(unique_keys_key, EXPIRE_SECONDS) if uniques.length == size.last
|
23
20
|
rescue StandardError => e
|
24
21
|
@config.log_found_exception(__method__.to_s, e)
|
25
22
|
end
|
@@ -47,6 +44,18 @@ module SplitIoClient
|
|
47
44
|
@adapter.expire(impressions_count_key, EXPIRE_SECONDS) if impressions_count.size == hlen && (pipeline_result.sum - hlen) == total_count
|
48
45
|
end
|
49
46
|
|
47
|
+
def uniques_formatter(uniques)
|
48
|
+
to_return = []
|
49
|
+
uniques.each do |key, value|
|
50
|
+
to_return << {
|
51
|
+
f: key,
|
52
|
+
ks: value.to_a
|
53
|
+
}.to_json
|
54
|
+
end
|
55
|
+
|
56
|
+
to_return
|
57
|
+
end
|
58
|
+
|
50
59
|
def impressions_count_key
|
51
60
|
"#{@config.redis_namespace}.impressions.count"
|
52
61
|
end
|
@@ -117,7 +117,7 @@ module SplitIoClient
|
|
117
117
|
|
118
118
|
@counter_refresh_rate = SplitConfig.default_counter_refresh_rate(@cache_adapter)
|
119
119
|
|
120
|
-
@sdk_start_time = Time.now
|
120
|
+
@sdk_start_time = Time.now.to_f
|
121
121
|
|
122
122
|
@on_demand_fetch_retry_delay_seconds = SplitConfig.default_on_demand_fetch_retry_delay_seconds
|
123
123
|
@on_demand_fetch_max_retries = SplitConfig.default_on_demand_fetch_max_retries
|
@@ -13,9 +13,10 @@ module SplitIoClient
|
|
13
13
|
# s: sdkUrl, e: eventsUrl, a: authUrl, st: streamUrl, t: telemetryUrl
|
14
14
|
UrlOverrides = Struct.new(:s, :e, :a, :st, :t)
|
15
15
|
|
16
|
-
# om: operationMode,
|
17
|
-
#
|
18
|
-
#
|
16
|
+
# om: operationMode, st: storage, af: activeFactories, rf: redundantActiveFactories, t: tags, se: streamingEnabled,
|
17
|
+
# rr: refreshRate, uo: urlOverrides, iq: impressionsQueueSize, eq: eventsQueueSize, im: impressionsMode,
|
18
|
+
# il: impressionListenerEnabled, hp: httpProxyDetected, tr: timeUntilSdkReady, bt: burTimeouts,
|
19
|
+
# nr: sdkNotReadyUsage, i: integrations
|
19
20
|
ConfigInit = Struct.new(:om, :st, :af, :rf, :t, :se, :rr, :uo, :iq, :eq, :im, :il, :hp, :tr, :bt, :nr, :i)
|
20
21
|
|
21
22
|
# ls: lastSynchronization, ml: clientMethodLatencies, me: clientMethodExceptions, he: httpErros, hl: httpLatencies,
|
@@ -56,6 +56,7 @@ module SplitIoClient
|
|
56
56
|
|
57
57
|
active_factories ||= SplitIoClient.split_factory_registry.active_factories
|
58
58
|
redundant_active_factories ||= SplitIoClient.split_factory_registry.redundant_active_factories
|
59
|
+
time_until_ready ||= ((Time.now.to_f - @config.sdk_start_time) * 1000.0).to_i
|
59
60
|
|
60
61
|
init_config = ConfigInit.new(mode,
|
61
62
|
'memory',
|
@@ -70,7 +71,7 @@ module SplitIoClient
|
|
70
71
|
impressions_mode,
|
71
72
|
!@config.impression_listener.nil?,
|
72
73
|
http_proxy_detected?,
|
73
|
-
time_until_ready
|
74
|
+
time_until_ready,
|
74
75
|
@telemetry_init_consumer.bur_timeouts,
|
75
76
|
@telemetry_init_consumer.non_ready_usages)
|
76
77
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: splitclient-rb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 8.1.1.pre.
|
4
|
+
version: 8.1.1.pre.rc3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Split Software
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-03-
|
11
|
+
date: 2023-03-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: allocation_stats
|