splitclient-rb 7.3.3.pre.rc15 → 7.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop.yml +1 -0
- data/CHANGES.txt +10 -0
- data/lib/splitclient-rb/engine/push_manager.rb +0 -5
- data/lib/splitclient-rb/engine/sync_manager.rb +0 -1
- data/lib/splitclient-rb/helpers/thread_helper.rb +0 -2
- data/lib/splitclient-rb/sse/event_source/client.rb +7 -7
- data/lib/splitclient-rb/sse/sse_handler.rb +1 -1
- data/lib/splitclient-rb/sse/workers/segments_worker.rb +0 -5
- data/lib/splitclient-rb/sse/workers/splits_worker.rb +0 -10
- data/lib/splitclient-rb/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 69076f1dccfed6a33995ffb44369f40ecec01b99e7bc5b427c7a451e4bef3ee0
|
4
|
+
data.tar.gz: f298a3f2879a399a990d2d29d30fcb129b264e1ed09eece6b61653439a1a55b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 33f2ebae7e70a1b929f6bf7f049e8687202ef8e17d950d5d872f281a680bd9f82f03e77bc1ca8e73b25bc9e1e4498ce3701160158ffb98b030702f50b6764435
|
7
|
+
data.tar.gz: 2e80a76e93049d612806d2889bb707e77fce20e6487cd046c0e26fecdf5770fa35170076d6d652518e05929155943f50bc8e2e4842a9233960427eafbab739a5
|
data/.rubocop.yml
CHANGED
data/CHANGES.txt
CHANGED
@@ -1,5 +1,15 @@
|
|
1
1
|
CHANGES
|
2
2
|
|
3
|
+
7.3.3 (Jan 28, 2021)
|
4
|
+
- Fixed edge cases where the sdk lost streaming connection.
|
5
|
+
- Updated default auth service url to https://auth.split.io/api/v2/auth
|
6
|
+
- Updated dependencies:
|
7
|
+
- faraday to >= 0.8, < 2.0
|
8
|
+
- net-http-persistent to >= 2.9, < 5.0
|
9
|
+
- redis to >= 4.0.0, < 5.0
|
10
|
+
- socketry to >= 0.4, < 1.0
|
11
|
+
- thread_safe to ~> 0.3
|
12
|
+
|
3
13
|
7.3.2 (Dec 10, 2021)
|
4
14
|
- Updated the readiness flow to be more consistent with the other sdks and improve the readiness time.
|
5
15
|
- Updated the name of telemety key latencies in Redis.
|
@@ -34,8 +34,6 @@ module SplitIoClient
|
|
34
34
|
end
|
35
35
|
|
36
36
|
def stop_sse
|
37
|
-
@config.logger.error('## STOP SSE')
|
38
|
-
@sse_handler.process_disconnect if @sse_handler.sse_client.nil?
|
39
37
|
@sse_handler.stop
|
40
38
|
SplitIoClient::Helpers::ThreadHelper.stop(:schedule_next_token_refresh, @config)
|
41
39
|
end
|
@@ -48,12 +46,9 @@ module SplitIoClient
|
|
48
46
|
@config.logger.debug("schedule_next_token_refresh refresh in #{time} seconds.") if @config.debug_enabled
|
49
47
|
sleep(time)
|
50
48
|
@config.logger.debug('schedule_next_token_refresh starting ...') if @config.debug_enabled
|
51
|
-
@config.logger.error('## SCHEDULE NEXT TOKEN')
|
52
|
-
|
53
49
|
@sse_handler.stop
|
54
50
|
start_sse
|
55
51
|
rescue StandardError => e
|
56
|
-
@config.logger.error("## SCHEDULE EXCEPTION #{e.inspect}")
|
57
52
|
@config.logger.debug("schedule_next_token_refresh error: #{e.inspect}") if @config.debug_enabled
|
58
53
|
end
|
59
54
|
end
|
@@ -8,11 +8,9 @@ module SplitIoClient
|
|
8
8
|
|
9
9
|
unless thread.nil?
|
10
10
|
config.logger.debug("Stopping #{thread_sym} thread...") if config.debug_enabled
|
11
|
-
# sleep(0.1) while thread.status == 'run'
|
12
11
|
Thread.kill(thread)
|
13
12
|
end
|
14
13
|
rescue StandardError => e
|
15
|
-
puts e.inspect
|
16
14
|
config.logger.error(e.inspect)
|
17
15
|
end
|
18
16
|
|
@@ -35,7 +35,7 @@ module SplitIoClient
|
|
35
35
|
@on[:action] = action
|
36
36
|
end
|
37
37
|
|
38
|
-
def close
|
38
|
+
def close(action = nil)
|
39
39
|
unless connected?
|
40
40
|
@config.logger.error('SSEClient already disconected.') if @config.debug_enabled
|
41
41
|
return
|
@@ -43,7 +43,7 @@ module SplitIoClient
|
|
43
43
|
|
44
44
|
@connected.make_false
|
45
45
|
@socket&.close
|
46
|
-
|
46
|
+
dispatch_action(action) unless action.nil?
|
47
47
|
rescue StandardError => e
|
48
48
|
@config.logger.error("SSEClient close Error: #{e.inspect}")
|
49
49
|
end
|
@@ -75,12 +75,10 @@ module SplitIoClient
|
|
75
75
|
|
76
76
|
def connect_thread(latch)
|
77
77
|
@config.threads[:connect_stream] = Thread.new do
|
78
|
-
@config.logger.error('## CONNECT THREAD')
|
79
78
|
@config.logger.info('Starting connect_stream thread ...') if @config.debug_enabled
|
80
79
|
action = connect_stream(latch)
|
81
|
-
dispatch_action(action)
|
80
|
+
dispatch_action(action) unless action.nil?
|
82
81
|
@config.logger.info('connect_stream thread finished.') if @config.debug_enabled
|
83
|
-
@config.logger.error('#### DISCONNECTED')
|
84
82
|
end
|
85
83
|
end
|
86
84
|
|
@@ -96,15 +94,17 @@ module SplitIoClient
|
|
96
94
|
raise 'eof exception' if partial_data == :eof
|
97
95
|
rescue Errno::EBADF, IOError => e
|
98
96
|
@config.logger.error(e.inspect)
|
99
|
-
return
|
97
|
+
return nil
|
100
98
|
rescue StandardError => e
|
99
|
+
return nil if ENV['SPLITCLIENT_ENV'] == 'test'
|
100
|
+
|
101
101
|
@config.logger.error("Error reading partial data: #{e.inspect}") if @config.debug_enabled
|
102
102
|
return Constants::PUSH_RETRYABLE_ERROR
|
103
103
|
end
|
104
104
|
|
105
105
|
process_data(partial_data)
|
106
106
|
end
|
107
|
-
|
107
|
+
nil
|
108
108
|
end
|
109
109
|
|
110
110
|
def socket_write(latch)
|
@@ -13,11 +13,6 @@ module SplitIoClient
|
|
13
13
|
end
|
14
14
|
|
15
15
|
def add_to_queue(change_number, segment_name)
|
16
|
-
unless @running.value
|
17
|
-
@config.logger.debug('segments worker not running.')
|
18
|
-
return
|
19
|
-
end
|
20
|
-
|
21
16
|
item = { change_number: change_number, segment_name: segment_name }
|
22
17
|
@config.logger.debug("SegmentsWorker add to queue #{item}")
|
23
18
|
@queue.push(item)
|
@@ -33,21 +33,11 @@ module SplitIoClient
|
|
33
33
|
end
|
34
34
|
|
35
35
|
def add_to_queue(change_number)
|
36
|
-
unless @running.value
|
37
|
-
@config.logger.debug('splits worker not running.')
|
38
|
-
return
|
39
|
-
end
|
40
|
-
|
41
36
|
@config.logger.debug("SplitsWorker add to queue #{change_number}")
|
42
37
|
@queue.push(change_number)
|
43
38
|
end
|
44
39
|
|
45
40
|
def kill_split(change_number, split_name, default_treatment)
|
46
|
-
unless @running.value
|
47
|
-
@config.logger.debug('splits worker not running.')
|
48
|
-
return
|
49
|
-
end
|
50
|
-
|
51
41
|
return if @splits_repository.get_change_number.to_i > change_number
|
52
42
|
|
53
43
|
@config.logger.debug("SplitsWorker kill #{split_name}, #{change_number}")
|
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: 7.3.3
|
4
|
+
version: 7.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Split Software
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-01-
|
11
|
+
date: 2022-01-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: allocation_stats
|
@@ -519,9 +519,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
519
519
|
version: '0'
|
520
520
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
521
521
|
requirements:
|
522
|
-
- - "
|
522
|
+
- - ">="
|
523
523
|
- !ruby/object:Gem::Version
|
524
|
-
version:
|
524
|
+
version: '0'
|
525
525
|
requirements: []
|
526
526
|
rubygems_version: 3.2.32
|
527
527
|
signing_key:
|