splitclient-rb 3.1.0 → 3.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a5117f6f857f704d74de7ad686f76fe016245794
4
- data.tar.gz: 8fdaf54c1819746efc035274ec8cd466f318c6c7
3
+ metadata.gz: 4840554044e90d311433517d0cb5805759023674
4
+ data.tar.gz: 472d56491357ec2dad31dcfb97e38f237036d5ee
5
5
  SHA512:
6
- metadata.gz: 37e6ece18bd94cf91577f11d27d21d14a6d95e41e010b865621b36fb387769b208e1160029a096512d4d35b05a16e04904e3df103e6b47e1f241e699833293d7
7
- data.tar.gz: 840b6cc2480523351a7d6f612b641f65309ffcb2cc6a1993acaacb457b89a924d061f87e5ec104af972de70e20b6156509042e5ace91f0f36f84c4fcbfd42171
6
+ metadata.gz: c1d930b278e72f552b5f18fd5152120ee743a0ba5571f845b3aa4bfb3bf7c0c9bf5d7facf9d34eed748a3105f5e1444bcd70529fa1516800571882e0e5bf5392
7
+ data.tar.gz: 661cc43581e7246b0fd0817fc7dd7dc30028b978843d408294c7430e62b8f95ddd18cb4782e112d46888d90cdc4cd751ecd4f623aaaea71021491f7539698af7
data/CHANGES.txt CHANGED
@@ -1,3 +1,7 @@
1
+ 3.1.1
2
+ - Fix variable not found when posting impression
3
+ - Fix infinite loop when posting impression if there is a network glitch
4
+
1
5
  3.1.0
2
6
  - Add RedisAdapter
3
7
  - adds manager.split_names()
@@ -19,7 +19,7 @@ module SplitIoClient
19
19
  post_impressions
20
20
  else
21
21
  Thread.new do
22
- @config.logger.info('Starting impressions service') unless ENV['SPLITCLIENT_ENV'] == 'test'
22
+ @config.logger.info('Starting impressions service')
23
23
 
24
24
  loop do
25
25
  post_impressions
@@ -28,8 +28,6 @@ module SplitIoClient
28
28
  end
29
29
  end
30
30
  end
31
-
32
- @config.logger.info('Started impressions service') unless ENV['SPLITCLIENT_ENV'] == 'test'
33
31
  end
34
32
 
35
33
  private
@@ -13,7 +13,7 @@ module SplitIoClient
13
13
  return
14
14
  end
15
15
 
16
- result = post_api("#{config.events_uri}/testImpressions/bulk", @config, @api_key, @impressions)
16
+ result = post_api("#{@config.events_uri}/testImpressions/bulk", @config, @api_key, @impressions)
17
17
 
18
18
  if result.status / 100 != 2
19
19
  @config.logger.error("Unexpected status code while posting impressions: #{result.status}")
@@ -140,17 +140,23 @@ module SplitIoClient
140
140
  return if ENV['SPLITCLIENT_ENV'] == 'test'
141
141
 
142
142
  Thread.new do
143
+
144
+ @config.logger.info('Starting metrics service')
145
+
143
146
  loop do
144
147
  begin
148
+
145
149
  post_metrics
146
150
 
147
- random_interval = randomize_interval @config.metrics_refresh_rate
148
- sleep(random_interval)
149
151
  rescue StandardError => error
150
152
  @config.log_found_exception(__method__.to_s, error)
151
153
  end
154
+
155
+ # Sleep either on success of failure.
156
+ sleep(randomize_interval(@config.metrics_refresh_rate))
152
157
  end
153
158
  end
159
+
154
160
  end
155
161
 
156
162
  #
@@ -1,3 +1,3 @@
1
1
  module SplitIoClient
2
- VERSION = '3.1.0'
2
+ VERSION = '3.1.1'
3
3
  end
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: 3.1.0
4
+ version: 3.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Split Software
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-11-18 00:00:00.000000000 Z
11
+ date: 2016-11-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler