grpc 1.3.4-x86-mingw32 → 1.4.0-x86-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.

@@ -233,7 +233,7 @@ extern grpc_completion_queue_create_for_next_type grpc_completion_queue_create_f
233
233
  typedef grpc_completion_queue *(*grpc_completion_queue_create_for_pluck_type)(void *reserved);
234
234
  extern grpc_completion_queue_create_for_pluck_type grpc_completion_queue_create_for_pluck_import;
235
235
  #define grpc_completion_queue_create_for_pluck grpc_completion_queue_create_for_pluck_import
236
- typedef grpc_completion_queue *(*grpc_completion_queue_create_type)(void *reserved);
236
+ typedef grpc_completion_queue *(*grpc_completion_queue_create_type)(const grpc_completion_queue_factory *factory, const grpc_completion_queue_attributes *attributes, void *reserved);
237
237
  extern grpc_completion_queue_create_type grpc_completion_queue_create_import;
238
238
  #define grpc_completion_queue_create grpc_completion_queue_create_import
239
239
  typedef grpc_event(*grpc_completion_queue_next_type)(grpc_completion_queue *cq, gpr_timespec deadline, void *reserved);
@@ -278,15 +278,15 @@ extern grpc_channel_register_call_type grpc_channel_register_call_import;
278
278
  typedef grpc_call *(*grpc_channel_create_registered_call_type)(grpc_channel *channel, grpc_call *parent_call, uint32_t propagation_mask, grpc_completion_queue *completion_queue, void *registered_call_handle, gpr_timespec deadline, void *reserved);
279
279
  extern grpc_channel_create_registered_call_type grpc_channel_create_registered_call_import;
280
280
  #define grpc_channel_create_registered_call grpc_channel_create_registered_call_import
281
+ typedef void *(*grpc_call_arena_alloc_type)(grpc_call *call, size_t size);
282
+ extern grpc_call_arena_alloc_type grpc_call_arena_alloc_import;
283
+ #define grpc_call_arena_alloc grpc_call_arena_alloc_import
281
284
  typedef grpc_call_error(*grpc_call_start_batch_type)(grpc_call *call, const grpc_op *ops, size_t nops, void *tag, void *reserved);
282
285
  extern grpc_call_start_batch_type grpc_call_start_batch_import;
283
286
  #define grpc_call_start_batch grpc_call_start_batch_import
284
287
  typedef char *(*grpc_call_get_peer_type)(grpc_call *call);
285
288
  extern grpc_call_get_peer_type grpc_call_get_peer_import;
286
289
  #define grpc_call_get_peer grpc_call_get_peer_import
287
- typedef void(*grpc_call_set_load_reporting_cost_context_type)(grpc_call *call, struct grpc_load_reporting_cost_context *context);
288
- extern grpc_call_set_load_reporting_cost_context_type grpc_call_set_load_reporting_cost_context_import;
289
- #define grpc_call_set_load_reporting_cost_context grpc_call_set_load_reporting_cost_context_import
290
290
  typedef void(*grpc_census_call_set_context_type)(grpc_call *call, struct census_context *context);
291
291
  extern grpc_census_call_set_context_type grpc_census_call_set_context_import;
292
292
  #define grpc_census_call_set_context grpc_census_call_set_context_import
@@ -314,9 +314,12 @@ extern grpc_call_cancel_type grpc_call_cancel_import;
314
314
  typedef grpc_call_error(*grpc_call_cancel_with_status_type)(grpc_call *call, grpc_status_code status, const char *description, void *reserved);
315
315
  extern grpc_call_cancel_with_status_type grpc_call_cancel_with_status_import;
316
316
  #define grpc_call_cancel_with_status grpc_call_cancel_with_status_import
317
- typedef void(*grpc_call_destroy_type)(grpc_call *call);
318
- extern grpc_call_destroy_type grpc_call_destroy_import;
319
- #define grpc_call_destroy grpc_call_destroy_import
317
+ typedef void(*grpc_call_ref_type)(grpc_call *call);
318
+ extern grpc_call_ref_type grpc_call_ref_import;
319
+ #define grpc_call_ref grpc_call_ref_import
320
+ typedef void(*grpc_call_unref_type)(grpc_call *call);
321
+ extern grpc_call_unref_type grpc_call_unref_import;
322
+ #define grpc_call_unref grpc_call_unref_import
320
323
  typedef grpc_call_error(*grpc_server_request_call_type)(grpc_server *server, grpc_call **call, grpc_call_details *details, grpc_metadata_array *request_metadata, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new);
321
324
  extern grpc_server_request_call_type grpc_server_request_call_import;
322
325
  #define grpc_server_request_call grpc_server_request_call_import
@@ -332,9 +335,6 @@ extern grpc_server_create_type grpc_server_create_import;
332
335
  typedef void(*grpc_server_register_completion_queue_type)(grpc_server *server, grpc_completion_queue *cq, void *reserved);
333
336
  extern grpc_server_register_completion_queue_type grpc_server_register_completion_queue_import;
334
337
  #define grpc_server_register_completion_queue grpc_server_register_completion_queue_import
335
- typedef void(*grpc_server_register_non_listening_completion_queue_type)(grpc_server *server, grpc_completion_queue *q, void *reserved);
336
- extern grpc_server_register_non_listening_completion_queue_type grpc_server_register_non_listening_completion_queue_import;
337
- #define grpc_server_register_non_listening_completion_queue grpc_server_register_non_listening_completion_queue_import
338
338
  typedef int(*grpc_server_add_insecure_http2_port_type)(grpc_server *server, const char *addr);
339
339
  extern grpc_server_add_insecure_http2_port_type grpc_server_add_insecure_http2_port_import;
340
340
  #define grpc_server_add_insecure_http2_port grpc_server_add_insecure_http2_port_import
@@ -491,6 +491,9 @@ extern grpc_slice_ref_type grpc_slice_ref_import;
491
491
  typedef void(*grpc_slice_unref_type)(grpc_slice s);
492
492
  extern grpc_slice_unref_type grpc_slice_unref_import;
493
493
  #define grpc_slice_unref grpc_slice_unref_import
494
+ typedef grpc_slice(*grpc_slice_copy_type)(grpc_slice s);
495
+ extern grpc_slice_copy_type grpc_slice_copy_import;
496
+ #define grpc_slice_copy grpc_slice_copy_import
494
497
  typedef grpc_slice(*grpc_slice_new_type)(void *p, size_t len, void (*destroy)(void *));
495
498
  extern grpc_slice_new_type grpc_slice_new_import;
496
499
  #define grpc_slice_new grpc_slice_new_import
@@ -503,6 +506,9 @@ extern grpc_slice_new_with_len_type grpc_slice_new_with_len_import;
503
506
  typedef grpc_slice(*grpc_slice_malloc_type)(size_t length);
504
507
  extern grpc_slice_malloc_type grpc_slice_malloc_import;
505
508
  #define grpc_slice_malloc grpc_slice_malloc_import
509
+ typedef grpc_slice(*grpc_slice_malloc_large_type)(size_t length);
510
+ extern grpc_slice_malloc_large_type grpc_slice_malloc_large_import;
511
+ #define grpc_slice_malloc_large grpc_slice_malloc_large_import
506
512
  typedef grpc_slice(*grpc_slice_intern_type)(grpc_slice slice);
507
513
  extern grpc_slice_intern_type grpc_slice_intern_import;
508
514
  #define grpc_slice_intern grpc_slice_intern_import
@@ -527,6 +533,9 @@ extern grpc_slice_sub_no_ref_type grpc_slice_sub_no_ref_import;
527
533
  typedef grpc_slice(*grpc_slice_split_tail_type)(grpc_slice *s, size_t split);
528
534
  extern grpc_slice_split_tail_type grpc_slice_split_tail_import;
529
535
  #define grpc_slice_split_tail grpc_slice_split_tail_import
536
+ typedef grpc_slice(*grpc_slice_split_tail_maybe_ref_type)(grpc_slice *s, size_t split, grpc_slice_ref_whom ref_whom);
537
+ extern grpc_slice_split_tail_maybe_ref_type grpc_slice_split_tail_maybe_ref_import;
538
+ #define grpc_slice_split_tail_maybe_ref grpc_slice_split_tail_maybe_ref_import
530
539
  typedef grpc_slice(*grpc_slice_split_head_type)(grpc_slice *s, size_t split);
531
540
  extern grpc_slice_split_head_type grpc_slice_split_head_import;
532
541
  #define grpc_slice_split_head grpc_slice_split_head_import
@@ -611,6 +620,9 @@ extern grpc_slice_buffer_trim_end_type grpc_slice_buffer_trim_end_import;
611
620
  typedef void(*grpc_slice_buffer_move_first_type)(grpc_slice_buffer *src, size_t n, grpc_slice_buffer *dst);
612
621
  extern grpc_slice_buffer_move_first_type grpc_slice_buffer_move_first_import;
613
622
  #define grpc_slice_buffer_move_first grpc_slice_buffer_move_first_import
623
+ typedef void(*grpc_slice_buffer_move_first_no_ref_type)(grpc_slice_buffer *src, size_t n, grpc_slice_buffer *dst);
624
+ extern grpc_slice_buffer_move_first_no_ref_type grpc_slice_buffer_move_first_no_ref_import;
625
+ #define grpc_slice_buffer_move_first_no_ref grpc_slice_buffer_move_first_no_ref_import
614
626
  typedef void(*grpc_slice_buffer_move_first_into_buffer_type)(grpc_exec_ctx *exec_ctx, grpc_slice_buffer *src, size_t n, void *dst);
615
627
  extern grpc_slice_buffer_move_first_into_buffer_type grpc_slice_buffer_move_first_into_buffer_import;
616
628
  #define grpc_slice_buffer_move_first_into_buffer grpc_slice_buffer_move_first_into_buffer_import
@@ -752,6 +764,9 @@ extern gpr_join_host_port_type gpr_join_host_port_import;
752
764
  typedef int(*gpr_split_host_port_type)(const char *name, char **host, char **port);
753
765
  extern gpr_split_host_port_type gpr_split_host_port_import;
754
766
  #define gpr_split_host_port gpr_split_host_port_import
767
+ typedef const char *(*gpr_log_severity_string_type)(gpr_log_severity severity);
768
+ extern gpr_log_severity_string_type gpr_log_severity_string_import;
769
+ #define gpr_log_severity_string gpr_log_severity_string_import
755
770
  typedef void(*gpr_log_type)(const char *file, int line, gpr_log_severity severity, const char *format, ...) GPR_PRINT_FORMAT_CHECK(4, 5);
756
771
  extern gpr_log_type gpr_log_import;
757
772
  #define gpr_log gpr_log_import
@@ -37,15 +37,15 @@
37
37
  #include "rb_server.h"
38
38
 
39
39
  #include <grpc/grpc.h>
40
- #include <grpc/support/atm.h>
41
40
  #include <grpc/grpc_security.h>
41
+ #include <grpc/support/atm.h>
42
42
  #include <grpc/support/log.h>
43
+ #include "rb_byte_buffer.h"
43
44
  #include "rb_call.h"
44
45
  #include "rb_channel_args.h"
45
46
  #include "rb_completion_queue.h"
46
- #include "rb_server_credentials.h"
47
- #include "rb_byte_buffer.h"
48
47
  #include "rb_grpc.h"
48
+ #include "rb_server_credentials.h"
49
49
 
50
50
  /* grpc_rb_cServer is the ruby class that proxies grpc_server. */
51
51
  static VALUE grpc_rb_cServer = Qnil;
@@ -93,9 +93,8 @@ static void grpc_rb_server_free(void *p) {
93
93
  };
94
94
  svr = (grpc_rb_server *)p;
95
95
 
96
- deadline = gpr_time_add(
97
- gpr_now(GPR_CLOCK_REALTIME),
98
- gpr_time_from_seconds(2, GPR_TIMESPAN));
96
+ deadline = gpr_time_add(gpr_now(GPR_CLOCK_REALTIME),
97
+ gpr_time_from_seconds(2, GPR_TIMESPAN));
99
98
 
100
99
  destroy_server(svr, deadline);
101
100
 
@@ -104,13 +103,15 @@ static void grpc_rb_server_free(void *p) {
104
103
 
105
104
  static const rb_data_type_t grpc_rb_server_data_type = {
106
105
  "grpc_server",
107
- {GRPC_RB_GC_NOT_MARKED, grpc_rb_server_free, GRPC_RB_MEMSIZE_UNAVAILABLE,
106
+ {GRPC_RB_GC_NOT_MARKED,
107
+ grpc_rb_server_free,
108
+ GRPC_RB_MEMSIZE_UNAVAILABLE,
108
109
  {NULL, NULL}},
109
110
  NULL,
110
111
  NULL,
111
112
  #ifdef RUBY_TYPED_FREE_IMMEDIATELY
112
- /* It is unsafe to specify RUBY_TYPED_FREE_IMMEDIATELY because the free function would block
113
- * and we might want to unlock GVL
113
+ /* It is unsafe to specify RUBY_TYPED_FREE_IMMEDIATELY because the free
114
+ * function would block and we might want to unlock GVL
114
115
  * TODO(yugui) Unlock GVL?
115
116
  */
116
117
  0,
@@ -139,7 +140,7 @@ static VALUE grpc_rb_server_init(VALUE self, VALUE channel_args) {
139
140
 
140
141
  grpc_ruby_once_init();
141
142
 
142
- cq = grpc_completion_queue_create(NULL);
143
+ cq = grpc_completion_queue_create_for_pluck(NULL);
143
144
  TypedData_Get_Struct(self, grpc_rb_server, &grpc_rb_server_data_type,
144
145
  wrapper);
145
146
  grpc_rb_hash_convert_to_channel_args(channel_args, &args);
@@ -167,7 +168,7 @@ typedef struct request_call_stack {
167
168
 
168
169
  /* grpc_request_call_stack_init ensures the request_call_stack is properly
169
170
  * initialized */
170
- static void grpc_request_call_stack_init(request_call_stack* st) {
171
+ static void grpc_request_call_stack_init(request_call_stack *st) {
171
172
  MEMZERO(st, request_call_stack, 1);
172
173
  grpc_metadata_array_init(&st->md_ary);
173
174
  grpc_call_details_init(&st->details);
@@ -175,7 +176,7 @@ static void grpc_request_call_stack_init(request_call_stack* st) {
175
176
 
176
177
  /* grpc_request_call_stack_cleanup ensures the request_call_stack is properly
177
178
  * cleaned up */
178
- static void grpc_request_call_stack_cleanup(request_call_stack* st) {
179
+ static void grpc_request_call_stack_cleanup(request_call_stack *st) {
179
180
  grpc_metadata_array_destroy(&st->md_ary);
180
181
  grpc_call_details_destroy(&st->details);
181
182
  }
@@ -191,8 +192,9 @@ static VALUE grpc_rb_server_request_call(VALUE self) {
191
192
  grpc_call_error err;
192
193
  request_call_stack st;
193
194
  VALUE result;
194
- void *tag = (void*)&st;
195
- grpc_completion_queue *call_queue = grpc_completion_queue_create(NULL);
195
+ void *tag = (void *)&st;
196
+ grpc_completion_queue *call_queue =
197
+ grpc_completion_queue_create_for_pluck(NULL);
196
198
  gpr_timespec deadline;
197
199
 
198
200
  TypedData_Get_Struct(self, grpc_rb_server, &grpc_rb_server_data_type, s);
@@ -203,9 +205,8 @@ static VALUE grpc_rb_server_request_call(VALUE self) {
203
205
  grpc_request_call_stack_init(&st);
204
206
  /* call grpc_server_request_call, then wait for it to complete using
205
207
  * pluck_event */
206
- err = grpc_server_request_call(
207
- s->wrapped, &call, &st.details, &st.md_ary,
208
- call_queue, s->queue, tag);
208
+ err = grpc_server_request_call(s->wrapped, &call, &st.details, &st.md_ary,
209
+ call_queue, s->queue, tag);
209
210
  if (err != GRPC_CALL_OK) {
210
211
  grpc_request_call_stack_cleanup(&st);
211
212
  rb_raise(grpc_rb_eCallError,
@@ -301,8 +302,7 @@ static VALUE grpc_rb_server_add_http2_port(VALUE self, VALUE port,
301
302
  return Qnil;
302
303
  } else if (TYPE(rb_creds) == T_SYMBOL) {
303
304
  if (id_insecure_server != SYM2ID(rb_creds)) {
304
- rb_raise(rb_eTypeError,
305
- "bad creds symbol, want :this_port_is_insecure");
305
+ rb_raise(rb_eTypeError, "bad creds symbol, want :this_port_is_insecure");
306
306
  return Qnil;
307
307
  }
308
308
  recvd_port =
@@ -314,9 +314,8 @@ static VALUE grpc_rb_server_add_http2_port(VALUE self, VALUE port,
314
314
  }
315
315
  } else {
316
316
  creds = grpc_rb_get_wrapped_server_credentials(rb_creds);
317
- recvd_port =
318
- grpc_server_add_secure_http2_port(s->wrapped, StringValueCStr(port),
319
- creds);
317
+ recvd_port = grpc_server_add_secure_http2_port(
318
+ s->wrapped, StringValueCStr(port), creds);
320
319
  if (recvd_port == 0) {
321
320
  rb_raise(rb_eRuntimeError,
322
321
  "could not add secure port %s to server, not sure why",
@@ -335,18 +334,17 @@ void Init_grpc_server() {
335
334
 
336
335
  /* Provides a ruby constructor and support for dup/clone. */
337
336
  rb_define_method(grpc_rb_cServer, "initialize", grpc_rb_server_init, 1);
338
- rb_define_method(grpc_rb_cServer, "initialize_copy",
339
- grpc_rb_cannot_init_copy, 1);
337
+ rb_define_method(grpc_rb_cServer, "initialize_copy", grpc_rb_cannot_init_copy,
338
+ 1);
340
339
 
341
340
  /* Add the server methods. */
342
- rb_define_method(grpc_rb_cServer, "request_call",
343
- grpc_rb_server_request_call, 0);
341
+ rb_define_method(grpc_rb_cServer, "request_call", grpc_rb_server_request_call,
342
+ 0);
344
343
  rb_define_method(grpc_rb_cServer, "start", grpc_rb_server_start, 0);
345
344
  rb_define_method(grpc_rb_cServer, "destroy", grpc_rb_server_destroy, -1);
346
345
  rb_define_alias(grpc_rb_cServer, "close", "destroy");
347
346
  rb_define_method(grpc_rb_cServer, "add_http2_port",
348
- grpc_rb_server_add_http2_port,
349
- 2);
347
+ grpc_rb_server_add_http2_port, 2);
350
348
  id_at = rb_intern("at");
351
349
  id_insecure_server = rb_intern("this_port_is_insecure");
352
350
  }
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -34,6 +34,6 @@ begin
34
34
  if File.directory?(distrib_lib_dir)
35
35
  require_relative "#{distrib_lib_dir}/grpc_c"
36
36
  else
37
- require_relative 'grpc_c'
37
+ require 'grpc/grpc_c'
38
38
  end
39
39
  end
Binary file
@@ -29,5 +29,5 @@
29
29
 
30
30
  # GRPC contains the General RPC module.
31
31
  module GRPC
32
- VERSION = '1.3.4'
32
+ VERSION = '1.4.0'
33
33
  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.3.4
4
+ version: 1.4.0
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - gRPC Authors
8
8
  autorequire:
9
9
  bindir: src/ruby/bin
10
10
  cert_chain: []
11
- date: 2017-05-19 00:00:00.000000000 Z
11
+ date: 2017-06-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-protobuf
@@ -313,27 +313,27 @@ signing_key:
313
313
  specification_version: 4
314
314
  summary: GRPC system in Ruby
315
315
  test_files:
316
- - src/ruby/spec/generic/rpc_server_spec.rb
317
- - src/ruby/spec/generic/rpc_server_pool_spec.rb
318
- - src/ruby/spec/generic/client_stub_spec.rb
319
- - src/ruby/spec/generic/rpc_desc_spec.rb
320
- - src/ruby/spec/generic/service_spec.rb
321
- - src/ruby/spec/generic/active_call_spec.rb
322
- - src/ruby/spec/pb/health/checker_spec.rb
323
- - src/ruby/spec/pb/duplicate/codegen_spec.rb
316
+ - src/ruby/spec/server_spec.rb
324
317
  - src/ruby/spec/channel_spec.rb
325
- - src/ruby/spec/client_server_spec.rb
326
318
  - src/ruby/spec/testdata/README
327
- - src/ruby/spec/testdata/server1.key
328
319
  - src/ruby/spec/testdata/ca.pem
320
+ - src/ruby/spec/testdata/server1.key
329
321
  - src/ruby/spec/testdata/server1.pem
322
+ - src/ruby/spec/time_consts_spec.rb
323
+ - src/ruby/spec/channel_connection_spec.rb
330
324
  - src/ruby/spec/call_spec.rb
325
+ - src/ruby/spec/generic/rpc_server_spec.rb
326
+ - src/ruby/spec/generic/rpc_desc_spec.rb
327
+ - src/ruby/spec/generic/active_call_spec.rb
328
+ - src/ruby/spec/generic/client_stub_spec.rb
329
+ - src/ruby/spec/generic/rpc_server_pool_spec.rb
330
+ - src/ruby/spec/generic/service_spec.rb
331
+ - src/ruby/spec/pb/duplicate/codegen_spec.rb
332
+ - src/ruby/spec/pb/health/checker_spec.rb
333
+ - src/ruby/spec/client_server_spec.rb
334
+ - src/ruby/spec/compression_options_spec.rb
331
335
  - src/ruby/spec/server_credentials_spec.rb
332
336
  - src/ruby/spec/spec_helper.rb
333
- - src/ruby/spec/time_consts_spec.rb
337
+ - src/ruby/spec/error_sanity_spec.rb
334
338
  - src/ruby/spec/channel_credentials_spec.rb
335
339
  - src/ruby/spec/call_credentials_spec.rb
336
- - src/ruby/spec/channel_connection_spec.rb
337
- - src/ruby/spec/server_spec.rb
338
- - src/ruby/spec/error_sanity_spec.rb
339
- - src/ruby/spec/compression_options_spec.rb