grpc 1.0.1-x64-mingw32 → 1.1.2-x64-mingw32
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of grpc might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/etc/roots.pem +39 -111
- data/grpc_c.32.ruby +0 -0
- data/grpc_c.64.ruby +0 -0
- data/src/ruby/ext/grpc/extconf.rb +0 -1
- data/src/ruby/ext/grpc/rb_byte_buffer.c +8 -7
- data/src/ruby/ext/grpc/rb_call.c +15 -5
- data/src/ruby/ext/grpc/rb_channel.c +1 -1
- data/src/ruby/ext/grpc/rb_compression_options.c +466 -0
- data/src/ruby/ext/grpc/rb_compression_options.h +44 -0
- data/src/ruby/ext/grpc/rb_grpc.c +3 -1
- data/src/ruby/ext/grpc/rb_grpc_imports.generated.c +198 -190
- data/src/ruby/ext/grpc/rb_grpc_imports.generated.h +306 -294
- data/src/ruby/ext/grpc/rb_server.c +18 -12
- data/src/ruby/lib/grpc/2.0/grpc_c.so +0 -0
- data/src/ruby/lib/grpc/2.1/grpc_c.so +0 -0
- data/src/ruby/lib/grpc/2.2/grpc_c.so +0 -0
- data/src/ruby/lib/grpc/2.3/grpc_c.so +0 -0
- data/src/ruby/lib/grpc/2.4/grpc_c.so +0 -0
- data/src/ruby/lib/grpc/errors.rb +154 -2
- data/src/ruby/lib/grpc/generic/active_call.rb +144 -63
- data/src/ruby/lib/grpc/generic/bidi_call.rb +18 -2
- data/src/ruby/lib/grpc/generic/client_stub.rb +7 -5
- data/src/ruby/lib/grpc/generic/rpc_desc.rb +39 -13
- data/src/ruby/lib/grpc/generic/rpc_server.rb +51 -24
- data/src/ruby/lib/grpc/generic/service.rb +3 -2
- data/src/ruby/lib/grpc/grpc_c.so +0 -0
- data/src/ruby/lib/grpc/version.rb +1 -1
- data/src/ruby/pb/grpc/health/checker.rb +3 -1
- data/src/ruby/pb/src/proto/grpc/testing/test_services_pb.rb +7 -0
- data/src/ruby/pb/test/client.rb +307 -7
- data/src/ruby/pb/test/server.rb +26 -1
- data/src/ruby/spec/compression_options_spec.rb +164 -0
- data/src/ruby/spec/error_sanity_spec.rb +64 -0
- data/src/ruby/spec/generic/active_call_spec.rb +290 -12
- data/src/ruby/spec/generic/client_stub_spec.rb +91 -41
- data/src/ruby/spec/generic/rpc_desc_spec.rb +36 -16
- data/src/ruby/spec/generic/rpc_server_pool_spec.rb +22 -28
- data/src/ruby/spec/generic/rpc_server_spec.rb +6 -6
- data/src/ruby/spec/pb/health/checker_spec.rb +27 -19
- data/src/ruby/spec/spec_helper.rb +2 -0
- metadata +18 -8
@@ -97,15 +97,17 @@ describe Grpc::Health::Checker do
|
|
97
97
|
|
98
98
|
context 'initialization' do
|
99
99
|
it 'can be constructed with no args' do
|
100
|
-
|
100
|
+
checker = Grpc::Health::Checker.new
|
101
|
+
expect(checker).to_not be(nil)
|
101
102
|
end
|
102
103
|
end
|
103
104
|
|
104
105
|
context 'method `add_status` and `check`' do
|
105
106
|
success_tests.each do |t|
|
106
107
|
it "should succeed when #{t[:desc]}" do
|
107
|
-
|
108
|
-
|
108
|
+
checker = Grpc::Health::Checker.new
|
109
|
+
checker.add_status(t[:service], ServingStatus::NOT_SERVING)
|
110
|
+
got = checker.check(HCReq.new(service: t[:service]), nil)
|
109
111
|
want = HCResp.new(status: ServingStatus::NOT_SERVING)
|
110
112
|
expect(got).to eq(want)
|
111
113
|
end
|
@@ -115,11 +117,12 @@ describe Grpc::Health::Checker do
|
|
115
117
|
context 'method `check`' do
|
116
118
|
success_tests.each do |t|
|
117
119
|
it "should fail with NOT_FOUND when #{t[:desc]}" do
|
120
|
+
checker = Grpc::Health::Checker.new
|
118
121
|
blk = proc do
|
119
|
-
|
122
|
+
checker.check(HCReq.new(service: t[:service]), nil)
|
120
123
|
end
|
121
124
|
expected_msg = /#{StatusCodes::NOT_FOUND}/
|
122
|
-
expect(&blk).to raise_error GRPC::
|
125
|
+
expect(&blk).to raise_error GRPC::NotFound, expected_msg
|
123
126
|
end
|
124
127
|
end
|
125
128
|
end
|
@@ -127,38 +130,40 @@ describe Grpc::Health::Checker do
|
|
127
130
|
context 'method `clear_status`' do
|
128
131
|
success_tests.each do |t|
|
129
132
|
it "should fail after clearing status when #{t[:desc]}" do
|
130
|
-
|
131
|
-
|
133
|
+
checker = Grpc::Health::Checker.new
|
134
|
+
checker.add_status(t[:service], ServingStatus::NOT_SERVING)
|
135
|
+
got = checker.check(HCReq.new(service: t[:service]), nil)
|
132
136
|
want = HCResp.new(status: ServingStatus::NOT_SERVING)
|
133
137
|
expect(got).to eq(want)
|
134
138
|
|
135
|
-
|
139
|
+
checker.clear_status(t[:service])
|
136
140
|
blk = proc do
|
137
|
-
|
141
|
+
checker.check(HCReq.new(service: t[:service]), nil)
|
138
142
|
end
|
139
143
|
expected_msg = /#{StatusCodes::NOT_FOUND}/
|
140
|
-
expect(&blk).to raise_error GRPC::
|
144
|
+
expect(&blk).to raise_error GRPC::NotFound, expected_msg
|
141
145
|
end
|
142
146
|
end
|
143
147
|
end
|
144
148
|
|
145
149
|
context 'method `clear_all`' do
|
146
150
|
it 'should return NOT_FOUND after being invoked' do
|
151
|
+
checker = Grpc::Health::Checker.new
|
147
152
|
success_tests.each do |t|
|
148
|
-
|
149
|
-
got =
|
153
|
+
checker.add_status(t[:service], ServingStatus::NOT_SERVING)
|
154
|
+
got = checker.check(HCReq.new(service: t[:service]), nil)
|
150
155
|
want = HCResp.new(status: ServingStatus::NOT_SERVING)
|
151
156
|
expect(got).to eq(want)
|
152
157
|
end
|
153
158
|
|
154
|
-
|
159
|
+
checker.clear_all
|
155
160
|
|
156
161
|
success_tests.each do |t|
|
157
162
|
blk = proc do
|
158
|
-
|
163
|
+
checker.check(HCReq.new(service: t[:service]), nil)
|
159
164
|
end
|
160
165
|
expected_msg = /#{StatusCodes::NOT_FOUND}/
|
161
|
-
expect(&blk).to raise_error GRPC::
|
166
|
+
expect(&blk).to raise_error GRPC::NotFound, expected_msg
|
162
167
|
end
|
163
168
|
end
|
164
169
|
end
|
@@ -184,8 +189,10 @@ describe Grpc::Health::Checker do
|
|
184
189
|
end
|
185
190
|
|
186
191
|
it 'should receive the correct status', server: true do
|
187
|
-
|
188
|
-
|
192
|
+
Thread.abort_on_exception = true
|
193
|
+
checker = Grpc::Health::Checker.new
|
194
|
+
@srv.handle(checker)
|
195
|
+
checker.add_status('', ServingStatus::NOT_SERVING)
|
189
196
|
t = Thread.new { @srv.run }
|
190
197
|
@srv.wait_till_running
|
191
198
|
|
@@ -198,7 +205,8 @@ describe Grpc::Health::Checker do
|
|
198
205
|
end
|
199
206
|
|
200
207
|
it 'should fail on unknown services', server: true do
|
201
|
-
|
208
|
+
checker = Grpc::Health::Checker.new
|
209
|
+
@srv.handle(checker)
|
202
210
|
t = Thread.new { @srv.run }
|
203
211
|
@srv.wait_till_running
|
204
212
|
blk = proc do
|
@@ -206,7 +214,7 @@ describe Grpc::Health::Checker do
|
|
206
214
|
stub.check(HCReq.new(service: 'unknown'))
|
207
215
|
end
|
208
216
|
expected_msg = /#{StatusCodes::NOT_FOUND}/
|
209
|
-
expect(&blk).to raise_error GRPC::
|
217
|
+
expect(&blk).to raise_error GRPC::NotFound, expected_msg
|
210
218
|
@srv.stop
|
211
219
|
t.join
|
212
220
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grpc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.2
|
5
5
|
platform: x64-mingw32
|
6
6
|
authors:
|
7
7
|
- gRPC Authors
|
8
8
|
autorequire:
|
9
9
|
bindir: src/ruby/bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-02-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: google-protobuf
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 3.
|
19
|
+
version: '3.1'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 3.
|
26
|
+
version: '3.1'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: googleauth
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -114,14 +114,14 @@ dependencies:
|
|
114
114
|
requirements:
|
115
115
|
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version: '0
|
117
|
+
version: '1.0'
|
118
118
|
type: :development
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
122
|
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version: '0
|
124
|
+
version: '1.0'
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: rake-compiler-dock
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
@@ -212,6 +212,8 @@ files:
|
|
212
212
|
- src/ruby/ext/grpc/rb_channel_credentials.h
|
213
213
|
- src/ruby/ext/grpc/rb_completion_queue.c
|
214
214
|
- src/ruby/ext/grpc/rb_completion_queue.h
|
215
|
+
- src/ruby/ext/grpc/rb_compression_options.c
|
216
|
+
- src/ruby/ext/grpc/rb_compression_options.h
|
215
217
|
- src/ruby/ext/grpc/rb_event_thread.c
|
216
218
|
- src/ruby/ext/grpc/rb_event_thread.h
|
217
219
|
- src/ruby/ext/grpc/rb_grpc.c
|
@@ -229,6 +231,7 @@ files:
|
|
229
231
|
- src/ruby/lib/grpc/2.1/grpc_c.so
|
230
232
|
- src/ruby/lib/grpc/2.2/grpc_c.so
|
231
233
|
- src/ruby/lib/grpc/2.3/grpc_c.so
|
234
|
+
- src/ruby/lib/grpc/2.4/grpc_c.so
|
232
235
|
- src/ruby/lib/grpc/core/time_consts.rb
|
233
236
|
- src/ruby/lib/grpc/errors.rb
|
234
237
|
- src/ruby/lib/grpc/generic/active_call.rb
|
@@ -261,6 +264,8 @@ files:
|
|
261
264
|
- src/ruby/spec/channel_credentials_spec.rb
|
262
265
|
- src/ruby/spec/channel_spec.rb
|
263
266
|
- src/ruby/spec/client_server_spec.rb
|
267
|
+
- src/ruby/spec/compression_options_spec.rb
|
268
|
+
- src/ruby/spec/error_sanity_spec.rb
|
264
269
|
- src/ruby/spec/generic/active_call_spec.rb
|
265
270
|
- src/ruby/spec/generic/client_stub_spec.rb
|
266
271
|
- src/ruby/spec/generic/rpc_desc_spec.rb
|
@@ -291,7 +296,10 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
291
296
|
requirements:
|
292
297
|
- - ">="
|
293
298
|
- !ruby/object:Gem::Version
|
294
|
-
version: 2.0
|
299
|
+
version: '2.0'
|
300
|
+
- - "<"
|
301
|
+
- !ruby/object:Gem::Version
|
302
|
+
version: '2.5'
|
295
303
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
296
304
|
requirements:
|
297
305
|
- - ">="
|
@@ -299,7 +307,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
299
307
|
version: '0'
|
300
308
|
requirements: []
|
301
309
|
rubyforge_project:
|
302
|
-
rubygems_version: 2.
|
310
|
+
rubygems_version: 2.6.10
|
303
311
|
signing_key:
|
304
312
|
specification_version: 4
|
305
313
|
summary: GRPC system in Ruby
|
@@ -325,3 +333,5 @@ test_files:
|
|
325
333
|
- src/ruby/spec/channel_credentials_spec.rb
|
326
334
|
- src/ruby/spec/call_credentials_spec.rb
|
327
335
|
- src/ruby/spec/server_spec.rb
|
336
|
+
- src/ruby/spec/error_sanity_spec.rb
|
337
|
+
- src/ruby/spec/compression_options_spec.rb
|