routemaster-drain 3.6.5 → 3.6.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.circleci/config.yml +10 -200
- data/lib/routemaster/api_client_circuit.rb +2 -1
- data/lib/routemaster/drain.rb +1 -1
- data/routemaster-drain.gemspec +1 -0
- metadata +21 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 95bdc05150729150c9abb45ca3d66689a3669b43e0cedf3621ea5d8dcac9c5f2
|
4
|
+
data.tar.gz: cad717d62652b35fc06de4713ef50fccccaed06242dc0d33cec68bf6354d2bcc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ef95e56e7c88e806e735dbb4cf8fef8233e0b5f64f437c6d33f6b13918d7c8f0bf8e2c3569ef0193b9f6af99024452d579a30f9333a72be79c947ffda489c918
|
7
|
+
data.tar.gz: 286ed07d78195d3977e00e3963dc8b2943ac356a7a123e8ac02e666566e1014f01e01c1f2fdd7de81bda0b722c9f295549d5673c023e1a74648741d94a31ba41
|
data/.circleci/config.yml
CHANGED
@@ -4,160 +4,24 @@
|
|
4
4
|
version: 2
|
5
5
|
jobs:
|
6
6
|
|
7
|
-
build_2.
|
7
|
+
build_2.5_rails_5:
|
8
8
|
docker:
|
9
|
-
- image:
|
9
|
+
- image: circleci/ruby:2.4.1
|
10
10
|
- image: redis:3-alpine
|
11
11
|
steps:
|
12
12
|
- checkout
|
13
13
|
|
14
14
|
- run:
|
15
|
-
name:
|
15
|
+
name: Install bundler
|
16
16
|
command: |
|
17
|
-
rbenv local 2.3.4 ;
|
18
|
-
gem install bundler -v '~> 1.17' ;
|
19
|
-
bundle config --local gemfile $PWD/gemfiles/rails_3.gemfile
|
20
|
-
|
21
|
-
- restore_cache:
|
22
|
-
keys:
|
23
|
-
- v2-bundle-2.3.4-rails_3-{{ .Branch }}
|
24
|
-
- v2-bundle-2.3.4-rails_3
|
25
|
-
- v2-bundle-2.3.4
|
26
|
-
|
27
|
-
- run:
|
28
|
-
name: Install dependencies
|
29
|
-
command: |
|
30
|
-
bundle install --jobs=3 --retry=3 --path=$PWD/vendor/bundle
|
31
|
-
|
32
|
-
- run:
|
33
|
-
name: Run test suite
|
34
|
-
command: |
|
35
|
-
unset RACK_ENV &&
|
36
|
-
unset RAILS_ENV &&
|
37
|
-
bundle exec rspec
|
38
|
-
|
39
|
-
- save_cache:
|
40
|
-
key: v2-bundle-2.3.4-rails_3-{{ .Branch }}
|
41
|
-
paths:
|
42
|
-
- ~/project/vendor/bundle
|
43
|
-
- save_cache:
|
44
|
-
key: v2-bundle-2.3.4-rails_3
|
45
|
-
paths:
|
46
|
-
- ~/project/vendor/bundle
|
47
|
-
- save_cache:
|
48
|
-
key: v2-bundle-2.3.4
|
49
|
-
paths:
|
50
|
-
- ~/project/vendor/bundle
|
51
|
-
|
52
|
-
build_2.3.4_rails_4:
|
53
|
-
docker:
|
54
|
-
- image: deliveroo/multiruby
|
55
|
-
- image: redis:3-alpine
|
56
|
-
steps:
|
57
|
-
- checkout
|
58
|
-
|
59
|
-
- run:
|
60
|
-
name: Select build variant (Ruby 2.3.4, rails_4)
|
61
|
-
command: |
|
62
|
-
rbenv local 2.3.4 ;
|
63
|
-
gem install bundler -v '~> 1.17' ;
|
64
|
-
bundle config --local gemfile $PWD/gemfiles/rails_4.gemfile
|
65
|
-
|
66
|
-
- restore_cache:
|
67
|
-
keys:
|
68
|
-
- v2-bundle-2.3.4-rails_4-{{ .Branch }}
|
69
|
-
- v2-bundle-2.3.4-rails_4
|
70
|
-
- v2-bundle-2.3.4
|
71
|
-
|
72
|
-
- run:
|
73
|
-
name: Install dependencies
|
74
|
-
command: |
|
75
|
-
bundle install --jobs=3 --retry=3 --path=$PWD/vendor/bundle
|
76
|
-
|
77
|
-
- run:
|
78
|
-
name: Run test suite
|
79
|
-
command: |
|
80
|
-
unset RACK_ENV &&
|
81
|
-
unset RAILS_ENV &&
|
82
|
-
bundle exec rspec
|
83
|
-
|
84
|
-
- save_cache:
|
85
|
-
key: v2-bundle-2.3.4-rails_4-{{ .Branch }}
|
86
|
-
paths:
|
87
|
-
- ~/project/vendor/bundle
|
88
|
-
- save_cache:
|
89
|
-
key: v2-bundle-2.3.4-rails_4
|
90
|
-
paths:
|
91
|
-
- ~/project/vendor/bundle
|
92
|
-
- save_cache:
|
93
|
-
key: v2-bundle-2.3.4
|
94
|
-
paths:
|
95
|
-
- ~/project/vendor/bundle
|
96
|
-
|
97
|
-
build_2.4.1_rails_4:
|
98
|
-
docker:
|
99
|
-
- image: deliveroo/multiruby
|
100
|
-
- image: redis:3-alpine
|
101
|
-
steps:
|
102
|
-
- checkout
|
103
|
-
|
104
|
-
- run:
|
105
|
-
name: Select build variant (Ruby 2.4.1, rails_4)
|
106
|
-
command: |
|
107
|
-
rbenv local 2.4.1 ;
|
108
|
-
gem install bundler -v '~> 1.17' ;
|
109
|
-
bundle config --local gemfile $PWD/gemfiles/rails_4.gemfile
|
110
|
-
|
111
|
-
- restore_cache:
|
112
|
-
keys:
|
113
|
-
- v2-bundle-2.4.1-rails_4-{{ .Branch }}
|
114
|
-
- v2-bundle-2.4.1-rails_4
|
115
|
-
- v2-bundle-2.4.1
|
116
|
-
|
117
|
-
- run:
|
118
|
-
name: Install dependencies
|
119
|
-
command: |
|
120
|
-
bundle install --jobs=3 --retry=3 --path=$PWD/vendor/bundle
|
121
|
-
|
122
|
-
- run:
|
123
|
-
name: Run test suite
|
124
|
-
command: |
|
125
|
-
unset RACK_ENV &&
|
126
|
-
unset RAILS_ENV &&
|
127
|
-
bundle exec rspec
|
128
|
-
|
129
|
-
- save_cache:
|
130
|
-
key: v2-bundle-2.4.1-rails_4-{{ .Branch }}
|
131
|
-
paths:
|
132
|
-
- ~/project/vendor/bundle
|
133
|
-
- save_cache:
|
134
|
-
key: v2-bundle-2.4.1-rails_4
|
135
|
-
paths:
|
136
|
-
- ~/project/vendor/bundle
|
137
|
-
- save_cache:
|
138
|
-
key: v2-bundle-2.4.1
|
139
|
-
paths:
|
140
|
-
- ~/project/vendor/bundle
|
141
|
-
|
142
|
-
build_2.3.4_rails_5:
|
143
|
-
docker:
|
144
|
-
- image: deliveroo/multiruby
|
145
|
-
- image: redis:3-alpine
|
146
|
-
steps:
|
147
|
-
- checkout
|
148
|
-
|
149
|
-
- run:
|
150
|
-
name: Select build variant (Ruby 2.3.4, rails_5)
|
151
|
-
command: |
|
152
|
-
rbenv local 2.3.4 ;
|
153
17
|
gem install bundler -v '~> 1.17' ;
|
154
18
|
bundle config --local gemfile $PWD/gemfiles/rails_5.gemfile
|
155
19
|
|
156
20
|
- restore_cache:
|
157
21
|
keys:
|
158
|
-
- v2-bundle-2.
|
159
|
-
- v2-bundle-2.
|
160
|
-
- v2-bundle-2.
|
22
|
+
- v2-bundle-2.5.0-rails_5-{{ .Branch }}
|
23
|
+
- v2-bundle-2.5.0-rails_5
|
24
|
+
- v2-bundle-2.5.0
|
161
25
|
|
162
26
|
- run:
|
163
27
|
name: Install dependencies
|
@@ -172,60 +36,15 @@ jobs:
|
|
172
36
|
bundle exec rspec
|
173
37
|
|
174
38
|
- save_cache:
|
175
|
-
key: v2-bundle-2.
|
39
|
+
key: v2-bundle-2.5.0-rails_5-{{ .Branch }}
|
176
40
|
paths:
|
177
41
|
- ~/project/vendor/bundle
|
178
42
|
- save_cache:
|
179
|
-
key: v2-bundle-2.
|
43
|
+
key: v2-bundle-2.5.0-rails_5
|
180
44
|
paths:
|
181
45
|
- ~/project/vendor/bundle
|
182
46
|
- save_cache:
|
183
|
-
key: v2-bundle-2.
|
184
|
-
paths:
|
185
|
-
- ~/project/vendor/bundle
|
186
|
-
|
187
|
-
build_2.4.1_rails_5:
|
188
|
-
docker:
|
189
|
-
- image: deliveroo/multiruby
|
190
|
-
- image: redis:3-alpine
|
191
|
-
steps:
|
192
|
-
- checkout
|
193
|
-
|
194
|
-
- run:
|
195
|
-
name: Select build variant (Ruby 2.4.1, rails_5)
|
196
|
-
command: |
|
197
|
-
rbenv local 2.4.1 ;
|
198
|
-
gem install bundler -v '~> 1.17' ;
|
199
|
-
bundle config --local gemfile $PWD/gemfiles/rails_5.gemfile
|
200
|
-
|
201
|
-
- restore_cache:
|
202
|
-
keys:
|
203
|
-
- v2-bundle-2.4.1-rails_5-{{ .Branch }}
|
204
|
-
- v2-bundle-2.4.1-rails_5
|
205
|
-
- v2-bundle-2.4.1
|
206
|
-
|
207
|
-
- run:
|
208
|
-
name: Install dependencies
|
209
|
-
command: |
|
210
|
-
bundle install --jobs=3 --retry=3 --path=$PWD/vendor/bundle
|
211
|
-
|
212
|
-
- run:
|
213
|
-
name: Run test suite
|
214
|
-
command: |
|
215
|
-
unset RACK_ENV &&
|
216
|
-
unset RAILS_ENV &&
|
217
|
-
bundle exec rspec
|
218
|
-
|
219
|
-
- save_cache:
|
220
|
-
key: v2-bundle-2.4.1-rails_5-{{ .Branch }}
|
221
|
-
paths:
|
222
|
-
- ~/project/vendor/bundle
|
223
|
-
- save_cache:
|
224
|
-
key: v2-bundle-2.4.1-rails_5
|
225
|
-
paths:
|
226
|
-
- ~/project/vendor/bundle
|
227
|
-
- save_cache:
|
228
|
-
key: v2-bundle-2.4.1
|
47
|
+
key: v2-bundle-2.5.0
|
229
48
|
paths:
|
230
49
|
- ~/project/vendor/bundle
|
231
50
|
|
@@ -234,14 +53,5 @@ workflows:
|
|
234
53
|
version: 2
|
235
54
|
test:
|
236
55
|
jobs:
|
237
|
-
|
238
|
-
- build_2.3.4_rails_3
|
239
|
-
|
240
|
-
- build_2.3.4_rails_4
|
241
|
-
|
242
|
-
- build_2.4.1_rails_4
|
243
|
-
|
244
|
-
- build_2.3.4_rails_5
|
245
|
-
|
246
|
-
- build_2.4.1_rails_5
|
56
|
+
- build_2.5_rails_5
|
247
57
|
|
@@ -25,13 +25,14 @@ module Routemaster
|
|
25
25
|
ENV.fetch('ROUTEMASTER_ENABLE_API_CLIENT_CIRCUIT', 'NO') =~ /\A(YES|TRUE|ON|1)\Z/i
|
26
26
|
end
|
27
27
|
|
28
|
+
|
28
29
|
def circuit
|
29
30
|
Circuitbox.circuit(@circuit_name, {
|
30
31
|
sleep_window: configuration_setting(@circuit_name, 'ROUTEMASTER_CIRCUIT_BREAKER_SLEEP_WINDOW', 60).to_i,
|
31
32
|
time_window: configuration_setting(@circuit_name, 'ROUTEMASTER_CIRCUIT_BREAKER_TIME_WINDOW', 120).to_i,
|
32
33
|
volume_threshold: configuration_setting(@circuit_name, 'ROUTEMASTER_CIRCUIT_BREAKER_VOLUME_THRESHOLD', 50).to_i,
|
33
34
|
error_threshold: configuration_setting(@circuit_name, 'ROUTEMASTER_CIRCUIT_BREAKER_ERROR_THRESHOLD', 50).to_i,
|
34
|
-
cache: Moneta.new(
|
35
|
+
cache: Moneta::Adapters::Redis.new(backend: Config.cache_redis),
|
35
36
|
exceptions: [Routemaster::Errors::FatalResource, Faraday::TimeoutError]
|
36
37
|
})
|
37
38
|
end
|
data/lib/routemaster/drain.rb
CHANGED
data/routemaster-drain.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: routemaster-drain
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.6.
|
4
|
+
version: 3.6.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Julien Letessier
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-10-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|
@@ -150,7 +150,21 @@ dependencies:
|
|
150
150
|
- - ">="
|
151
151
|
- !ruby/object:Gem::Version
|
152
152
|
version: '0'
|
153
|
-
|
153
|
+
- !ruby/object:Gem::Dependency
|
154
|
+
name: moneta
|
155
|
+
requirement: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - '='
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: 1.0.0
|
160
|
+
type: :runtime
|
161
|
+
prerelease: false
|
162
|
+
version_requirements: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - '='
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: 1.0.0
|
167
|
+
description:
|
154
168
|
email:
|
155
169
|
- julien.letessier@gmail.com
|
156
170
|
executables: []
|
@@ -271,7 +285,7 @@ homepage: http://github.com/deliveroo/routemaster-drain
|
|
271
285
|
licenses:
|
272
286
|
- MIT
|
273
287
|
metadata: {}
|
274
|
-
post_install_message:
|
288
|
+
post_install_message:
|
275
289
|
rdoc_options: []
|
276
290
|
require_paths:
|
277
291
|
- lib
|
@@ -286,8 +300,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
286
300
|
- !ruby/object:Gem::Version
|
287
301
|
version: '0'
|
288
302
|
requirements: []
|
289
|
-
rubygems_version: 3.
|
290
|
-
signing_key:
|
303
|
+
rubygems_version: 3.1.4
|
304
|
+
signing_key:
|
291
305
|
specification_version: 4
|
292
306
|
summary: Event receiver for the Routemaster bus
|
293
307
|
test_files:
|