splitclient-rb 7.3.3.pre.rc17 → 7.3.3.pre.rc18
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/splitclient-rb/engine/push_manager.rb +0 -4
- 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 +2 -3
- 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 +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 463a9d41ab4651544984dc087f5800d6e86566a694c8ca0929c224c145bed839
|
4
|
+
data.tar.gz: e8a870ca9198ff396ca9d5f621d86623acb08cc081ea145623c27f0b8571565d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 17fcb827a161a709cc2b6cbda87ed645d076eae3cb77a004ca9044f951adbd6ad040b0452c2f9eedf986e35ed2107a5d5b6d89e498303d2301c3356ff2acdb38
|
7
|
+
data.tar.gz: 106f1726837501774021c23cb5136354dd17ef7ed134eba49840c60d3a6f065f4d7d7243048f4a0ede51a98b98e79a63845267d4d656f5132a5d398295e70c25
|
@@ -34,7 +34,6 @@ module SplitIoClient
|
|
34
34
|
end
|
35
35
|
|
36
36
|
def stop_sse
|
37
|
-
@config.logger.error('## STOP SSE')
|
38
37
|
@sse_handler.stop
|
39
38
|
SplitIoClient::Helpers::ThreadHelper.stop(:schedule_next_token_refresh, @config)
|
40
39
|
end
|
@@ -47,12 +46,9 @@ module SplitIoClient
|
|
47
46
|
@config.logger.debug("schedule_next_token_refresh refresh in #{time} seconds.") if @config.debug_enabled
|
48
47
|
sleep(time)
|
49
48
|
@config.logger.debug('schedule_next_token_refresh starting ...') if @config.debug_enabled
|
50
|
-
@config.logger.error('## SCHEDULE NEXT TOKEN')
|
51
|
-
|
52
49
|
@sse_handler.stop
|
53
50
|
start_sse
|
54
51
|
rescue StandardError => e
|
55
|
-
@config.logger.error("## SCHEDULE EXCEPTION #{e.inspect}")
|
56
52
|
@config.logger.debug("schedule_next_token_refresh error: #{e.inspect}") if @config.debug_enabled
|
57
53
|
end
|
58
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
|
|
@@ -43,7 +43,6 @@ module SplitIoClient
|
|
43
43
|
|
44
44
|
@connected.make_false
|
45
45
|
@socket&.close
|
46
|
-
@config.logger.error('## CLOSE SSE')
|
47
46
|
dispatch_action(action) unless action.nil?
|
48
47
|
rescue StandardError => e
|
49
48
|
@config.logger.error("SSEClient close Error: #{e.inspect}")
|
@@ -76,12 +75,10 @@ module SplitIoClient
|
|
76
75
|
|
77
76
|
def connect_thread(latch)
|
78
77
|
@config.threads[:connect_stream] = Thread.new do
|
79
|
-
@config.logger.error('## CONNECT THREAD')
|
80
78
|
@config.logger.info('Starting connect_stream thread ...') if @config.debug_enabled
|
81
79
|
action = connect_stream(latch)
|
82
80
|
dispatch_action(action) unless action.nil?
|
83
81
|
@config.logger.info('connect_stream thread finished.') if @config.debug_enabled
|
84
|
-
@config.logger.error('#### DISCONNECTED')
|
85
82
|
end
|
86
83
|
end
|
87
84
|
|
@@ -99,6 +96,8 @@ module SplitIoClient
|
|
99
96
|
@config.logger.error(e.inspect)
|
100
97
|
return nil
|
101
98
|
rescue StandardError => e
|
99
|
+
return nil if ENV['SPLITCLIENT_ENV'] == 'test'
|
100
|
+
|
102
101
|
@config.logger.error("Error reading partial data: #{e.inspect}") if @config.debug_enabled
|
103
102
|
return Constants::PUSH_RETRYABLE_ERROR
|
104
103
|
end
|
@@ -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.pre.
|
4
|
+
version: 7.3.3.pre.rc18
|
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-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: allocation_stats
|