From 24e69bf02afb0f4abdd637d1513e93e5aa227e7e Mon Sep 17 00:00:00 2001 From: Aaron Isotton Date: Fri, 26 Feb 2016 11:53:22 -0800 Subject: Added a channel argument to set the maximum reconnect backoff duration. Extended the interop test to test the custom reconnect backoffs. This closes #5377. --- src/core/client_config/subchannel.c | 14 ++++++++++++++ src/proto/grpc/testing/messages.proto | 8 +++++++- src/proto/grpc/testing/test.proto | 4 ++-- 3 files changed, 23 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/core/client_config/subchannel.c b/src/core/client_config/subchannel.c index d91dd116b8..055f69c70e 100644 --- a/src/core/client_config/subchannel.c +++ b/src/core/client_config/subchannel.c @@ -603,6 +603,20 @@ static void update_reconnect_parameters(grpc_subchannel *c) { gpr_time_from_millis(c->args->args[i].value.integer, GPR_TIMESPAN)); return; } + if (0 == + strcmp(c->args->args[i].key, GRPC_ARG_MAX_RECONNECT_BACKOFF_MS)) { + if (c->args->args[i].type == GRPC_ARG_INTEGER) { + if (c->args->args[i].value.integer >= 0) { + max_backoff_millis = c->args->args[i].value.integer; + } else { + gpr_log(GPR_ERROR, GRPC_ARG_MAX_RECONNECT_BACKOFF_MS + " : must be non-negative"); + } + } else { + gpr_log(GPR_ERROR, + GRPC_ARG_MAX_RECONNECT_BACKOFF_MS " : must be an integer"); + } + } } } diff --git a/src/proto/grpc/testing/messages.proto b/src/proto/grpc/testing/messages.proto index 193b6c4171..a063b470c7 100644 --- a/src/proto/grpc/testing/messages.proto +++ b/src/proto/grpc/testing/messages.proto @@ -1,5 +1,5 @@ -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without @@ -158,6 +158,12 @@ message StreamingOutputCallResponse { Payload payload = 1; } +// For reconnect interop test only. +// Client tells server what reconnection parameters it used. +message ReconnectParams { + int32 max_reconnect_backoff_ms = 1; +} + // For reconnect interop test only. // Server tells client whether its reconnects are following the spec and the // reconnect backoffs it saw. diff --git a/src/proto/grpc/testing/test.proto b/src/proto/grpc/testing/test.proto index 9faba297a3..84369db4b8 100644 --- a/src/proto/grpc/testing/test.proto +++ b/src/proto/grpc/testing/test.proto @@ -1,5 +1,5 @@ -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without @@ -80,6 +80,6 @@ service UnimplementedService { // A service used to control reconnect server. service ReconnectService { - rpc Start(grpc.testing.Empty) returns (grpc.testing.Empty); + rpc Start(grpc.testing.ReconnectParams) returns (grpc.testing.Empty); rpc Stop(grpc.testing.Empty) returns (grpc.testing.ReconnectInfo); } -- cgit v1.2.3 From 8c0d96ff867628dbb3e4fa8562869d53eff45589 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 11 Mar 2016 14:27:52 -0800 Subject: Initial fail-fast support --- include/grpc/impl/codegen/grpc_types.h | 6 +++- src/core/channel/client_channel.c | 40 ++++++++++++++++++------ src/core/channel/client_uchannel.c | 1 + src/core/channel/http_client_filter.c | 10 +++--- src/core/channel/subchannel_call_holder.c | 5 +-- src/core/channel/subchannel_call_holder.h | 1 + src/core/client_config/lb_policies/pick_first.c | 36 +++++++++++++++++++-- src/core/client_config/lb_policies/round_robin.c | 36 +++++++++++++++++++-- src/core/client_config/lb_policy.c | 11 ++++++- src/core/client_config/lb_policy.h | 13 ++++++++ src/core/surface/call.c | 3 +- src/core/transport/transport.h | 6 ++-- test/core/end2end/dualstack_socket_test.c | 4 +-- test/core/end2end/tests/simple_delayed_request.c | 2 +- 14 files changed, 143 insertions(+), 31 deletions(-) (limited to 'src') diff --git a/include/grpc/impl/codegen/grpc_types.h b/include/grpc/impl/codegen/grpc_types.h index 993fc97adb..d5ec2fedd8 100644 --- a/include/grpc/impl/codegen/grpc_types.h +++ b/include/grpc/impl/codegen/grpc_types.h @@ -202,8 +202,12 @@ typedef enum grpc_call_error { /* Initial metadata flags */ /** Signal that the call is idempotent */ #define GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST (0x00000010u) +/** Signal that the call should not return UNAVAILABLE before it has started */ +#define GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY (0x00000020u) /** Mask of all valid flags */ -#define GRPC_INITIAL_METADATA_USED_MASK GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST +#define GRPC_INITIAL_METADATA_USED_MASK \ + (GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST | \ + GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY) /** A single metadata element */ typedef struct grpc_metadata { diff --git a/src/core/channel/client_channel.c b/src/core/channel/client_channel.c index f021a8ae32..e229a15260 100644 --- a/src/core/channel/client_channel.c +++ b/src/core/channel/client_channel.c @@ -114,6 +114,22 @@ static void watch_lb_policy(grpc_exec_ctx *exec_ctx, channel_data *chand, grpc_lb_policy *lb_policy, grpc_connectivity_state current_state); +static void set_channel_connectivity_state_locked(grpc_exec_ctx *exec_ctx, + channel_data *chand, + grpc_connectivity_state state, + const char *reason) { + if ((state == GRPC_CHANNEL_TRANSIENT_FAILURE || + state == GRPC_CHANNEL_FATAL_FAILURE) && + chand->lb_policy != NULL) { + /* cancel fail-fast picks */ + grpc_lb_policy_cancel_picks( + exec_ctx, chand->lb_policy, + /* mask= */ GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY, + /* check= */ 0); + } + grpc_connectivity_state_set(exec_ctx, &chand->state_tracker, state, reason); +} + static void on_lb_policy_state_changed_locked( grpc_exec_ctx *exec_ctx, lb_policy_connectivity_watcher *w) { grpc_connectivity_state publish_state = w->state; @@ -127,8 +143,8 @@ static void on_lb_policy_state_changed_locked( GRPC_LB_POLICY_UNREF(exec_ctx, w->chand->lb_policy, "channel"); w->chand->lb_policy = NULL; } - grpc_connectivity_state_set(exec_ctx, &w->chand->state_tracker, publish_state, - "lb_changed"); + set_channel_connectivity_state_locked(exec_ctx, w->chand, publish_state, + "lb_changed"); if (w->state != GRPC_CHANNEL_FATAL_FAILURE) { watch_lb_policy(exec_ctx, w->chand, w->lb_policy, w->state); } @@ -200,8 +216,8 @@ static void cc_on_config_changed(grpc_exec_ctx *exec_ctx, void *arg, } if (iomgr_success && chand->resolver) { - grpc_connectivity_state_set(exec_ctx, &chand->state_tracker, state, - "new_lb+resolver"); + set_channel_connectivity_state_locked(exec_ctx, chand, state, + "new_lb+resolver"); if (lb_policy != NULL) { watch_lb_policy(exec_ctx, chand, lb_policy, state); } @@ -216,8 +232,8 @@ static void cc_on_config_changed(grpc_exec_ctx *exec_ctx, void *arg, GRPC_RESOLVER_UNREF(exec_ctx, chand->resolver, "channel"); chand->resolver = NULL; } - grpc_connectivity_state_set(exec_ctx, &chand->state_tracker, - GRPC_CHANNEL_FATAL_FAILURE, "resolver_gone"); + set_channel_connectivity_state_locked( + exec_ctx, chand, GRPC_CHANNEL_FATAL_FAILURE, "resolver_gone"); gpr_mu_unlock(&chand->mu_config); } @@ -272,8 +288,8 @@ static void cc_start_transport_op(grpc_exec_ctx *exec_ctx, } if (op->disconnect && chand->resolver != NULL) { - grpc_connectivity_state_set(exec_ctx, &chand->state_tracker, - GRPC_CHANNEL_FATAL_FAILURE, "disconnect"); + set_channel_connectivity_state_locked( + exec_ctx, chand, GRPC_CHANNEL_FATAL_FAILURE, "disconnect"); grpc_resolver_shutdown(exec_ctx, chand->resolver); GRPC_RESOLVER_UNREF(exec_ctx, chand->resolver, "channel"); chand->resolver = NULL; @@ -290,6 +306,7 @@ static void cc_start_transport_op(grpc_exec_ctx *exec_ctx, typedef struct { grpc_metadata_batch *initial_metadata; + uint32_t initial_metadata_flags; grpc_connected_subchannel **connected_subchannel; grpc_closure *on_ready; grpc_call_element *elem; @@ -298,6 +315,7 @@ typedef struct { static int cc_pick_subchannel(grpc_exec_ctx *exec_ctx, void *arg, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **connected_subchannel, grpc_closure *on_ready); @@ -308,6 +326,7 @@ static void continue_picking(grpc_exec_ctx *exec_ctx, void *arg, bool success) { } else if (cpa->connected_subchannel == NULL) { /* cancelled, do nothing */ } else if (cc_pick_subchannel(exec_ctx, cpa->elem, cpa->initial_metadata, + cpa->initial_metadata_flags, cpa->connected_subchannel, cpa->on_ready)) { grpc_exec_ctx_enqueue(exec_ctx, cpa->on_ready, true, NULL); } @@ -316,6 +335,7 @@ static void continue_picking(grpc_exec_ctx *exec_ctx, void *arg, bool success) { static int cc_pick_subchannel(grpc_exec_ctx *exec_ctx, void *elemp, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **connected_subchannel, grpc_closure *on_ready) { grpc_call_element *elem = elemp; @@ -349,7 +369,8 @@ static int cc_pick_subchannel(grpc_exec_ctx *exec_ctx, void *elemp, GRPC_LB_POLICY_REF(lb_policy, "cc_pick_subchannel"); gpr_mu_unlock(&chand->mu_config); r = grpc_lb_policy_pick(exec_ctx, lb_policy, calld->pollset, - initial_metadata, connected_subchannel, on_ready); + initial_metadata, initial_metadata_flags, + connected_subchannel, on_ready); GRPC_LB_POLICY_UNREF(exec_ctx, lb_policy, "cc_pick_subchannel"); return r; } @@ -362,6 +383,7 @@ static int cc_pick_subchannel(grpc_exec_ctx *exec_ctx, void *elemp, } cpa = gpr_malloc(sizeof(*cpa)); cpa->initial_metadata = initial_metadata; + cpa->initial_metadata_flags = initial_metadata_flags; cpa->connected_subchannel = connected_subchannel; cpa->on_ready = on_ready; cpa->elem = elem; diff --git a/src/core/channel/client_uchannel.c b/src/core/channel/client_uchannel.c index 83fcc3a87f..cafbc4fd89 100644 --- a/src/core/channel/client_uchannel.c +++ b/src/core/channel/client_uchannel.c @@ -126,6 +126,7 @@ static void cuc_start_transport_op(grpc_exec_ctx *exec_ctx, static int cuc_pick_subchannel(grpc_exec_ctx *exec_ctx, void *arg, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **connected_subchannel, grpc_closure *on_ready) { channel_data *chand = arg; diff --git a/src/core/channel/http_client_filter.c b/src/core/channel/http_client_filter.c index 32c808cf6a..79abfd2102 100644 --- a/src/core/channel/http_client_filter.c +++ b/src/core/channel/http_client_filter.c @@ -111,10 +111,12 @@ static void hc_mutate_op(grpc_call_element *elem, elem); /* Send : prefixed headers, which have to be before any application layer headers. */ - grpc_metadata_batch_add_head(op->send_initial_metadata, &calld->method, - op->send_idempotent_request - ? GRPC_MDELEM_METHOD_PUT - : GRPC_MDELEM_METHOD_POST); + grpc_metadata_batch_add_head( + op->send_initial_metadata, &calld->method, + op->send_initial_metadata_flags & + GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST + ? GRPC_MDELEM_METHOD_PUT + : GRPC_MDELEM_METHOD_POST); grpc_metadata_batch_add_head(op->send_initial_metadata, &calld->scheme, channeld->static_scheme); grpc_metadata_batch_add_tail(op->send_initial_metadata, &calld->te_trailers, diff --git a/src/core/channel/subchannel_call_holder.c b/src/core/channel/subchannel_call_holder.c index 9c087dc2a1..788d3ab21b 100644 --- a/src/core/channel/subchannel_call_holder.c +++ b/src/core/channel/subchannel_call_holder.c @@ -127,7 +127,7 @@ retry: break; case GRPC_SUBCHANNEL_CALL_HOLDER_PICKING_SUBCHANNEL: holder->pick_subchannel(exec_ctx, holder->pick_subchannel_arg, NULL, - &holder->connected_subchannel, NULL); + 0, &holder->connected_subchannel, NULL); break; } gpr_mu_unlock(&holder->mu); @@ -145,7 +145,8 @@ retry: GRPC_CALL_STACK_REF(holder->owning_call, "pick_subchannel"); if (holder->pick_subchannel( exec_ctx, holder->pick_subchannel_arg, op->send_initial_metadata, - &holder->connected_subchannel, &holder->next_step)) { + op->send_initial_metadata_flags, &holder->connected_subchannel, + &holder->next_step)) { holder->creation_phase = GRPC_SUBCHANNEL_CALL_HOLDER_NOT_CREATING; GRPC_CALL_STACK_UNREF(exec_ctx, holder->owning_call, "pick_subchannel"); } diff --git a/src/core/channel/subchannel_call_holder.h b/src/core/channel/subchannel_call_holder.h index 9cf72c6cf7..acb35a8283 100644 --- a/src/core/channel/subchannel_call_holder.h +++ b/src/core/channel/subchannel_call_holder.h @@ -42,6 +42,7 @@ called when the subchannel is available) */ typedef int (*grpc_subchannel_call_holder_pick_subchannel)( grpc_exec_ctx *exec_ctx, void *arg, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **connected_subchannel, grpc_closure *on_ready); typedef enum { diff --git a/src/core/client_config/lb_policies/pick_first.c b/src/core/client_config/lb_policies/pick_first.c index 81167b31c8..20c2dd8bf3 100644 --- a/src/core/client_config/lb_policies/pick_first.c +++ b/src/core/client_config/lb_policies/pick_first.c @@ -42,6 +42,7 @@ typedef struct pending_pick { struct pending_pick *next; grpc_pollset *pollset; + uint32_t initial_metadata_flags; grpc_connected_subchannel **target; grpc_closure *on_complete; } pending_pick; @@ -151,6 +152,32 @@ static void pf_cancel_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, gpr_mu_unlock(&p->mu); } +static void pf_cancel_picks(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, + uint32_t initial_metadata_flags_mask, + uint32_t initial_metadata_flags_eq) { + pick_first_lb_policy *p = (pick_first_lb_policy *)pol; + pending_pick *pp; + gpr_mu_lock(&p->mu); + pp = p->pending_picks; + p->pending_picks = NULL; + while (pp != NULL) { + pending_pick *next = pp->next; + if ((pp->initial_metadata_flags & initial_metadata_flags_mask) == + initial_metadata_flags_eq) { + grpc_pollset_set_del_pollset(exec_ctx, p->base.interested_parties, + pp->pollset); + *pp->target = NULL; + grpc_exec_ctx_enqueue(exec_ctx, pp->on_complete, false, NULL); + gpr_free(pp); + } else { + pp->next = p->pending_picks; + p->pending_picks = pp; + } + pp = next; + } + gpr_mu_unlock(&p->mu); +} + static void start_picking(grpc_exec_ctx *exec_ctx, pick_first_lb_policy *p) { p->started_picking = 1; p->checking_subchannel = 0; @@ -173,7 +200,8 @@ void pf_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) { int pf_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, grpc_pollset *pollset, grpc_metadata_batch *initial_metadata, - grpc_connected_subchannel **target, grpc_closure *on_complete) { + uint32_t initial_metadata_flags, grpc_connected_subchannel **target, + grpc_closure *on_complete) { pick_first_lb_policy *p = (pick_first_lb_policy *)pol; pending_pick *pp; @@ -200,6 +228,7 @@ int pf_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, grpc_pollset *pollset, pp->next = p->pending_picks; pp->pollset = pollset; pp->target = target; + pp->initial_metadata_flags = initial_metadata_flags; pp->on_complete = on_complete; p->pending_picks = pp; gpr_mu_unlock(&p->mu); @@ -378,8 +407,9 @@ void pf_ping_one(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, } static const grpc_lb_policy_vtable pick_first_lb_policy_vtable = { - pf_destroy, pf_shutdown, pf_pick, pf_cancel_pick, pf_ping_one, pf_exit_idle, - pf_check_connectivity, pf_notify_on_state_change}; + pf_destroy, pf_shutdown, pf_pick, pf_cancel_pick, pf_cancel_picks, + pf_ping_one, pf_exit_idle, pf_check_connectivity, + pf_notify_on_state_change}; static void pick_first_factory_ref(grpc_lb_policy_factory *factory) {} diff --git a/src/core/client_config/lb_policies/round_robin.c b/src/core/client_config/lb_policies/round_robin.c index 98d9acc75b..6fa5b03d8c 100644 --- a/src/core/client_config/lb_policies/round_robin.c +++ b/src/core/client_config/lb_policies/round_robin.c @@ -48,6 +48,7 @@ int grpc_lb_round_robin_trace = 0; typedef struct pending_pick { struct pending_pick *next; grpc_pollset *pollset; + uint32_t initial_metadata_flags; grpc_connected_subchannel **target; grpc_closure *on_complete; } pending_pick; @@ -274,6 +275,32 @@ static void rr_cancel_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, gpr_mu_unlock(&p->mu); } +static void rr_cancel_picks(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, + uint32_t initial_metadata_flags_mask, + uint32_t initial_metadata_flags_eq) { + round_robin_lb_policy *p = (round_robin_lb_policy *)pol; + pending_pick *pp; + gpr_mu_lock(&p->mu); + pp = p->pending_picks; + p->pending_picks = NULL; + while (pp != NULL) { + pending_pick *next = pp->next; + if ((pp->initial_metadata_flags & initial_metadata_flags_mask) == + initial_metadata_flags_eq) { + grpc_pollset_set_del_pollset(exec_ctx, p->base.interested_parties, + pp->pollset); + *pp->target = NULL; + grpc_exec_ctx_enqueue(exec_ctx, pp->on_complete, false, NULL); + gpr_free(pp); + } else { + pp->next = p->pending_picks; + p->pending_picks = pp; + } + pp = next; + } + gpr_mu_unlock(&p->mu); +} + static void start_picking(grpc_exec_ctx *exec_ctx, round_robin_lb_policy *p) { size_t i; p->started_picking = 1; @@ -302,7 +329,8 @@ void rr_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) { int rr_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, grpc_pollset *pollset, grpc_metadata_batch *initial_metadata, - grpc_connected_subchannel **target, grpc_closure *on_complete) { + uint32_t initial_metadata_flags, grpc_connected_subchannel **target, + grpc_closure *on_complete) { round_robin_lb_policy *p = (round_robin_lb_policy *)pol; pending_pick *pp; ready_list *selected; @@ -328,6 +356,7 @@ int rr_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, grpc_pollset *pollset, pp->pollset = pollset; pp->target = target; pp->on_complete = on_complete; + pp->initial_metadata_flags = initial_metadata_flags; p->pending_picks = pp; gpr_mu_unlock(&p->mu); return 0; @@ -483,8 +512,9 @@ static void rr_ping_one(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, } static const grpc_lb_policy_vtable round_robin_lb_policy_vtable = { - rr_destroy, rr_shutdown, rr_pick, rr_cancel_pick, rr_ping_one, rr_exit_idle, - rr_check_connectivity, rr_notify_on_state_change}; + rr_destroy, rr_shutdown, rr_pick, rr_cancel_pick, rr_cancel_picks, + rr_ping_one, rr_exit_idle, rr_check_connectivity, + rr_notify_on_state_change}; static void round_robin_factory_ref(grpc_lb_policy_factory *factory) {} diff --git a/src/core/client_config/lb_policy.c b/src/core/client_config/lb_policy.c index 0d8b007336..d67505e618 100644 --- a/src/core/client_config/lb_policy.c +++ b/src/core/client_config/lb_policy.c @@ -101,10 +101,11 @@ void grpc_lb_policy_weak_unref(grpc_exec_ctx *exec_ctx, int grpc_lb_policy_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, grpc_pollset *pollset, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **target, grpc_closure *on_complete) { return policy->vtable->pick(exec_ctx, policy, pollset, initial_metadata, - target, on_complete); + initial_metadata_flags, target, on_complete); } void grpc_lb_policy_cancel_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, @@ -112,6 +113,14 @@ void grpc_lb_policy_cancel_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, policy->vtable->cancel_pick(exec_ctx, policy, target); } +void grpc_lb_policy_cancel_picks(grpc_exec_ctx *exec_ctx, + grpc_lb_policy *policy, + uint32_t initial_metadata_flags_mask, + uint32_t initial_metadata_flags_eq) { + policy->vtable->cancel_picks(exec_ctx, policy, initial_metadata_flags_mask, + initial_metadata_flags_eq); +} + void grpc_lb_policy_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy) { policy->vtable->exit_idle(exec_ctx, policy); } diff --git a/src/core/client_config/lb_policy.h b/src/core/client_config/lb_policy.h index 3457390606..922b0d3672 100644 --- a/src/core/client_config/lb_policy.h +++ b/src/core/client_config/lb_policy.h @@ -60,9 +60,13 @@ struct grpc_lb_policy_vtable { /** implement grpc_lb_policy_pick */ int (*pick)(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, grpc_pollset *pollset, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **target, grpc_closure *on_complete); void (*cancel_pick)(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, grpc_connected_subchannel **target); + void (*cancel_picks)(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, + uint32_t initial_metadata_flags_mask, + uint32_t initial_metadata_flags_eq); void (*ping_one)(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, grpc_closure *closure); @@ -122,6 +126,7 @@ void grpc_lb_policy_init(grpc_lb_policy *policy, int grpc_lb_policy_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, grpc_pollset *pollset, grpc_metadata_batch *initial_metadata, + uint32_t initial_metadata_flags, grpc_connected_subchannel **target, grpc_closure *on_complete); @@ -131,6 +136,14 @@ void grpc_lb_policy_ping_one(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, void grpc_lb_policy_cancel_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy, grpc_connected_subchannel **target); +/** Cancel all pending picks which have: + (initial_metadata_flags & initial_metadata_flags_mask) == + initial_metadata_flags_eq */ +void grpc_lb_policy_cancel_picks(grpc_exec_ctx *exec_ctx, + grpc_lb_policy *policy, + uint32_t initial_metadata_flags_mask, + uint32_t initial_metadata_flags_eq); + void grpc_lb_policy_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *policy); void grpc_lb_policy_notify_on_state_change(grpc_exec_ctx *exec_ctx, diff --git a/src/core/surface/call.c b/src/core/surface/call.c index a369795ac8..07a6c1a2db 100644 --- a/src/core/surface/call.c +++ b/src/core/surface/call.c @@ -1229,8 +1229,7 @@ static grpc_call_error call_start_batch(grpc_exec_ctx *exec_ctx, call->metadata_batch[0][0].deadline = call->send_deadline; stream_op.send_initial_metadata = &call->metadata_batch[0 /* is_receiving */][0 /* is_trailing */]; - stream_op.send_idempotent_request = - (op->flags & GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST) != 0; + stream_op.send_initial_metadata_flags = op->flags; break; case GRPC_OP_SEND_MESSAGE: if (!are_write_flags_valid(op->flags)) { diff --git a/src/core/transport/transport.h b/src/core/transport/transport.h index 0374c98087..ca7f60fa03 100644 --- a/src/core/transport/transport.h +++ b/src/core/transport/transport.h @@ -84,9 +84,9 @@ typedef struct grpc_transport_stream_op { /** Send initial metadata to the peer, from the provided metadata batch. idempotent_request MUST be set if this is non-null */ grpc_metadata_batch *send_initial_metadata; - /** Iff send_initial_metadata != NULL, flags if this is an idempotent request - or not */ - bool send_idempotent_request; + /** Iff send_initial_metadata != NULL, flags associated with + send_initial_metadata: a bitfield of GRPC_INITIAL_METADATA_xxx */ + uint32_t send_initial_metadata_flags; /** Send trailing metadata to the peer, from the provided metadata batch. */ grpc_metadata_batch *send_trailing_metadata; diff --git a/test/core/end2end/dualstack_socket_test.c b/test/core/end2end/dualstack_socket_test.c index 58e13a4098..f6531ea523 100644 --- a/test/core/end2end/dualstack_socket_test.c +++ b/test/core/end2end/dualstack_socket_test.c @@ -39,9 +39,9 @@ #include #include -#include "src/core/support/string.h" #include "src/core/iomgr/resolve_address.h" #include "src/core/iomgr/socket_utils_posix.h" +#include "src/core/support/string.h" #include "test/core/end2end/cq_verifier.h" #include "test/core/util/port.h" @@ -237,7 +237,7 @@ void test_connect(const char *server_host, const char *client_host, int port, cq_expect_completion(cqv, tag(1), 1); cq_verify(cqv); - GPR_ASSERT(status == GRPC_STATUS_DEADLINE_EXCEEDED); + GPR_ASSERT(status == GRPC_STATUS_UNAVAILABLE); } grpc_call_destroy(c); diff --git a/test/core/end2end/tests/simple_delayed_request.c b/test/core/end2end/tests/simple_delayed_request.c index 0afef7503b..ad8bce5541 100644 --- a/test/core/end2end/tests/simple_delayed_request.c +++ b/test/core/end2end/tests/simple_delayed_request.c @@ -120,7 +120,7 @@ static void simple_delayed_request_body(grpc_end2end_test_config config, op = ops; op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; - op->flags = 0; + op->flags = GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY; op->reserved = NULL; op++; op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT; -- cgit v1.2.3 From 99259a9f44f7153ac737d68da4d910e4ec2c87aa Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 11 Mar 2016 14:54:57 -0800 Subject: Fix copyright --- src/core/channel/subchannel_call_holder.h | 2 +- test/core/end2end/dualstack_socket_test.c | 2 +- test/core/end2end/tests/simple_delayed_request.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/core/channel/subchannel_call_holder.h b/src/core/channel/subchannel_call_holder.h index acb35a8283..20793fdb7c 100644 --- a/src/core/channel/subchannel_call_holder.h +++ b/src/core/channel/subchannel_call_holder.h @@ -1,6 +1,6 @@ /* * - * Copyright 2015, Google Inc. + * Copyright 2015-2016, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/end2end/dualstack_socket_test.c b/test/core/end2end/dualstack_socket_test.c index f6531ea523..a8f83d0b05 100644 --- a/test/core/end2end/dualstack_socket_test.c +++ b/test/core/end2end/dualstack_socket_test.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015, Google Inc. + * Copyright 2015-2016, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/end2end/tests/simple_delayed_request.c b/test/core/end2end/tests/simple_delayed_request.c index ad8bce5541..7ec4f9c689 100644 --- a/test/core/end2end/tests/simple_delayed_request.c +++ b/test/core/end2end/tests/simple_delayed_request.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015, Google Inc. + * Copyright 2015-2016, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without -- cgit v1.2.3 From 5b1e659ab07e0818032f178722024bbbb6cf6de8 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 11 Mar 2016 15:05:30 -0800 Subject: Fix some bugs --- src/core/surface/call.c | 3 +++ test/core/bad_ssl/bad_ssl_test.c | 6 +++--- test/core/end2end/dualstack_socket_test.c | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/core/surface/call.c b/src/core/surface/call.c index 07a6c1a2db..30f67327d7 100644 --- a/src/core/surface/call.c +++ b/src/core/surface/call.c @@ -1107,6 +1107,9 @@ static void finish_batch(grpc_exec_ctx *exec_ctx, void *bctlp, bool success) { gpr_mu_lock(&call->mu); if (bctl->send_initial_metadata) { + if (!success) { + set_status_code(call, STATUS_FROM_CORE, GRPC_STATUS_UNAVAILABLE); + } grpc_metadata_batch_destroy( &call->metadata_batch[0 /* is_receiving */][0 /* is_trailing */]); } diff --git a/test/core/bad_ssl/bad_ssl_test.c b/test/core/bad_ssl/bad_ssl_test.c index a78a0798ae..9aced1c4af 100644 --- a/test/core/bad_ssl/bad_ssl_test.c +++ b/test/core/bad_ssl/bad_ssl_test.c @@ -31,8 +31,8 @@ * */ -#include #include +#include #include #include @@ -42,8 +42,8 @@ #include #include #include "src/core/support/string.h" -#include "test/core/util/port.h" #include "test/core/end2end/cq_verifier.h" +#include "test/core/util/port.h" #include "test/core/util/test_config.h" static void *tag(intptr_t t) { return (void *)t; } @@ -86,7 +86,7 @@ static void run_test(const char *target, size_t nops) { op = ops; op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; - op->flags = 0; + op->flags = GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY; op->reserved = NULL; op++; op->op = GRPC_OP_RECV_STATUS_ON_CLIENT; diff --git a/test/core/end2end/dualstack_socket_test.c b/test/core/end2end/dualstack_socket_test.c index a8f83d0b05..b05b138304 100644 --- a/test/core/end2end/dualstack_socket_test.c +++ b/test/core/end2end/dualstack_socket_test.c @@ -168,7 +168,7 @@ void test_connect(const char *server_host, const char *client_host, int port, op = ops; op->op = GRPC_OP_SEND_INITIAL_METADATA; op->data.send_initial_metadata.count = 0; - op->flags = 0; + op->flags = expect_ok ? GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY : 0; op->reserved = NULL; op++; op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT; -- cgit v1.2.3 From 2aa03dfa58a16d3362abd729991a9d68aa3ef8de Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Wed, 16 Mar 2016 08:24:55 -0700 Subject: Fix status prioritization --- src/core/surface/call.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/core/surface/call.c b/src/core/surface/call.c index 30f67327d7..b9763afa8a 100644 --- a/src/core/surface/call.c +++ b/src/core/surface/call.c @@ -81,11 +81,11 @@ typedef enum { /* Status came from the application layer overriding whatever the wire says */ STATUS_FROM_API_OVERRIDE = 0, - /* Status was created by some internal channel stack operation */ - STATUS_FROM_CORE, /* Status came from 'the wire' - or somewhere below the surface layer */ STATUS_FROM_WIRE, + /* Status was created by some internal channel stack operation */ + STATUS_FROM_CORE, /* Status came from the server sending status */ STATUS_FROM_SERVER_STATUS, STATUS_SOURCE_COUNT -- cgit v1.2.3 From fcf7ad692cbd98a75d7dba53acf0ac8739a9da5e Mon Sep 17 00:00:00 2001 From: David Garcia Quintas Date: Tue, 29 Mar 2016 21:55:34 -0700 Subject: Renamed subchannel_factory to client_channel_factory. Added the ability to create channels from client_channel_factory. This will be used by the grpclb code to create the channels to communicate with the LB servers. --- BUILD | 12 +-- Makefile | 4 +- binding.gyp | 2 +- build.yaml | 4 +- config.m4 | 2 +- gRPC.podspec | 6 +- grpc.gemspec | 4 +- package.json | 4 +- package.xml | 4 +- .../chttp2/client/insecure/channel_create.c | 88 ++++++++++-------- .../chttp2/client/secure/secure_channel_create.c | 100 +++++++++++++-------- src/core/lib/client_config/README.md | 2 +- .../lib/client_config/client_channel_factory.c | 55 ++++++++++++ .../lib/client_config/client_channel_factory.h | 78 ++++++++++++++++ src/core/lib/client_config/resolver_factory.h | 4 +- src/core/lib/client_config/resolver_registry.c | 4 +- src/core/lib/client_config/resolver_registry.h | 2 +- .../lib/client_config/resolvers/dns_resolver.c | 13 +-- .../client_config/resolvers/sockaddr_resolver.c | 12 +-- .../client_config/resolvers/zookeeper_resolver.c | 12 +-- src/core/lib/client_config/subchannel_factory.c | 49 ---------- src/core/lib/client_config/subchannel_factory.h | 66 -------------- src/core/lib/surface/channel.h | 2 +- src/python/grpcio/grpc_core_dependencies.py | 2 +- .../resolvers/dns_resolver_connectivity_test.c | 27 +++--- .../client_config/resolvers/dns_resolver_test.c | 27 +++--- .../resolvers/sockaddr_resolver_test.c | 27 +++--- tools/doxygen/Doxyfile.core.internal | 4 +- tools/run_tests/sources_and_headers.json | 12 +-- vsprojects/vcxproj/grpc/grpc.vcxproj | 6 +- vsprojects/vcxproj/grpc/grpc.vcxproj.filters | 12 +-- .../vcxproj/grpc_unsecure/grpc_unsecure.vcxproj | 6 +- .../grpc_unsecure/grpc_unsecure.vcxproj.filters | 12 +-- 33 files changed, 372 insertions(+), 292 deletions(-) create mode 100644 src/core/lib/client_config/client_channel_factory.c create mode 100644 src/core/lib/client_config/client_channel_factory.h delete mode 100644 src/core/lib/client_config/subchannel_factory.c delete mode 100644 src/core/lib/client_config/subchannel_factory.h (limited to 'src') diff --git a/BUILD b/BUILD index fc4dfe8d9a..069f134a1c 100644 --- a/BUILD +++ b/BUILD @@ -195,6 +195,7 @@ cc_library( "src/core/lib/channel/http_client_filter.h", "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.h", "src/core/lib/client_config/initial_connect_string.h", @@ -210,7 +211,6 @@ cc_library( "src/core/lib/client_config/resolvers/dns_resolver.h", "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.h", "src/core/lib/compression/algorithm_metadata.h", @@ -339,6 +339,7 @@ cc_library( "src/core/lib/channel/http_client_filter.c", "src/core/lib/channel/http_server_filter.c", "src/core/lib/channel/subchannel_call_holder.c", + "src/core/lib/client_config/client_channel_factory.c", "src/core/lib/client_config/client_config.c", "src/core/lib/client_config/connector.c", "src/core/lib/client_config/default_initial_connect_string.c", @@ -355,7 +356,6 @@ cc_library( "src/core/lib/client_config/resolvers/dns_resolver.c", "src/core/lib/client_config/resolvers/sockaddr_resolver.c", "src/core/lib/client_config/subchannel.c", - "src/core/lib/client_config/subchannel_factory.c", "src/core/lib/client_config/subchannel_index.c", "src/core/lib/client_config/uri_parser.c", "src/core/lib/compression/compression_algorithm.c", @@ -566,6 +566,7 @@ cc_library( "src/core/lib/channel/http_client_filter.h", "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.h", "src/core/lib/client_config/initial_connect_string.h", @@ -581,7 +582,6 @@ cc_library( "src/core/lib/client_config/resolvers/dns_resolver.h", "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.h", "src/core/lib/compression/algorithm_metadata.h", @@ -694,6 +694,7 @@ cc_library( "src/core/lib/channel/http_client_filter.c", "src/core/lib/channel/http_server_filter.c", "src/core/lib/channel/subchannel_call_holder.c", + "src/core/lib/client_config/client_channel_factory.c", "src/core/lib/client_config/client_config.c", "src/core/lib/client_config/connector.c", "src/core/lib/client_config/default_initial_connect_string.c", @@ -710,7 +711,6 @@ cc_library( "src/core/lib/client_config/resolvers/dns_resolver.c", "src/core/lib/client_config/resolvers/sockaddr_resolver.c", "src/core/lib/client_config/subchannel.c", - "src/core/lib/client_config/subchannel_factory.c", "src/core/lib/client_config/subchannel_index.c", "src/core/lib/client_config/uri_parser.c", "src/core/lib/compression/compression_algorithm.c", @@ -1404,6 +1404,7 @@ objc_library( "src/core/lib/channel/http_client_filter.c", "src/core/lib/channel/http_server_filter.c", "src/core/lib/channel/subchannel_call_holder.c", + "src/core/lib/client_config/client_channel_factory.c", "src/core/lib/client_config/client_config.c", "src/core/lib/client_config/connector.c", "src/core/lib/client_config/default_initial_connect_string.c", @@ -1420,7 +1421,6 @@ objc_library( "src/core/lib/client_config/resolvers/dns_resolver.c", "src/core/lib/client_config/resolvers/sockaddr_resolver.c", "src/core/lib/client_config/subchannel.c", - "src/core/lib/client_config/subchannel_factory.c", "src/core/lib/client_config/subchannel_index.c", "src/core/lib/client_config/uri_parser.c", "src/core/lib/compression/compression_algorithm.c", @@ -1573,6 +1573,7 @@ objc_library( "src/core/lib/channel/http_client_filter.h", "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.h", "src/core/lib/client_config/initial_connect_string.h", @@ -1588,7 +1589,6 @@ objc_library( "src/core/lib/client_config/resolvers/dns_resolver.h", "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.h", "src/core/lib/compression/algorithm_metadata.h", diff --git a/Makefile b/Makefile index 2286abe625..b4815461ef 100644 --- a/Makefile +++ b/Makefile @@ -2477,6 +2477,7 @@ LIBGRPC_SRC = \ src/core/lib/channel/http_client_filter.c \ src/core/lib/channel/http_server_filter.c \ src/core/lib/channel/subchannel_call_holder.c \ + src/core/lib/client_config/client_channel_factory.c \ src/core/lib/client_config/client_config.c \ src/core/lib/client_config/connector.c \ src/core/lib/client_config/default_initial_connect_string.c \ @@ -2493,7 +2494,6 @@ LIBGRPC_SRC = \ src/core/lib/client_config/resolvers/dns_resolver.c \ src/core/lib/client_config/resolvers/sockaddr_resolver.c \ src/core/lib/client_config/subchannel.c \ - src/core/lib/client_config/subchannel_factory.c \ src/core/lib/client_config/subchannel_index.c \ src/core/lib/client_config/uri_parser.c \ src/core/lib/compression/compression_algorithm.c \ @@ -2836,6 +2836,7 @@ LIBGRPC_UNSECURE_SRC = \ src/core/lib/channel/http_client_filter.c \ src/core/lib/channel/http_server_filter.c \ src/core/lib/channel/subchannel_call_holder.c \ + src/core/lib/client_config/client_channel_factory.c \ src/core/lib/client_config/client_config.c \ src/core/lib/client_config/connector.c \ src/core/lib/client_config/default_initial_connect_string.c \ @@ -2852,7 +2853,6 @@ LIBGRPC_UNSECURE_SRC = \ src/core/lib/client_config/resolvers/dns_resolver.c \ src/core/lib/client_config/resolvers/sockaddr_resolver.c \ src/core/lib/client_config/subchannel.c \ - src/core/lib/client_config/subchannel_factory.c \ src/core/lib/client_config/subchannel_index.c \ src/core/lib/client_config/uri_parser.c \ src/core/lib/compression/compression_algorithm.c \ diff --git a/binding.gyp b/binding.gyp index a1cdf2ec36..39cc84243f 100644 --- a/binding.gyp +++ b/binding.gyp @@ -601,6 +601,7 @@ 'src/core/lib/channel/http_client_filter.c', 'src/core/lib/channel/http_server_filter.c', 'src/core/lib/channel/subchannel_call_holder.c', + 'src/core/lib/client_config/client_channel_factory.c', 'src/core/lib/client_config/client_config.c', 'src/core/lib/client_config/connector.c', 'src/core/lib/client_config/default_initial_connect_string.c', @@ -617,7 +618,6 @@ 'src/core/lib/client_config/resolvers/dns_resolver.c', 'src/core/lib/client_config/resolvers/sockaddr_resolver.c', 'src/core/lib/client_config/subchannel.c', - 'src/core/lib/client_config/subchannel_factory.c', 'src/core/lib/client_config/subchannel_index.c', 'src/core/lib/client_config/uri_parser.c', 'src/core/lib/compression/compression_algorithm.c', diff --git a/build.yaml b/build.yaml index 43d3c680b8..0eb40d7472 100644 --- a/build.yaml +++ b/build.yaml @@ -259,6 +259,7 @@ filegroups: - src/core/lib/channel/http_client_filter.h - src/core/lib/channel/http_server_filter.h - src/core/lib/channel/subchannel_call_holder.h + - src/core/lib/client_config/client_channel_factory.h - src/core/lib/client_config/client_config.h - src/core/lib/client_config/connector.h - src/core/lib/client_config/initial_connect_string.h @@ -274,7 +275,6 @@ filegroups: - src/core/lib/client_config/resolvers/dns_resolver.h - src/core/lib/client_config/resolvers/sockaddr_resolver.h - src/core/lib/client_config/subchannel.h - - src/core/lib/client_config/subchannel_factory.h - src/core/lib/client_config/subchannel_index.h - src/core/lib/client_config/uri_parser.h - src/core/lib/compression/algorithm_metadata.h @@ -359,6 +359,7 @@ filegroups: - src/core/lib/channel/http_client_filter.c - src/core/lib/channel/http_server_filter.c - src/core/lib/channel/subchannel_call_holder.c + - src/core/lib/client_config/client_channel_factory.c - src/core/lib/client_config/client_config.c - src/core/lib/client_config/connector.c - src/core/lib/client_config/default_initial_connect_string.c @@ -375,7 +376,6 @@ filegroups: - src/core/lib/client_config/resolvers/dns_resolver.c - src/core/lib/client_config/resolvers/sockaddr_resolver.c - src/core/lib/client_config/subchannel.c - - src/core/lib/client_config/subchannel_factory.c - src/core/lib/client_config/subchannel_index.c - src/core/lib/client_config/uri_parser.c - src/core/lib/compression/compression_algorithm.c diff --git a/config.m4 b/config.m4 index 653b287067..5b9e792564 100644 --- a/config.m4 +++ b/config.m4 @@ -123,6 +123,7 @@ if test "$PHP_GRPC" != "no"; then src/core/lib/channel/http_client_filter.c \ src/core/lib/channel/http_server_filter.c \ src/core/lib/channel/subchannel_call_holder.c \ + src/core/lib/client_config/client_channel_factory.c \ src/core/lib/client_config/client_config.c \ src/core/lib/client_config/connector.c \ src/core/lib/client_config/default_initial_connect_string.c \ @@ -139,7 +140,6 @@ if test "$PHP_GRPC" != "no"; then src/core/lib/client_config/resolvers/dns_resolver.c \ src/core/lib/client_config/resolvers/sockaddr_resolver.c \ src/core/lib/client_config/subchannel.c \ - src/core/lib/client_config/subchannel_factory.c \ src/core/lib/client_config/subchannel_index.c \ src/core/lib/client_config/uri_parser.c \ src/core/lib/compression/compression_algorithm.c \ diff --git a/gRPC.podspec b/gRPC.podspec index 08330eb8e1..f518e48fb9 100644 --- a/gRPC.podspec +++ b/gRPC.podspec @@ -197,6 +197,7 @@ Pod::Spec.new do |s| 'src/core/lib/channel/http_client_filter.h', 'src/core/lib/channel/http_server_filter.h', 'src/core/lib/channel/subchannel_call_holder.h', + 'src/core/lib/client_config/client_channel_factory.h', 'src/core/lib/client_config/client_config.h', 'src/core/lib/client_config/connector.h', 'src/core/lib/client_config/initial_connect_string.h', @@ -212,7 +213,6 @@ Pod::Spec.new do |s| 'src/core/lib/client_config/resolvers/dns_resolver.h', 'src/core/lib/client_config/resolvers/sockaddr_resolver.h', 'src/core/lib/client_config/subchannel.h', - 'src/core/lib/client_config/subchannel_factory.h', 'src/core/lib/client_config/subchannel_index.h', 'src/core/lib/client_config/uri_parser.h', 'src/core/lib/compression/algorithm_metadata.h', @@ -358,6 +358,7 @@ Pod::Spec.new do |s| 'src/core/lib/channel/http_client_filter.c', 'src/core/lib/channel/http_server_filter.c', 'src/core/lib/channel/subchannel_call_holder.c', + 'src/core/lib/client_config/client_channel_factory.c', 'src/core/lib/client_config/client_config.c', 'src/core/lib/client_config/connector.c', 'src/core/lib/client_config/default_initial_connect_string.c', @@ -374,7 +375,6 @@ Pod::Spec.new do |s| 'src/core/lib/client_config/resolvers/dns_resolver.c', 'src/core/lib/client_config/resolvers/sockaddr_resolver.c', 'src/core/lib/client_config/subchannel.c', - 'src/core/lib/client_config/subchannel_factory.c', 'src/core/lib/client_config/subchannel_index.c', 'src/core/lib/client_config/uri_parser.c', 'src/core/lib/compression/compression_algorithm.c', @@ -528,6 +528,7 @@ Pod::Spec.new do |s| 'src/core/lib/channel/http_client_filter.h', 'src/core/lib/channel/http_server_filter.h', 'src/core/lib/channel/subchannel_call_holder.h', + 'src/core/lib/client_config/client_channel_factory.h', 'src/core/lib/client_config/client_config.h', 'src/core/lib/client_config/connector.h', 'src/core/lib/client_config/initial_connect_string.h', @@ -543,7 +544,6 @@ Pod::Spec.new do |s| 'src/core/lib/client_config/resolvers/dns_resolver.h', 'src/core/lib/client_config/resolvers/sockaddr_resolver.h', 'src/core/lib/client_config/subchannel.h', - 'src/core/lib/client_config/subchannel_factory.h', 'src/core/lib/client_config/subchannel_index.h', 'src/core/lib/client_config/uri_parser.h', 'src/core/lib/compression/algorithm_metadata.h', diff --git a/grpc.gemspec b/grpc.gemspec index c516f5278f..94677aa6af 100755 --- a/grpc.gemspec +++ b/grpc.gemspec @@ -193,6 +193,7 @@ Gem::Specification.new do |s| s.files += %w( src/core/lib/channel/http_client_filter.h ) s.files += %w( src/core/lib/channel/http_server_filter.h ) s.files += %w( src/core/lib/channel/subchannel_call_holder.h ) + s.files += %w( src/core/lib/client_config/client_channel_factory.h ) s.files += %w( src/core/lib/client_config/client_config.h ) s.files += %w( src/core/lib/client_config/connector.h ) s.files += %w( src/core/lib/client_config/initial_connect_string.h ) @@ -208,7 +209,6 @@ Gem::Specification.new do |s| s.files += %w( src/core/lib/client_config/resolvers/dns_resolver.h ) s.files += %w( src/core/lib/client_config/resolvers/sockaddr_resolver.h ) s.files += %w( src/core/lib/client_config/subchannel.h ) - s.files += %w( src/core/lib/client_config/subchannel_factory.h ) s.files += %w( src/core/lib/client_config/subchannel_index.h ) s.files += %w( src/core/lib/client_config/uri_parser.h ) s.files += %w( src/core/lib/compression/algorithm_metadata.h ) @@ -341,6 +341,7 @@ Gem::Specification.new do |s| s.files += %w( src/core/lib/channel/http_client_filter.c ) s.files += %w( src/core/lib/channel/http_server_filter.c ) s.files += %w( src/core/lib/channel/subchannel_call_holder.c ) + s.files += %w( src/core/lib/client_config/client_channel_factory.c ) s.files += %w( src/core/lib/client_config/client_config.c ) s.files += %w( src/core/lib/client_config/connector.c ) s.files += %w( src/core/lib/client_config/default_initial_connect_string.c ) @@ -357,7 +358,6 @@ Gem::Specification.new do |s| s.files += %w( src/core/lib/client_config/resolvers/dns_resolver.c ) s.files += %w( src/core/lib/client_config/resolvers/sockaddr_resolver.c ) s.files += %w( src/core/lib/client_config/subchannel.c ) - s.files += %w( src/core/lib/client_config/subchannel_factory.c ) s.files += %w( src/core/lib/client_config/subchannel_index.c ) s.files += %w( src/core/lib/client_config/uri_parser.c ) s.files += %w( src/core/lib/compression/compression_algorithm.c ) diff --git a/package.json b/package.json index 4da7c708f0..99aea807fc 100644 --- a/package.json +++ b/package.json @@ -136,6 +136,7 @@ "src/core/lib/channel/http_client_filter.h", "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.h", "src/core/lib/client_config/initial_connect_string.h", @@ -151,7 +152,6 @@ "src/core/lib/client_config/resolvers/dns_resolver.h", "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.h", "src/core/lib/compression/algorithm_metadata.h", @@ -284,6 +284,7 @@ "src/core/lib/channel/http_client_filter.c", "src/core/lib/channel/http_server_filter.c", "src/core/lib/channel/subchannel_call_holder.c", + "src/core/lib/client_config/client_channel_factory.c", "src/core/lib/client_config/client_config.c", "src/core/lib/client_config/connector.c", "src/core/lib/client_config/default_initial_connect_string.c", @@ -300,7 +301,6 @@ "src/core/lib/client_config/resolvers/dns_resolver.c", "src/core/lib/client_config/resolvers/sockaddr_resolver.c", "src/core/lib/client_config/subchannel.c", - "src/core/lib/client_config/subchannel_factory.c", "src/core/lib/client_config/subchannel_index.c", "src/core/lib/client_config/uri_parser.c", "src/core/lib/compression/compression_algorithm.c", diff --git a/package.xml b/package.xml index a40cd160ae..c124181161 100644 --- a/package.xml +++ b/package.xml @@ -197,6 +197,7 @@ + @@ -212,7 +213,6 @@ - @@ -345,6 +345,7 @@ + @@ -361,7 +362,6 @@ - diff --git a/src/core/ext/transport/chttp2/client/insecure/channel_create.c b/src/core/ext/transport/chttp2/client/insecure/channel_create.c index cf987a02e0..fdf81ae59a 100644 --- a/src/core/ext/transport/chttp2/client/insecure/channel_create.c +++ b/src/core/ext/transport/chttp2/client/insecure/channel_create.c @@ -136,31 +136,35 @@ static const grpc_connector_vtable connector_vtable = { connector_ref, connector_unref, connector_shutdown, connector_connect}; typedef struct { - grpc_subchannel_factory base; + grpc_client_channel_factory base; gpr_refcount refs; grpc_channel_args *merge_args; grpc_channel *master; -} subchannel_factory; +} client_channel_factory; -static void subchannel_factory_ref(grpc_subchannel_factory *scf) { - subchannel_factory *f = (subchannel_factory *)scf; +static void client_channel_factory_ref( + grpc_client_channel_factory *cc_factory) { + client_channel_factory *f = (client_channel_factory *)cc_factory; gpr_ref(&f->refs); } -static void subchannel_factory_unref(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *scf) { - subchannel_factory *f = (subchannel_factory *)scf; +static void client_channel_factory_unref( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory) { + client_channel_factory *f = (client_channel_factory *)cc_factory; if (gpr_unref(&f->refs)) { - GRPC_CHANNEL_INTERNAL_UNREF(exec_ctx, f->master, "subchannel_factory"); + if (f->master != NULL) { + GRPC_CHANNEL_INTERNAL_UNREF(exec_ctx, f->master, + "client_channel_factory"); + } grpc_channel_args_destroy(f->merge_args); gpr_free(f); } } -static grpc_subchannel *subchannel_factory_create_subchannel( - grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *scf, +static grpc_subchannel *client_channel_factory_create_subchannel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, grpc_subchannel_args *args) { - subchannel_factory *f = (subchannel_factory *)scf; + client_channel_factory *f = (client_channel_factory *)cc_factory; connector *c = gpr_malloc(sizeof(*c)); grpc_channel_args *final_args = grpc_channel_args_merge(args->args, f->merge_args); @@ -175,9 +179,32 @@ static grpc_subchannel *subchannel_factory_create_subchannel( return s; } -static const grpc_subchannel_factory_vtable subchannel_factory_vtable = { - subchannel_factory_ref, subchannel_factory_unref, - subchannel_factory_create_subchannel}; +static grpc_channel *client_channel_factory_create_channel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, + const char *target, grpc_channel_args *args) { + client_channel_factory *f = (client_channel_factory *)cc_factory; + grpc_channel_args *final_args = grpc_channel_args_merge(args, f->merge_args); + grpc_channel *channel = grpc_channel_create(exec_ctx, target, final_args, + GRPC_CLIENT_CHANNEL, NULL); + grpc_channel_args_destroy(final_args); + grpc_resolver *resolver = grpc_resolver_create(target, &f->base); + if (!resolver) { + GRPC_CHANNEL_INTERNAL_UNREF(exec_ctx, channel, + "client_channel_factory_create_channel"); + return NULL; + } + + grpc_client_channel_set_resolver( + exec_ctx, grpc_channel_get_channel_stack(channel), resolver); + GRPC_RESOLVER_UNREF(exec_ctx, resolver, "create_channel"); + + return channel; +} + +static const grpc_client_channel_factory_vtable client_channel_factory_vtable = + {client_channel_factory_ref, client_channel_factory_unref, + client_channel_factory_create_subchannel, + client_channel_factory_create_channel}; /* Create a client channel: Asynchronously: - resolve target @@ -186,38 +213,27 @@ static const grpc_subchannel_factory_vtable subchannel_factory_vtable = { grpc_channel *grpc_insecure_channel_create(const char *target, const grpc_channel_args *args, void *reserved) { - grpc_channel *channel = NULL; - grpc_resolver *resolver; - subchannel_factory *f; grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT; GRPC_API_TRACE( "grpc_insecure_channel_create(target=%p, args=%p, reserved=%p)", 3, (target, args, reserved)); GPR_ASSERT(!reserved); - channel = - grpc_channel_create(&exec_ctx, target, args, GRPC_CLIENT_CHANNEL, NULL); - - f = gpr_malloc(sizeof(*f)); - f->base.vtable = &subchannel_factory_vtable; + client_channel_factory *f = gpr_malloc(sizeof(*f)); + memset(f, 0, sizeof(*f)); + f->base.vtable = &client_channel_factory_vtable; gpr_ref_init(&f->refs, 1); f->merge_args = grpc_channel_args_copy(args); - f->master = channel; - GRPC_CHANNEL_INTERNAL_REF(f->master, "subchannel_factory"); - resolver = grpc_resolver_create(target, &f->base); - if (!resolver) { - GRPC_CHANNEL_INTERNAL_UNREF(&exec_ctx, f->master, "subchannel_factory"); - grpc_subchannel_factory_unref(&exec_ctx, &f->base); - grpc_exec_ctx_finish(&exec_ctx); - return NULL; - } - grpc_client_channel_set_resolver( - &exec_ctx, grpc_channel_get_channel_stack(channel), resolver); - GRPC_RESOLVER_UNREF(&exec_ctx, resolver, "create"); - grpc_subchannel_factory_unref(&exec_ctx, &f->base); + grpc_channel *channel = + client_channel_factory_create_channel(&exec_ctx, &f->base, target, NULL); + if (channel != NULL) { + f->master = channel; + GRPC_CHANNEL_INTERNAL_REF(f->master, "grpc_insecure_channel_create"); + } + grpc_client_channel_factory_unref(&exec_ctx, &f->base); grpc_exec_ctx_finish(&exec_ctx); - return channel; + return channel; /* may be NULL */ } diff --git a/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c b/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c index 203475ba52..eecca9cf06 100644 --- a/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c +++ b/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c @@ -192,34 +192,38 @@ static const grpc_connector_vtable connector_vtable = { connector_ref, connector_unref, connector_shutdown, connector_connect}; typedef struct { - grpc_subchannel_factory base; + grpc_client_channel_factory base; gpr_refcount refs; grpc_channel_args *merge_args; grpc_channel_security_connector *security_connector; grpc_channel *master; -} subchannel_factory; +} client_channel_factory; -static void subchannel_factory_ref(grpc_subchannel_factory *scf) { - subchannel_factory *f = (subchannel_factory *)scf; +static void client_channel_factory_ref( + grpc_client_channel_factory *cc_factory) { + client_channel_factory *f = (client_channel_factory *)cc_factory; gpr_ref(&f->refs); } -static void subchannel_factory_unref(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *scf) { - subchannel_factory *f = (subchannel_factory *)scf; +static void client_channel_factory_unref( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory) { + client_channel_factory *f = (client_channel_factory *)cc_factory; if (gpr_unref(&f->refs)) { GRPC_SECURITY_CONNECTOR_UNREF(&f->security_connector->base, - "subchannel_factory"); - GRPC_CHANNEL_INTERNAL_UNREF(exec_ctx, f->master, "subchannel_factory"); + "client_channel_factory"); + if (f->master != NULL) { + GRPC_CHANNEL_INTERNAL_UNREF(exec_ctx, f->master, + "client_channel_factory"); + } grpc_channel_args_destroy(f->merge_args); gpr_free(f); } } -static grpc_subchannel *subchannel_factory_create_subchannel( - grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *scf, +static grpc_subchannel *client_channel_factory_create_subchannel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, grpc_subchannel_args *args) { - subchannel_factory *f = (subchannel_factory *)scf; + client_channel_factory *f = (client_channel_factory *)cc_factory; connector *c = gpr_malloc(sizeof(*c)); grpc_channel_args *final_args = grpc_channel_args_merge(args->args, f->merge_args); @@ -236,9 +240,36 @@ static grpc_subchannel *subchannel_factory_create_subchannel( return s; } -static const grpc_subchannel_factory_vtable subchannel_factory_vtable = { - subchannel_factory_ref, subchannel_factory_unref, - subchannel_factory_create_subchannel}; +static grpc_channel *client_channel_factory_create_channel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, + const char *target, grpc_channel_args *args) { + client_channel_factory *f = (client_channel_factory *)cc_factory; + + grpc_channel_args *final_args = grpc_channel_args_merge(args, f->merge_args); + grpc_channel *channel = grpc_channel_create(exec_ctx, target, final_args, + GRPC_CLIENT_CHANNEL, NULL); + grpc_channel_args_destroy(final_args); + + grpc_resolver *resolver = grpc_resolver_create(target, &f->base); + if (resolver != NULL) { + grpc_client_channel_set_resolver( + exec_ctx, grpc_channel_get_channel_stack(channel), resolver); + GRPC_RESOLVER_UNREF(exec_ctx, resolver, "create"); + } else { + GRPC_CHANNEL_INTERNAL_UNREF(exec_ctx, channel, + "client_channel_factory_create_channel"); + channel = NULL; + } + + GRPC_SECURITY_CONNECTOR_UNREF(&f->security_connector->base, + "client_channel_factory_create_channel"); + return channel; +} + +static const grpc_client_channel_factory_vtable client_channel_factory_vtable = + {client_channel_factory_ref, client_channel_factory_unref, + client_channel_factory_create_subchannel, + client_channel_factory_create_channel}; /* Create a secure client channel: Asynchronously: - resolve target @@ -248,13 +279,11 @@ grpc_channel *grpc_secure_channel_create(grpc_channel_credentials *creds, const char *target, const grpc_channel_args *args, void *reserved) { - grpc_channel *channel; grpc_arg connector_arg; grpc_channel_args *args_copy; grpc_channel_args *new_args_from_connector; grpc_channel_security_connector *security_connector; - grpc_resolver *resolver; - subchannel_factory *f; + client_channel_factory *f; grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT; GRPC_API_TRACE( @@ -284,35 +313,30 @@ grpc_channel *grpc_secure_channel_create(grpc_channel_credentials *creds, new_args_from_connector != NULL ? new_args_from_connector : args, &connector_arg, 1); - channel = grpc_channel_create(&exec_ctx, target, args_copy, - GRPC_CLIENT_CHANNEL, NULL); - f = gpr_malloc(sizeof(*f)); - f->base.vtable = &subchannel_factory_vtable; + memset(f, 0, sizeof(*f)); + f->base.vtable = &client_channel_factory_vtable; gpr_ref_init(&f->refs, 1); - GRPC_SECURITY_CONNECTOR_REF(&security_connector->base, "subchannel_factory"); - f->security_connector = security_connector; + f->merge_args = grpc_channel_args_copy(args_copy); - f->master = channel; - GRPC_CHANNEL_INTERNAL_REF(channel, "subchannel_factory"); - resolver = grpc_resolver_create(target, &f->base); - if (resolver) { - grpc_client_channel_set_resolver( - &exec_ctx, grpc_channel_get_channel_stack(channel), resolver); - GRPC_RESOLVER_UNREF(&exec_ctx, resolver, "create"); - } - grpc_subchannel_factory_unref(&exec_ctx, &f->base); - GRPC_SECURITY_CONNECTOR_UNREF(&security_connector->base, "channel_create"); grpc_channel_args_destroy(args_copy); if (new_args_from_connector != NULL) { grpc_channel_args_destroy(new_args_from_connector); } - if (!resolver) { - GRPC_CHANNEL_INTERNAL_UNREF(&exec_ctx, channel, "subchannel_factory"); - channel = NULL; + GRPC_SECURITY_CONNECTOR_REF(&security_connector->base, + "grpc_secure_channel_create"); + f->security_connector = security_connector; + + grpc_channel *channel = + client_channel_factory_create_channel(&exec_ctx, &f->base, target, NULL); + if (channel != NULL) { + f->master = channel; + GRPC_CHANNEL_INTERNAL_REF(f->master, "grpc_secure_channel_create"); } + + grpc_client_channel_factory_unref(&exec_ctx, &f->base); grpc_exec_ctx_finish(&exec_ctx); - return channel; + return channel; /* may be NULL */ } diff --git a/src/core/lib/client_config/README.md b/src/core/lib/client_config/README.md index fff7a5af5b..7024fd540d 100644 --- a/src/core/lib/client_config/README.md +++ b/src/core/lib/client_config/README.md @@ -40,7 +40,7 @@ decisions (for example, by avoiding disconnected backends). Configured sub-channels are fully setup to participate in the grpc data plane. Their behavior is specified by a set of grpc channel filters defined at their construction. To customize this behavior, resolvers build -grpc_subchannel_factory objects, which use the decorator pattern to customize +grpc_client_channel_factory objects, which use the decorator pattern to customize construction arguments for concrete grpc_subchannel instances. diff --git a/src/core/lib/client_config/client_channel_factory.c b/src/core/lib/client_config/client_channel_factory.c new file mode 100644 index 0000000000..c079ce09dd --- /dev/null +++ b/src/core/lib/client_config/client_channel_factory.c @@ -0,0 +1,55 @@ +/* + * + * Copyright 2015-2016, Google Inc. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include "src/core/lib/client_config/client_channel_factory.h" + +void grpc_client_channel_factory_ref(grpc_client_channel_factory* factory) { + factory->vtable->ref(factory); +} + +void grpc_client_channel_factory_unref(grpc_exec_ctx* exec_ctx, + grpc_client_channel_factory* factory) { + factory->vtable->unref(exec_ctx, factory); +} + +grpc_subchannel* grpc_client_channel_factory_create_subchannel( + grpc_exec_ctx* exec_ctx, grpc_client_channel_factory* factory, + grpc_subchannel_args* args) { + return factory->vtable->create_subchannel(exec_ctx, factory, args); +} + +grpc_channel* grpc_client_channel_factory_create_channel( + grpc_exec_ctx* exec_ctx, grpc_client_channel_factory* factory, + const char* target, grpc_channel_args* args) { + return factory->vtable->create_channel(exec_ctx, factory, target, args); +} diff --git a/src/core/lib/client_config/client_channel_factory.h b/src/core/lib/client_config/client_channel_factory.h new file mode 100644 index 0000000000..3dd9dfea12 --- /dev/null +++ b/src/core/lib/client_config/client_channel_factory.h @@ -0,0 +1,78 @@ +/* + * + * Copyright 2015-2016, Google Inc. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef GRPC_CORE_LIB_CLIENT_CONFIG_CLIENT_CHANNEL_FACTORY_H +#define GRPC_CORE_LIB_CLIENT_CONFIG_CLIENT_CHANNEL_FACTORY_H + +#include +#include + +#include "src/core/lib/channel/channel_stack.h" +#include "src/core/lib/client_config/subchannel.h" + +typedef struct grpc_client_channel_factory grpc_client_channel_factory; +typedef struct grpc_client_channel_factory_vtable + grpc_client_channel_factory_vtable; + +/** Constructor for new configured channels. + Creating decorators around this type is encouraged to adapt behavior. */ +struct grpc_client_channel_factory { + const grpc_client_channel_factory_vtable *vtable; +}; + +struct grpc_client_channel_factory_vtable { + void (*ref)(grpc_client_channel_factory *factory); + void (*unref)(grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory); + grpc_subchannel *(*create_subchannel)(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *factory, + grpc_subchannel_args *args); + grpc_channel *(*create_channel)(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *factory, + const char *target, grpc_channel_args *args); +}; + +void grpc_client_channel_factory_ref(grpc_client_channel_factory *factory); +void grpc_client_channel_factory_unref(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *factory); + +/** Create a new grpc_subchannel */ +grpc_subchannel *grpc_client_channel_factory_create_subchannel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, + grpc_subchannel_args *args); + +/** Create a new grpc_channel */ +grpc_channel *grpc_client_channel_factory_create_channel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, + const char *target, grpc_channel_args *args); + +#endif /* GRPC_CORE_LIB_CLIENT_CONFIG_CLIENT_CHANNEL_FACTORY_H */ diff --git a/src/core/lib/client_config/resolver_factory.h b/src/core/lib/client_config/resolver_factory.h index 7765c3c844..91bdbfe01c 100644 --- a/src/core/lib/client_config/resolver_factory.h +++ b/src/core/lib/client_config/resolver_factory.h @@ -34,8 +34,8 @@ #ifndef GRPC_CORE_LIB_CLIENT_CONFIG_RESOLVER_FACTORY_H #define GRPC_CORE_LIB_CLIENT_CONFIG_RESOLVER_FACTORY_H +#include "src/core/lib/client_config/client_channel_factory.h" #include "src/core/lib/client_config/resolver.h" -#include "src/core/lib/client_config/subchannel_factory.h" #include "src/core/lib/client_config/uri_parser.h" typedef struct grpc_resolver_factory grpc_resolver_factory; @@ -49,7 +49,7 @@ struct grpc_resolver_factory { typedef struct grpc_resolver_args { grpc_uri *uri; - grpc_subchannel_factory *subchannel_factory; + grpc_client_channel_factory *client_channel_factory; } grpc_resolver_args; struct grpc_resolver_factory_vtable { diff --git a/src/core/lib/client_config/resolver_registry.c b/src/core/lib/client_config/resolver_registry.c index 29bd00c284..ff03041bc5 100644 --- a/src/core/lib/client_config/resolver_registry.c +++ b/src/core/lib/client_config/resolver_registry.c @@ -115,14 +115,14 @@ static grpc_resolver_factory *resolve_factory(const char *target, } grpc_resolver *grpc_resolver_create( - const char *target, grpc_subchannel_factory *subchannel_factory) { + const char *target, grpc_client_channel_factory *client_channel_factory) { grpc_uri *uri = NULL; grpc_resolver_factory *factory = resolve_factory(target, &uri); grpc_resolver *resolver; grpc_resolver_args args; memset(&args, 0, sizeof(args)); args.uri = uri; - args.subchannel_factory = subchannel_factory; + args.client_channel_factory = client_channel_factory; resolver = grpc_resolver_factory_create_resolver(factory, &args); grpc_uri_destroy(uri); return resolver; diff --git a/src/core/lib/client_config/resolver_registry.h b/src/core/lib/client_config/resolver_registry.h index 22289ca6bd..eec830bbcb 100644 --- a/src/core/lib/client_config/resolver_registry.h +++ b/src/core/lib/client_config/resolver_registry.h @@ -56,7 +56,7 @@ void grpc_register_resolver_type(grpc_resolver_factory *factory); return it. If a resolver factory was not found, return NULL. */ grpc_resolver *grpc_resolver_create( - const char *target, grpc_subchannel_factory *subchannel_factory); + const char *target, grpc_client_channel_factory *client_channel_factory); /** Given a target, return a (freshly allocated with gpr_malloc) string representing the default authority to pass from a client. */ diff --git a/src/core/lib/client_config/resolvers/dns_resolver.c b/src/core/lib/client_config/resolvers/dns_resolver.c index ab445730ad..078fda298a 100644 --- a/src/core/lib/client_config/resolvers/dns_resolver.c +++ b/src/core/lib/client_config/resolvers/dns_resolver.c @@ -60,7 +60,7 @@ typedef struct { /** default port to use */ char *default_port; /** subchannel factory */ - grpc_subchannel_factory *subchannel_factory; + grpc_client_channel_factory *client_channel_factory; /** load balancing policy name */ char *lb_policy_name; @@ -178,8 +178,9 @@ static void dns_on_resolved(grpc_exec_ctx *exec_ctx, void *arg, memset(&args, 0, sizeof(args)); args.addr = (struct sockaddr *)(addresses->addrs[i].addr); args.addr_len = (size_t)addresses->addrs[i].len; - grpc_subchannel *subchannel = grpc_subchannel_factory_create_subchannel( - exec_ctx, r->subchannel_factory, &args); + grpc_subchannel *subchannel = + grpc_client_channel_factory_create_subchannel( + exec_ctx, r->client_channel_factory, &args); if (subchannel != NULL) { subchannels[naddrs++] = subchannel; } @@ -244,7 +245,7 @@ static void dns_destroy(grpc_exec_ctx *exec_ctx, grpc_resolver *gr) { if (r->resolved_config) { grpc_client_config_unref(exec_ctx, r->resolved_config); } - grpc_subchannel_factory_unref(exec_ctx, r->subchannel_factory); + grpc_client_channel_factory_unref(exec_ctx, r->client_channel_factory); gpr_free(r->name); gpr_free(r->default_port); gpr_free(r->lb_policy_name); @@ -271,10 +272,10 @@ static grpc_resolver *dns_create(grpc_resolver_args *args, grpc_resolver_init(&r->base, &dns_resolver_vtable); r->name = gpr_strdup(path); r->default_port = gpr_strdup(default_port); - r->subchannel_factory = args->subchannel_factory; + r->client_channel_factory = args->client_channel_factory; gpr_backoff_init(&r->backoff_state, BACKOFF_MULTIPLIER, BACKOFF_JITTER, BACKOFF_MIN_SECONDS * 1000, BACKOFF_MAX_SECONDS * 1000); - grpc_subchannel_factory_ref(r->subchannel_factory); + grpc_client_channel_factory_ref(r->client_channel_factory); r->lb_policy_name = gpr_strdup(lb_policy_name); return &r->base; } diff --git a/src/core/lib/client_config/resolvers/sockaddr_resolver.c b/src/core/lib/client_config/resolvers/sockaddr_resolver.c index 66cddc3ed9..c2492a44b4 100644 --- a/src/core/lib/client_config/resolvers/sockaddr_resolver.c +++ b/src/core/lib/client_config/resolvers/sockaddr_resolver.c @@ -53,7 +53,7 @@ typedef struct { /** refcount */ gpr_refcount refs; /** subchannel factory */ - grpc_subchannel_factory *subchannel_factory; + grpc_client_channel_factory *client_channel_factory; /** load balancing policy name */ char *lb_policy_name; @@ -139,8 +139,8 @@ static void sockaddr_maybe_finish_next_locked(grpc_exec_ctx *exec_ctx, memset(&args, 0, sizeof(args)); args.addr = (struct sockaddr *)&r->addrs[i]; args.addr_len = r->addrs_len[i]; - subchannels[i] = grpc_subchannel_factory_create_subchannel( - exec_ctx, r->subchannel_factory, &args); + subchannels[i] = grpc_client_channel_factory_create_subchannel( + exec_ctx, r->client_channel_factory, &args); } memset(&lb_policy_args, 0, sizeof(lb_policy_args)); lb_policy_args.subchannels = subchannels; @@ -159,7 +159,7 @@ static void sockaddr_maybe_finish_next_locked(grpc_exec_ctx *exec_ctx, static void sockaddr_destroy(grpc_exec_ctx *exec_ctx, grpc_resolver *gr) { sockaddr_resolver *r = (sockaddr_resolver *)gr; gpr_mu_destroy(&r->mu); - grpc_subchannel_factory_unref(exec_ctx, r->subchannel_factory); + grpc_client_channel_factory_unref(exec_ctx, r->client_channel_factory); gpr_free(r->addrs); gpr_free(r->addrs_len); gpr_free(r->lb_policy_name); @@ -337,8 +337,8 @@ static grpc_resolver *sockaddr_create( gpr_ref_init(&r->refs, 1); gpr_mu_init(&r->mu); grpc_resolver_init(&r->base, &sockaddr_resolver_vtable); - r->subchannel_factory = args->subchannel_factory; - grpc_subchannel_factory_ref(r->subchannel_factory); + r->client_channel_factory = args->client_channel_factory; + grpc_client_channel_factory_ref(r->client_channel_factory); return &r->base; } diff --git a/src/core/lib/client_config/resolvers/zookeeper_resolver.c b/src/core/lib/client_config/resolvers/zookeeper_resolver.c index 3bb0bbdf5c..4548344611 100644 --- a/src/core/lib/client_config/resolvers/zookeeper_resolver.c +++ b/src/core/lib/client_config/resolvers/zookeeper_resolver.c @@ -59,7 +59,7 @@ typedef struct { /** name to resolve */ char *name; /** subchannel factory */ - grpc_subchannel_factory *subchannel_factory; + grpc_client_channel_factory *client_channel_factory; /** load balancing policy name */ char *lb_policy_name; @@ -196,8 +196,8 @@ static void zookeeper_on_resolved(grpc_exec_ctx *exec_ctx, void *arg, memset(&args, 0, sizeof(args)); args.addr = (struct sockaddr *)(addresses->addrs[i].addr); args.addr_len = addresses->addrs[i].len; - subchannels[i] = grpc_subchannel_factory_create_subchannel( - exec_ctx, r->subchannel_factory, &args); + subchannels[i] = grpc_client_channel_factory_create_subchannel( + exec_ctx, r->client_channel_factory, &args); } lb_policy_args.subchannels = subchannels; lb_policy_args.num_subchannels = addresses->naddrs; @@ -432,7 +432,7 @@ static void zookeeper_destroy(grpc_exec_ctx *exec_ctx, grpc_resolver *gr) { if (r->resolved_config != NULL) { grpc_client_config_unref(exec_ctx, r->resolved_config); } - grpc_subchannel_factory_unref(exec_ctx, r->subchannel_factory); + grpc_client_channel_factory_unref(exec_ctx, r->client_channel_factory); gpr_free(r->name); gpr_free(r->lb_policy_name); gpr_free(r); @@ -462,8 +462,8 @@ static grpc_resolver *zookeeper_create(grpc_resolver_args *args, grpc_resolver_init(&r->base, &zookeeper_resolver_vtable); r->name = gpr_strdup(path); - r->subchannel_factory = args->subchannel_factory; - grpc_subchannel_factory_ref(r->subchannel_factory); + r->client_channel_factory = args->client_channel_factory; + grpc_client_channel_factory_ref(r->client_channel_factory); r->lb_policy_name = gpr_strdup(lb_policy_name); diff --git a/src/core/lib/client_config/subchannel_factory.c b/src/core/lib/client_config/subchannel_factory.c deleted file mode 100644 index 727a48a6c8..0000000000 --- a/src/core/lib/client_config/subchannel_factory.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * - * Copyright 2015-2016, Google Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are - * met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * * Redistributions in binary form must reproduce the above - * copyright notice, this list of conditions and the following disclaimer - * in the documentation and/or other materials provided with the - * distribution. - * * Neither the name of Google Inc. nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#include "src/core/lib/client_config/subchannel_factory.h" - -void grpc_subchannel_factory_ref(grpc_subchannel_factory* factory) { - factory->vtable->ref(factory); -} - -void grpc_subchannel_factory_unref(grpc_exec_ctx* exec_ctx, - grpc_subchannel_factory* factory) { - factory->vtable->unref(exec_ctx, factory); -} - -grpc_subchannel* grpc_subchannel_factory_create_subchannel( - grpc_exec_ctx* exec_ctx, grpc_subchannel_factory* factory, - grpc_subchannel_args* args) { - return factory->vtable->create_subchannel(exec_ctx, factory, args); -} diff --git a/src/core/lib/client_config/subchannel_factory.h b/src/core/lib/client_config/subchannel_factory.h deleted file mode 100644 index 3ba2f860fe..0000000000 --- a/src/core/lib/client_config/subchannel_factory.h +++ /dev/null @@ -1,66 +0,0 @@ -/* - * - * Copyright 2015-2016, Google Inc. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are - * met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * * Redistributions in binary form must reproduce the above - * copyright notice, this list of conditions and the following disclaimer - * in the documentation and/or other materials provided with the - * distribution. - * * Neither the name of Google Inc. nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - */ - -#ifndef GRPC_CORE_LIB_CLIENT_CONFIG_SUBCHANNEL_FACTORY_H -#define GRPC_CORE_LIB_CLIENT_CONFIG_SUBCHANNEL_FACTORY_H - -#include "src/core/lib/channel/channel_stack.h" -#include "src/core/lib/client_config/subchannel.h" - -typedef struct grpc_subchannel_factory grpc_subchannel_factory; -typedef struct grpc_subchannel_factory_vtable grpc_subchannel_factory_vtable; - -/** Constructor for new configured channels. - Creating decorators around this type is encouraged to adapt behavior. */ -struct grpc_subchannel_factory { - const grpc_subchannel_factory_vtable *vtable; -}; - -struct grpc_subchannel_factory_vtable { - void (*ref)(grpc_subchannel_factory *factory); - void (*unref)(grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *factory); - grpc_subchannel *(*create_subchannel)(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *factory, - grpc_subchannel_args *args); -}; - -void grpc_subchannel_factory_ref(grpc_subchannel_factory *factory); -void grpc_subchannel_factory_unref(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *factory); - -/** Create a new grpc_subchannel */ -grpc_subchannel *grpc_subchannel_factory_create_subchannel( - grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *factory, - grpc_subchannel_args *args); - -#endif /* GRPC_CORE_LIB_CLIENT_CONFIG_SUBCHANNEL_FACTORY_H */ diff --git a/src/core/lib/surface/channel.h b/src/core/lib/surface/channel.h index 09de0fccc9..04f26b5501 100644 --- a/src/core/lib/surface/channel.h +++ b/src/core/lib/surface/channel.h @@ -35,7 +35,7 @@ #define GRPC_CORE_LIB_SURFACE_CHANNEL_H #include "src/core/lib/channel/channel_stack.h" -#include "src/core/lib/client_config/subchannel_factory.h" +#include "src/core/lib/client_config/client_channel_factory.h" #include "src/core/lib/surface/channel_stack_type.h" grpc_channel *grpc_channel_create(grpc_exec_ctx *exec_ctx, const char *target, diff --git a/src/python/grpcio/grpc_core_dependencies.py b/src/python/grpcio/grpc_core_dependencies.py index 3c57ad71da..3468fdfbdd 100644 --- a/src/python/grpcio/grpc_core_dependencies.py +++ b/src/python/grpcio/grpc_core_dependencies.py @@ -117,6 +117,7 @@ CORE_SOURCE_FILES = [ 'src/core/lib/channel/http_client_filter.c', 'src/core/lib/channel/http_server_filter.c', 'src/core/lib/channel/subchannel_call_holder.c', + 'src/core/lib/client_config/client_channel_factory.c', 'src/core/lib/client_config/client_config.c', 'src/core/lib/client_config/connector.c', 'src/core/lib/client_config/default_initial_connect_string.c', @@ -133,7 +134,6 @@ CORE_SOURCE_FILES = [ 'src/core/lib/client_config/resolvers/dns_resolver.c', 'src/core/lib/client_config/resolvers/sockaddr_resolver.c', 'src/core/lib/client_config/subchannel.c', - 'src/core/lib/client_config/subchannel_factory.c', 'src/core/lib/client_config/subchannel_index.c', 'src/core/lib/client_config/uri_parser.c', 'src/core/lib/compression/compression_algorithm.c', diff --git a/test/core/client_config/resolvers/dns_resolver_connectivity_test.c b/test/core/client_config/resolvers/dns_resolver_connectivity_test.c index dc6a614d55..020e93d3ab 100644 --- a/test/core/client_config/resolvers/dns_resolver_connectivity_test.c +++ b/test/core/client_config/resolvers/dns_resolver_connectivity_test.c @@ -42,20 +42,27 @@ #include "src/core/lib/iomgr/timer.h" #include "test/core/util/test_config.h" -static void subchannel_factory_ref(grpc_subchannel_factory *scv) {} -static void subchannel_factory_unref(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *scv) {} -static grpc_subchannel *subchannel_factory_create_subchannel( - grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *factory, +static void client_channel_factory_ref(grpc_client_channel_factory *scv) {} +static void client_channel_factory_unref(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *scv) {} +static grpc_subchannel *client_channel_factory_create_subchannel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, grpc_subchannel_args *args) { return NULL; } -static const grpc_subchannel_factory_vtable sc_vtable = { - subchannel_factory_ref, subchannel_factory_unref, - subchannel_factory_create_subchannel}; +static grpc_channel *client_channel_factory_create_channel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, + const char *target, grpc_channel_args *args) { + GPR_UNREACHABLE_CODE(return NULL); +} + +static const grpc_client_channel_factory_vtable sc_vtable = { + client_channel_factory_ref, client_channel_factory_unref, + client_channel_factory_create_subchannel, + client_channel_factory_create_channel}; -static grpc_subchannel_factory sc_factory = {&sc_vtable}; +static grpc_client_channel_factory cc_factory = {&sc_vtable}; static gpr_mu g_mu; static bool g_fail_resolution = true; @@ -85,7 +92,7 @@ static grpc_resolver *create_resolver(const char *name) { grpc_resolver_args args; memset(&args, 0, sizeof(args)); args.uri = uri; - args.subchannel_factory = &sc_factory; + args.client_channel_factory = &cc_factory; grpc_resolver *resolver = grpc_resolver_factory_create_resolver(factory, &args); grpc_resolver_factory_unref(factory); diff --git a/test/core/client_config/resolvers/dns_resolver_test.c b/test/core/client_config/resolvers/dns_resolver_test.c index 6c7a6b27e4..2ec45e4131 100644 --- a/test/core/client_config/resolvers/dns_resolver_test.c +++ b/test/core/client_config/resolvers/dns_resolver_test.c @@ -40,20 +40,27 @@ #include "src/core/lib/client_config/resolver.h" #include "test/core/util/test_config.h" -static void subchannel_factory_ref(grpc_subchannel_factory *scv) {} -static void subchannel_factory_unref(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *scv) {} -static grpc_subchannel *subchannel_factory_create_subchannel( - grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *factory, +static void client_channel_factory_ref(grpc_client_channel_factory *scv) {} +static void client_channel_factory_unref(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *scv) {} +static grpc_subchannel *client_channel_factory_create_subchannel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, grpc_subchannel_args *args) { GPR_UNREACHABLE_CODE(return NULL); } -static const grpc_subchannel_factory_vtable sc_vtable = { - subchannel_factory_ref, subchannel_factory_unref, - subchannel_factory_create_subchannel}; +static grpc_channel *client_channel_factory_create_channel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, + const char *target, grpc_channel_args *args) { + GPR_UNREACHABLE_CODE(return NULL); +} + +static const grpc_client_channel_factory_vtable sc_vtable = { + client_channel_factory_ref, client_channel_factory_unref, + client_channel_factory_create_subchannel, + client_channel_factory_create_channel}; -static grpc_subchannel_factory sc_factory = {&sc_vtable}; +static grpc_client_channel_factory cc_factory = {&sc_vtable}; static void test_succeeds(grpc_resolver_factory *factory, const char *string) { grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT; @@ -65,7 +72,7 @@ static void test_succeeds(grpc_resolver_factory *factory, const char *string) { GPR_ASSERT(uri); memset(&args, 0, sizeof(args)); args.uri = uri; - args.subchannel_factory = &sc_factory; + args.client_channel_factory = &cc_factory; resolver = grpc_resolver_factory_create_resolver(factory, &args); GPR_ASSERT(resolver != NULL); GRPC_RESOLVER_UNREF(&exec_ctx, resolver, "test_succeeds"); diff --git a/test/core/client_config/resolvers/sockaddr_resolver_test.c b/test/core/client_config/resolvers/sockaddr_resolver_test.c index fafddfd166..220c0b8c14 100644 --- a/test/core/client_config/resolvers/sockaddr_resolver_test.c +++ b/test/core/client_config/resolvers/sockaddr_resolver_test.c @@ -40,20 +40,27 @@ #include "src/core/lib/client_config/resolver.h" #include "test/core/util/test_config.h" -static void subchannel_factory_ref(grpc_subchannel_factory *scv) {} -static void subchannel_factory_unref(grpc_exec_ctx *exec_ctx, - grpc_subchannel_factory *scv) {} -static grpc_subchannel *subchannel_factory_create_subchannel( - grpc_exec_ctx *exec_ctx, grpc_subchannel_factory *factory, +static void client_channel_factory_ref(grpc_client_channel_factory *scv) {} +static void client_channel_factory_unref(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *scv) {} +static grpc_subchannel *client_channel_factory_create_subchannel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, grpc_subchannel_args *args) { GPR_UNREACHABLE_CODE(return NULL); } -static const grpc_subchannel_factory_vtable sc_vtable = { - subchannel_factory_ref, subchannel_factory_unref, - subchannel_factory_create_subchannel}; +static grpc_channel *client_channel_factory_create_channel( + grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, + const char *target, grpc_channel_args *args) { + GPR_UNREACHABLE_CODE(return NULL); +} + +static const grpc_client_channel_factory_vtable sc_vtable = { + client_channel_factory_ref, client_channel_factory_unref, + client_channel_factory_create_subchannel, + client_channel_factory_create_channel}; -static grpc_subchannel_factory sc_factory = {&sc_vtable}; +static grpc_client_channel_factory cc_factory = {&sc_vtable}; static void test_succeeds(grpc_resolver_factory *factory, const char *string) { grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT; @@ -65,7 +72,7 @@ static void test_succeeds(grpc_resolver_factory *factory, const char *string) { GPR_ASSERT(uri); memset(&args, 0, sizeof(args)); args.uri = uri; - args.subchannel_factory = &sc_factory; + args.client_channel_factory = &cc_factory; resolver = grpc_resolver_factory_create_resolver(factory, &args); GPR_ASSERT(resolver != NULL); GRPC_RESOLVER_UNREF(&exec_ctx, resolver, "test_succeeds"); diff --git a/tools/doxygen/Doxyfile.core.internal b/tools/doxygen/Doxyfile.core.internal index bb7177f52f..3a10d1379f 100644 --- a/tools/doxygen/Doxyfile.core.internal +++ b/tools/doxygen/Doxyfile.core.internal @@ -809,6 +809,7 @@ src/core/lib/channel/context.h \ src/core/lib/channel/http_client_filter.h \ src/core/lib/channel/http_server_filter.h \ src/core/lib/channel/subchannel_call_holder.h \ +src/core/lib/client_config/client_channel_factory.h \ src/core/lib/client_config/client_config.h \ src/core/lib/client_config/connector.h \ src/core/lib/client_config/initial_connect_string.h \ @@ -824,7 +825,6 @@ src/core/lib/client_config/resolver_registry.h \ src/core/lib/client_config/resolvers/dns_resolver.h \ src/core/lib/client_config/resolvers/sockaddr_resolver.h \ src/core/lib/client_config/subchannel.h \ -src/core/lib/client_config/subchannel_factory.h \ src/core/lib/client_config/subchannel_index.h \ src/core/lib/client_config/uri_parser.h \ src/core/lib/compression/algorithm_metadata.h \ @@ -957,6 +957,7 @@ src/core/lib/channel/connected_channel.c \ src/core/lib/channel/http_client_filter.c \ src/core/lib/channel/http_server_filter.c \ src/core/lib/channel/subchannel_call_holder.c \ +src/core/lib/client_config/client_channel_factory.c \ src/core/lib/client_config/client_config.c \ src/core/lib/client_config/connector.c \ src/core/lib/client_config/default_initial_connect_string.c \ @@ -973,7 +974,6 @@ src/core/lib/client_config/resolver_registry.c \ src/core/lib/client_config/resolvers/dns_resolver.c \ src/core/lib/client_config/resolvers/sockaddr_resolver.c \ src/core/lib/client_config/subchannel.c \ -src/core/lib/client_config/subchannel_factory.c \ src/core/lib/client_config/subchannel_index.c \ src/core/lib/client_config/uri_parser.c \ src/core/lib/compression/compression_algorithm.c \ diff --git a/tools/run_tests/sources_and_headers.json b/tools/run_tests/sources_and_headers.json index d7c9839d5a..dec8b1fe37 100644 --- a/tools/run_tests/sources_and_headers.json +++ b/tools/run_tests/sources_and_headers.json @@ -4024,6 +4024,7 @@ "src/core/lib/channel/http_client_filter.h", "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.h", "src/core/lib/client_config/initial_connect_string.h", @@ -4039,7 +4040,6 @@ "src/core/lib/client_config/resolvers/dns_resolver.h", "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.h", "src/core/lib/compression/algorithm_metadata.h", @@ -4225,6 +4225,8 @@ "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.c", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.c", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.c", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.c", @@ -4256,8 +4258,6 @@ "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.c", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.c", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.c", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.c", @@ -4652,6 +4652,7 @@ "src/core/lib/channel/http_client_filter.h", "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.h", "src/core/lib/client_config/initial_connect_string.h", @@ -4667,7 +4668,6 @@ "src/core/lib/client_config/resolvers/dns_resolver.h", "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.h", "src/core/lib/compression/algorithm_metadata.h", @@ -4836,6 +4836,8 @@ "src/core/lib/channel/http_server_filter.h", "src/core/lib/channel/subchannel_call_holder.c", "src/core/lib/channel/subchannel_call_holder.h", + "src/core/lib/client_config/client_channel_factory.c", + "src/core/lib/client_config/client_channel_factory.h", "src/core/lib/client_config/client_config.c", "src/core/lib/client_config/client_config.h", "src/core/lib/client_config/connector.c", @@ -4867,8 +4869,6 @@ "src/core/lib/client_config/resolvers/sockaddr_resolver.h", "src/core/lib/client_config/subchannel.c", "src/core/lib/client_config/subchannel.h", - "src/core/lib/client_config/subchannel_factory.c", - "src/core/lib/client_config/subchannel_factory.h", "src/core/lib/client_config/subchannel_index.c", "src/core/lib/client_config/subchannel_index.h", "src/core/lib/client_config/uri_parser.c", diff --git a/vsprojects/vcxproj/grpc/grpc.vcxproj b/vsprojects/vcxproj/grpc/grpc.vcxproj index c20f8d7070..ad7f888e49 100644 --- a/vsprojects/vcxproj/grpc/grpc.vcxproj +++ b/vsprojects/vcxproj/grpc/grpc.vcxproj @@ -318,6 +318,7 @@ + @@ -333,7 +334,6 @@ - @@ -511,6 +511,8 @@ + + @@ -543,8 +545,6 @@ - - diff --git a/vsprojects/vcxproj/grpc/grpc.vcxproj.filters b/vsprojects/vcxproj/grpc/grpc.vcxproj.filters index f03b20703f..48aaa04ad3 100644 --- a/vsprojects/vcxproj/grpc/grpc.vcxproj.filters +++ b/vsprojects/vcxproj/grpc/grpc.vcxproj.filters @@ -130,6 +130,9 @@ src\core\lib\channel + + src\core\lib\client_config + src\core\lib\client_config @@ -178,9 +181,6 @@ src\core\lib\client_config - - src\core\lib\client_config - src\core\lib\client_config @@ -644,6 +644,9 @@ src\core\lib\channel + + src\core\lib\client_config + src\core\lib\client_config @@ -689,9 +692,6 @@ src\core\lib\client_config - - src\core\lib\client_config - src\core\lib\client_config diff --git a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj index e89cc8a125..77b5ef7039 100644 --- a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj +++ b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj @@ -308,6 +308,7 @@ + @@ -323,7 +324,6 @@ - @@ -483,6 +483,8 @@ + + @@ -515,8 +517,6 @@ - - diff --git a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters index c9f1ad6943..4fa1fee9fb 100644 --- a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters +++ b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters @@ -124,6 +124,9 @@ src\core\lib\channel + + src\core\lib\client_config + src\core\lib\client_config @@ -172,9 +175,6 @@ src\core\lib\client_config - - src\core\lib\client_config - src\core\lib\client_config @@ -581,6 +581,9 @@ src\core\lib\channel + + src\core\lib\client_config + src\core\lib\client_config @@ -626,9 +629,6 @@ src\core\lib\client_config - - src\core\lib\client_config - src\core\lib\client_config -- cgit v1.2.3 From 64ddf13d1454e57df825d2923046e422abeb780c Mon Sep 17 00:00:00 2001 From: David Garcia Quintas Date: Wed, 30 Mar 2016 23:53:50 -0700 Subject: added grpclb support to sockaddr resolver --- .../client_config/resolvers/sockaddr_resolver.c | 33 +++++++++++++--------- 1 file changed, 20 insertions(+), 13 deletions(-) (limited to 'src') diff --git a/src/core/lib/client_config/resolvers/sockaddr_resolver.c b/src/core/lib/client_config/resolvers/sockaddr_resolver.c index c787bd57d6..b3aaf46ee4 100644 --- a/src/core/lib/client_config/resolvers/sockaddr_resolver.c +++ b/src/core/lib/client_config/resolvers/sockaddr_resolver.c @@ -35,6 +35,7 @@ #include "src/core/lib/client_config/resolvers/sockaddr_resolver.h" +#include #include #include @@ -265,21 +266,27 @@ static grpc_resolver *sockaddr_create( memset(r, 0, sizeof(*r)); r->lb_policy_name = NULL; - if (0 != strcmp(args->uri->query, "")) { - gpr_slice query_slice; - gpr_slice_buffer query_parts; - - query_slice = - gpr_slice_new(args->uri->query, strlen(args->uri->query), do_nothing); - gpr_slice_buffer_init(&query_parts); - gpr_slice_split(query_slice, "=", &query_parts); - GPR_ASSERT(query_parts.count == 2); - if (0 == gpr_slice_str_cmp(query_parts.slices[0], "lb_policy")) { - r->lb_policy_name = gpr_dump_slice(query_parts.slices[1], GPR_DUMP_ASCII); + bool lb_enabled = false; + for (size_t i = 0; i < args->uri->num_query_parts; ++i) { + if (0 == strcmp("lb_policy", args->uri->query_parts[i])) { + GPR_ASSERT(args->uri->query_parts_values[i] != NULL); + r->lb_policy_name = gpr_strdup(args->uri->query_parts_values[i]); + } else if (0 == strcmp("lb_enabled", args->uri->query_parts[i])) { + GPR_ASSERT(args->uri->query_parts_values[i] != NULL); + lb_enabled = (strcmp("0", args->uri->query_parts_values[i]) != 0); } - gpr_slice_buffer_destroy(&query_parts); - gpr_slice_unref(query_slice); } + + if (r->lb_policy_name != NULL && strcmp("grpclb", r->lb_policy_name) == 0 && + !lb_enabled) { + /* we want grpclb but the "resolved" addresses aren't LB enabled. Bail + * out, as this is meant mostly for tests. */ + gpr_log(GPR_ERROR, + "Requested 'grpclb' LB policy but resolved addresses don't " + "support load balancing."); + abort(); + } + if (r->lb_policy_name == NULL) { r->lb_policy_name = gpr_strdup(default_lb_policy_name); } -- cgit v1.2.3 From f9a7e2876d3d8dd76292afde2de3086f3cf9e0a9 Mon Sep 17 00:00:00 2001 From: David Garcia Quintas Date: Thu, 31 Mar 2016 09:35:57 -0700 Subject: Simplified code. --- .../lib/client_config/resolvers/sockaddr_resolver.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) (limited to 'src') diff --git a/src/core/lib/client_config/resolvers/sockaddr_resolver.c b/src/core/lib/client_config/resolvers/sockaddr_resolver.c index b3aaf46ee4..9e286966e4 100644 --- a/src/core/lib/client_config/resolvers/sockaddr_resolver.c +++ b/src/core/lib/client_config/resolvers/sockaddr_resolver.c @@ -265,17 +265,13 @@ static grpc_resolver *sockaddr_create( r = gpr_malloc(sizeof(sockaddr_resolver)); memset(r, 0, sizeof(*r)); - r->lb_policy_name = NULL; - bool lb_enabled = false; - for (size_t i = 0; i < args->uri->num_query_parts; ++i) { - if (0 == strcmp("lb_policy", args->uri->query_parts[i])) { - GPR_ASSERT(args->uri->query_parts_values[i] != NULL); - r->lb_policy_name = gpr_strdup(args->uri->query_parts_values[i]); - } else if (0 == strcmp("lb_enabled", args->uri->query_parts[i])) { - GPR_ASSERT(args->uri->query_parts_values[i] != NULL); - lb_enabled = (strcmp("0", args->uri->query_parts_values[i]) != 0); - } - } + r->lb_policy_name = + gpr_strdup(grpc_uri_get_query_arg(args->uri, "lb_policy")); + const char *lb_enabled_qpart = + grpc_uri_get_query_arg(args->uri, "lb_enabled"); + /* anything other than "0" is interpreted as true */ + const bool lb_enabled = + (lb_enabled_qpart != NULL && (strcmp("0", lb_enabled_qpart) != 0)); if (r->lb_policy_name != NULL && strcmp("grpclb", r->lb_policy_name) == 0 && !lb_enabled) { -- cgit v1.2.3 From ac491d8c1f901fd44c613301d247cd1cd6b82d72 Mon Sep 17 00:00:00 2001 From: Rafael Sales Date: Wed, 2 Mar 2016 02:30:29 -0300 Subject: Raise on unexpected metadata values The existing implementation was causing segmentation fault because src/ruby/ext/grpc/rb_call.c:358 was trying to convert any value type other than Array to String. The Array type is handled in first `if`. This change will cause the Ruby code that sends non-string values to fail with a better message: `ArgumentError: Header values must be of type string or array` --- src/ruby/ext/grpc/rb_call.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/ruby/ext/grpc/rb_call.c b/src/ruby/ext/grpc/rb_call.c index dc80d18b45..f5fdbb2ffd 100644 --- a/src/ruby/ext/grpc/rb_call.c +++ b/src/ruby/ext/grpc/rb_call.c @@ -359,7 +359,7 @@ static int grpc_rb_md_ary_fill_hash_cb(VALUE key, VALUE val, VALUE md_ary_obj) { md_ary->metadata[md_ary->count].value_length = value_len; md_ary->count += 1; } - } else { + } else if (TYPE(val) == T_STRING) { value_str = RSTRING_PTR(val); value_len = RSTRING_LEN(val); if (!grpc_is_binary_header(key_str, key_len) && @@ -373,6 +373,10 @@ static int grpc_rb_md_ary_fill_hash_cb(VALUE key, VALUE val, VALUE md_ary_obj) { md_ary->metadata[md_ary->count].value = value_str; md_ary->metadata[md_ary->count].value_length = value_len; md_ary->count += 1; + } else { + rb_raise(rb_eArgError, + "Header values must be of type string or array"); + return ST_STOP; } return ST_CONTINUE; -- cgit v1.2.3 From bc846f72d6e8f60b6e395822306832f7308d3c10 Mon Sep 17 00:00:00 2001 From: Rafael Sales Date: Wed, 2 Mar 2016 08:04:26 -0300 Subject: Add spec to make sure invalid metadata values raise ArgumentError --- src/ruby/spec/generic/client_stub_spec.rb | 35 ++++++++++++++++--------------- 1 file changed, 18 insertions(+), 17 deletions(-) (limited to 'src') diff --git a/src/ruby/spec/generic/client_stub_spec.rb b/src/ruby/spec/generic/client_stub_spec.rb index 5e13c25fcf..dd8e2e9f7a 100644 --- a/src/ruby/spec/generic/client_stub_spec.rb +++ b/src/ruby/spec/generic/client_stub_spec.rb @@ -193,44 +193,45 @@ describe 'ClientStub' do describe '#client_streamer' do shared_examples 'client streaming' do before(:each) do + server_port = create_test_server + host = "localhost:#{server_port}" + @stub = GRPC::ClientStub.new(host, @cq, :this_channel_is_insecure) + @options = { k1: 'v1', k2: 'v2' } @sent_msgs = Array.new(3) { |i| 'msg_' + (i + 1).to_s } @resp = 'a_reply' end it 'should send requests to/receive a reply from a server' do - server_port = create_test_server - host = "localhost:#{server_port}" th = run_client_streamer(@sent_msgs, @resp, @pass) - stub = GRPC::ClientStub.new(host, @cq, :this_channel_is_insecure) - expect(get_response(stub)).to eq(@resp) + expect(get_response(@stub)).to eq(@resp) th.join end it 'should send metadata to the server ok' do - server_port = create_test_server - host = "localhost:#{server_port}" - th = run_client_streamer(@sent_msgs, @resp, @pass, - k1: 'v1', k2: 'v2') - stub = GRPC::ClientStub.new(host, @cq, :this_channel_is_insecure) - expect(get_response(stub)).to eq(@resp) + th = run_client_streamer(@sent_msgs, @resp, @pass, @options) + expect(get_response(@stub)).to eq(@resp) th.join end it 'should raise an error if the status is not ok' do - server_port = create_test_server - host = "localhost:#{server_port}" th = run_client_streamer(@sent_msgs, @resp, @fail) - stub = GRPC::ClientStub.new(host, @cq, :this_channel_is_insecure) - blk = proc { get_response(stub) } + blk = proc { get_response(@stub) } expect(&blk).to raise_error(GRPC::BadStatus) th.join end + + it 'should raise ArgumentError if metadata contains invalid values' do + @options.merge!(k3: 3) + expect do + get_response(@stub) + end.to raise_error(ArgumentError, + /Header values must be of type string or array/) + end end describe 'without a call operation' do def get_response(stub) - stub.client_streamer(@method, @sent_msgs, noop, noop, - k1: 'v1', k2: 'v2') + stub.client_streamer(@method, @sent_msgs, noop, noop, @options) end it_behaves_like 'client streaming' @@ -239,7 +240,7 @@ describe 'ClientStub' do describe 'via a call operation' do def get_response(stub) op = stub.client_streamer(@method, @sent_msgs, noop, noop, - return_op: true, k1: 'v1', k2: 'v2') + @options.merge(return_op: true)) expect(op).to be_a(GRPC::ActiveCall::Operation) op.execute end -- cgit v1.2.3 From a95f1b56ff5be69a3e5742d6a3f5e480cb46e275 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Thu, 31 Mar 2016 16:58:19 -0700 Subject: Increase initial connection timeout --- src/core/lib/client_config/subchannel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/core/lib/client_config/subchannel.c b/src/core/lib/client_config/subchannel.c index 47c53a16ba..b4fd770e24 100644 --- a/src/core/lib/client_config/subchannel.c +++ b/src/core/lib/client_config/subchannel.c @@ -54,7 +54,7 @@ #define STRONG_REF_MASK (~(gpr_atm)((1 << INTERNAL_REF_BITS) - 1)) #define GRPC_SUBCHANNEL_MIN_CONNECT_TIMEOUT_SECONDS 20 -#define GRPC_SUBCHANNEL_INITIAL_CONNECT_BACKOFF_SECONDS 1 +#define GRPC_SUBCHANNEL_INITIAL_CONNECT_BACKOFF_SECONDS 2 #define GRPC_SUBCHANNEL_RECONNECT_BACKOFF_MULTIPLIER 1.6 #define GRPC_SUBCHANNEL_RECONNECT_MAX_BACKOFF_SECONDS 120 #define GRPC_SUBCHANNEL_RECONNECT_JITTER 0.2 -- cgit v1.2.3 From 131b6deb5cddcc6c8ae5f9684418eee29bb43664 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Thu, 31 Mar 2016 17:05:28 -0700 Subject: Refine model used to enter transient failure for pick_first --- src/core/ext/lb_policy/pick_first/pick_first.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/core/ext/lb_policy/pick_first/pick_first.c b/src/core/ext/lb_policy/pick_first/pick_first.c index 8c556f4ab2..53c14f8f0a 100644 --- a/src/core/ext/lb_policy/pick_first/pick_first.c +++ b/src/core/ext/lb_policy/pick_first/pick_first.c @@ -315,11 +315,14 @@ static void pf_connectivity_changed(grpc_exec_ctx *exec_ctx, void *arg, &p->checking_connectivity, &p->connectivity_changed); break; case GRPC_CHANNEL_TRANSIENT_FAILURE: - grpc_connectivity_state_set(exec_ctx, &p->state_tracker, - GRPC_CHANNEL_TRANSIENT_FAILURE, - "connecting_transient_failure"); p->checking_subchannel = (p->checking_subchannel + 1) % p->num_subchannels; + if (p->checking_subchannel == 0) { + /* only trigger transient failure when we've tried all alternatives */ + grpc_connectivity_state_set(exec_ctx, &p->state_tracker, + GRPC_CHANNEL_TRANSIENT_FAILURE, + "connecting_transient_failure"); + } p->checking_connectivity = grpc_subchannel_check_connectivity( p->subchannels[p->checking_subchannel]); if (p->checking_connectivity == GRPC_CHANNEL_TRANSIENT_FAILURE) { -- cgit v1.2.3 From 399b3c42de555c21202b1f7c897d7ac78c1557d1 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 1 Apr 2016 12:24:18 -0700 Subject: Fix client_crash_test, implement idempotency, fail_fast for C++ --- include/grpc++/impl/codegen/async_stream.h | 36 +++++++++++++++-------- include/grpc++/impl/codegen/async_unary_call.h | 9 ++++-- include/grpc++/impl/codegen/call.h | 7 +++-- include/grpc++/impl/codegen/client_context.h | 13 ++++++++ include/grpc++/impl/codegen/client_unary_call.h | 3 +- include/grpc++/impl/codegen/method_handler_impl.h | 29 +++++++++++------- include/grpc++/impl/codegen/server_context.h | 2 ++ include/grpc++/impl/codegen/sync_stream.h | 24 ++++++++++----- src/cpp/client/client_context.cc | 2 ++ test/cpp/end2end/client_crash_test.cc | 2 ++ 10 files changed, 90 insertions(+), 37 deletions(-) (limited to 'src') diff --git a/include/grpc++/impl/codegen/async_stream.h b/include/grpc++/impl/codegen/async_stream.h index 78fb7274e2..a607a47106 100644 --- a/include/grpc++/impl/codegen/async_stream.h +++ b/include/grpc++/impl/codegen/async_stream.h @@ -108,7 +108,8 @@ class ClientAsyncReader GRPC_FINAL : public ClientAsyncReaderInterface { const W& request, void* tag) : context_(context), call_(channel->CreateCall(method, context, cq)) { init_ops_.set_output_tag(tag); - init_ops_.SendInitialMetadata(context->send_initial_metadata_); + init_ops_.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); // TODO(ctiller): don't assert GPR_CODEGEN_ASSERT(init_ops_.SendMessage(request).ok()); init_ops_.ClientSendClose(); @@ -173,7 +174,8 @@ class ClientAsyncWriter GRPC_FINAL : public ClientAsyncWriterInterface { finish_ops_.RecvMessage(response); init_ops_.set_output_tag(tag); - init_ops_.SendInitialMetadata(context->send_initial_metadata_); + init_ops_.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); call_.PerformOps(&init_ops_); } @@ -240,7 +242,8 @@ class ClientAsyncReaderWriter GRPC_FINAL void* tag) : context_(context), call_(channel->CreateCall(method, context, cq)) { init_ops_.set_output_tag(tag); - init_ops_.SendInitialMetadata(context->send_initial_metadata_); + init_ops_.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); call_.PerformOps(&init_ops_); } @@ -305,7 +308,8 @@ class ServerAsyncReader GRPC_FINAL : public ServerAsyncStreamingInterface, GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); meta_ops_.set_output_tag(tag); - meta_ops_.SendInitialMetadata(ctx_->initial_metadata_); + meta_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_.PerformOps(&meta_ops_); } @@ -319,7 +323,8 @@ class ServerAsyncReader GRPC_FINAL : public ServerAsyncStreamingInterface, void Finish(const W& msg, const Status& status, void* tag) { finish_ops_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - finish_ops_.SendInitialMetadata(ctx_->initial_metadata_); + finish_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } // The response is dropped if the status is not OK. @@ -336,7 +341,8 @@ class ServerAsyncReader GRPC_FINAL : public ServerAsyncStreamingInterface, GPR_CODEGEN_ASSERT(!status.ok()); finish_ops_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - finish_ops_.SendInitialMetadata(ctx_->initial_metadata_); + finish_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } finish_ops_.ServerSendStatus(ctx_->trailing_metadata_, status); @@ -366,7 +372,8 @@ class ServerAsyncWriter GRPC_FINAL : public ServerAsyncStreamingInterface, GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); meta_ops_.set_output_tag(tag); - meta_ops_.SendInitialMetadata(ctx_->initial_metadata_); + meta_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_.PerformOps(&meta_ops_); } @@ -374,7 +381,8 @@ class ServerAsyncWriter GRPC_FINAL : public ServerAsyncStreamingInterface, void Write(const W& msg, void* tag) GRPC_OVERRIDE { write_ops_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - write_ops_.SendInitialMetadata(ctx_->initial_metadata_); + write_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } // TODO(ctiller): don't assert @@ -385,7 +393,8 @@ class ServerAsyncWriter GRPC_FINAL : public ServerAsyncStreamingInterface, void Finish(const Status& status, void* tag) { finish_ops_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - finish_ops_.SendInitialMetadata(ctx_->initial_metadata_); + finish_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } finish_ops_.ServerSendStatus(ctx_->trailing_metadata_, status); @@ -415,7 +424,8 @@ class ServerAsyncReaderWriter GRPC_FINAL : public ServerAsyncStreamingInterface, GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); meta_ops_.set_output_tag(tag); - meta_ops_.SendInitialMetadata(ctx_->initial_metadata_); + meta_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_.PerformOps(&meta_ops_); } @@ -429,7 +439,8 @@ class ServerAsyncReaderWriter GRPC_FINAL : public ServerAsyncStreamingInterface, void Write(const W& msg, void* tag) GRPC_OVERRIDE { write_ops_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - write_ops_.SendInitialMetadata(ctx_->initial_metadata_); + write_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } // TODO(ctiller): don't assert @@ -440,7 +451,8 @@ class ServerAsyncReaderWriter GRPC_FINAL : public ServerAsyncStreamingInterface, void Finish(const Status& status, void* tag) { finish_ops_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - finish_ops_.SendInitialMetadata(ctx_->initial_metadata_); + finish_ops_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } finish_ops_.ServerSendStatus(ctx_->trailing_metadata_, status); diff --git a/include/grpc++/impl/codegen/async_unary_call.h b/include/grpc++/impl/codegen/async_unary_call.h index 52b34770a8..e1067d111f 100644 --- a/include/grpc++/impl/codegen/async_unary_call.h +++ b/include/grpc++/impl/codegen/async_unary_call.h @@ -67,7 +67,8 @@ class ClientAsyncResponseReader GRPC_FINAL call_(channel->CreateCall(method, context, cq)), collection_(new CallOpSetCollection) { collection_->init_buf_.SetCollection(collection_); - collection_->init_buf_.SendInitialMetadata(context->send_initial_metadata_); + collection_->init_buf_.SendInitialMetadata( + context->send_initial_metadata_, context->initial_metadata_flags()); // TODO(ctiller): don't assert GPR_CODEGEN_ASSERT(collection_->init_buf_.SendMessage(request).ok()); collection_->init_buf_.ClientSendClose(); @@ -122,7 +123,8 @@ class ServerAsyncResponseWriter GRPC_FINAL GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); meta_buf_.set_output_tag(tag); - meta_buf_.SendInitialMetadata(ctx_->initial_metadata_); + meta_buf_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_.PerformOps(&meta_buf_); } @@ -130,7 +132,8 @@ class ServerAsyncResponseWriter GRPC_FINAL void Finish(const W& msg, const Status& status, void* tag) { finish_buf_.set_output_tag(tag); if (!ctx_->sent_initial_metadata_) { - finish_buf_.SendInitialMetadata(ctx_->initial_metadata_); + finish_buf_.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } // The response is dropped if the status is not OK. diff --git a/include/grpc++/impl/codegen/call.h b/include/grpc++/impl/codegen/call.h index f76d7c23ed..aea1a6acec 100644 --- a/include/grpc++/impl/codegen/call.h +++ b/include/grpc++/impl/codegen/call.h @@ -181,8 +181,10 @@ class CallOpSendInitialMetadata { CallOpSendInitialMetadata() : send_(false) {} void SendInitialMetadata( - const std::multimap& metadata) { + const std::multimap& metadata, + uint32_t flags) { send_ = true; + flags_ = flags; initial_metadata_count_ = metadata.size(); initial_metadata_ = FillMetadataArray(metadata); } @@ -192,7 +194,7 @@ class CallOpSendInitialMetadata { if (!send_) return; grpc_op* op = &ops[(*nops)++]; op->op = GRPC_OP_SEND_INITIAL_METADATA; - op->flags = 0; + op->flags = flags_; op->reserved = NULL; op->data.send_initial_metadata.count = initial_metadata_count_; op->data.send_initial_metadata.metadata = initial_metadata_; @@ -204,6 +206,7 @@ class CallOpSendInitialMetadata { } bool send_; + uint32_t flags_; size_t initial_metadata_count_; grpc_metadata* initial_metadata_; }; diff --git a/include/grpc++/impl/codegen/client_context.h b/include/grpc++/impl/codegen/client_context.h index 5201808600..aed12767a7 100644 --- a/include/grpc++/impl/codegen/client_context.h +++ b/include/grpc++/impl/codegen/client_context.h @@ -221,6 +221,12 @@ class ClientContext { deadline_ = deadline_tp.raw_time(); } + /// EXPERIMENTAL: Set this request to be idempotent + void set_idempotent(bool idempotent) { idempotent_ = idempotent; } + + /// EXPERIMENTAL: Trigger fail-fast or not on this request + void set_fail_fast(bool fail_fast) { fail_fast_ = fail_fast; } + #ifndef GRPC_CXX0X_NO_CHRONO /// Return the deadline for the client call. std::chrono::system_clock::time_point deadline() { @@ -328,9 +334,16 @@ class ClientContext { grpc_call* call() { return call_; } void set_call(grpc_call* call, const std::shared_ptr& channel); + uint32_t initial_metadata_flags() const { + return (idempotent_ ? GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST : 0) | + (fail_fast_ ? 0 : GRPC_INITIAL_METADATA_IGNORE_CONNECTIVITY); + } + grpc::string authority() { return authority_; } bool initial_metadata_received_; + bool fail_fast_; + bool idempotent_; std::shared_ptr channel_; grpc::mutex mu_; grpc_call* call_; diff --git a/include/grpc++/impl/codegen/client_unary_call.h b/include/grpc++/impl/codegen/client_unary_call.h index 0ee5b198d2..70d65549c8 100644 --- a/include/grpc++/impl/codegen/client_unary_call.h +++ b/include/grpc++/impl/codegen/client_unary_call.h @@ -62,7 +62,8 @@ Status BlockingUnaryCall(ChannelInterface* channel, const RpcMethod& method, if (!status.ok()) { return status; } - ops.SendInitialMetadata(context->send_initial_metadata_); + ops.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); ops.RecvInitialMetadata(context); ops.RecvMessage(result); ops.ClientSendClose(); diff --git a/include/grpc++/impl/codegen/method_handler_impl.h b/include/grpc++/impl/codegen/method_handler_impl.h index 436b4d819b..21ac6c4fb5 100644 --- a/include/grpc++/impl/codegen/method_handler_impl.h +++ b/include/grpc++/impl/codegen/method_handler_impl.h @@ -44,10 +44,10 @@ namespace grpc { template class RpcMethodHandler : public MethodHandler { public: - RpcMethodHandler( - std::function func, - ServiceType* service) + RpcMethodHandler(std::function + func, + ServiceType* service) : func_(func), service_(service) {} void RunHandler(const HandlerParameter& param) GRPC_FINAL { @@ -63,7 +63,8 @@ class RpcMethodHandler : public MethodHandler { CallOpSet ops; - ops.SendInitialMetadata(param.server_context->initial_metadata_); + ops.SendInitialMetadata(param.server_context->initial_metadata_, + param.server_context->initial_metadata_flags()); if (status.ok()) { status = ops.SendMessage(rsp); } @@ -87,7 +88,8 @@ class ClientStreamingHandler : public MethodHandler { public: ClientStreamingHandler( std::function*, ResponseType*)> func, + ServerReader*, ResponseType*)> + func, ServiceType* service) : func_(func), service_(service) {} @@ -100,7 +102,8 @@ class ClientStreamingHandler : public MethodHandler { CallOpSet ops; - ops.SendInitialMetadata(param.server_context->initial_metadata_); + ops.SendInitialMetadata(param.server_context->initial_metadata_, + param.server_context->initial_metadata_flags()); if (status.ok()) { status = ops.SendMessage(rsp); } @@ -122,7 +125,8 @@ class ServerStreamingHandler : public MethodHandler { public: ServerStreamingHandler( std::function*)> func, + ServerWriter*)> + func, ServiceType* service) : func_(func), service_(service) {} @@ -138,7 +142,8 @@ class ServerStreamingHandler : public MethodHandler { CallOpSet ops; if (!param.server_context->sent_initial_metadata_) { - ops.SendInitialMetadata(param.server_context->initial_metadata_); + ops.SendInitialMetadata(param.server_context->initial_metadata_, + param.server_context->initial_metadata_flags()); } ops.ServerSendStatus(param.server_context->trailing_metadata_, status); param.call->PerformOps(&ops); @@ -170,7 +175,8 @@ class BidiStreamingHandler : public MethodHandler { CallOpSet ops; if (!param.server_context->sent_initial_metadata_) { - ops.SendInitialMetadata(param.server_context->initial_metadata_); + ops.SendInitialMetadata(param.server_context->initial_metadata_, + param.server_context->initial_metadata_flags()); } ops.ServerSendStatus(param.server_context->trailing_metadata_, status); param.call->PerformOps(&ops); @@ -191,7 +197,8 @@ class UnknownMethodHandler : public MethodHandler { static void FillOps(ServerContext* context, T* ops) { Status status(StatusCode::UNIMPLEMENTED, ""); if (!context->sent_initial_metadata_) { - ops->SendInitialMetadata(context->initial_metadata_); + ops->SendInitialMetadata(context->initial_metadata_, + context->initial_metadata_flags()); context->sent_initial_metadata_ = true; } ops->ServerSendStatus(context->trailing_metadata_, status); diff --git a/include/grpc++/impl/codegen/server_context.h b/include/grpc++/impl/codegen/server_context.h index 44d340aa45..7fa0235ca9 100644 --- a/include/grpc++/impl/codegen/server_context.h +++ b/include/grpc++/impl/codegen/server_context.h @@ -195,6 +195,8 @@ class ServerContext { void set_call(grpc_call* call); + uint32_t initial_metadata_flags() const { return 0; } + CompletionOp* completion_op_; bool has_notify_when_done_tag_; void* async_notify_when_done_tag_; diff --git a/include/grpc++/impl/codegen/sync_stream.h b/include/grpc++/impl/codegen/sync_stream.h index d0ad05169f..9100ce09a2 100644 --- a/include/grpc++/impl/codegen/sync_stream.h +++ b/include/grpc++/impl/codegen/sync_stream.h @@ -125,7 +125,8 @@ class ClientReader GRPC_FINAL : public ClientReaderInterface { CallOpSet ops; - ops.SendInitialMetadata(context->send_initial_metadata_); + ops.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); // TODO(ctiller): don't assert GPR_CODEGEN_ASSERT(ops.SendMessage(request).ok()); ops.ClientSendClose(); @@ -190,7 +191,8 @@ class ClientWriter : public ClientWriterInterface { finish_ops_.RecvMessage(response); CallOpSet ops; - ops.SendInitialMetadata(context->send_initial_metadata_); + ops.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); call_.PerformOps(&ops); cq_.Pluck(&ops); } @@ -268,7 +270,8 @@ class ClientReaderWriter GRPC_FINAL : public ClientReaderWriterInterface { ClientContext* context) : context_(context), call_(channel->CreateCall(method, context, &cq_)) { CallOpSet ops; - ops.SendInitialMetadata(context->send_initial_metadata_); + ops.SendInitialMetadata(context->send_initial_metadata_, + context->initial_metadata_flags()); call_.PerformOps(&ops); cq_.Pluck(&ops); } @@ -334,7 +337,8 @@ class ServerReader GRPC_FINAL : public ReaderInterface { GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); CallOpSet ops; - ops.SendInitialMetadata(ctx_->initial_metadata_); + ops.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_->PerformOps(&ops); call_->cq()->Pluck(&ops); @@ -361,7 +365,8 @@ class ServerWriter GRPC_FINAL : public WriterInterface { GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); CallOpSet ops; - ops.SendInitialMetadata(ctx_->initial_metadata_); + ops.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_->PerformOps(&ops); call_->cq()->Pluck(&ops); @@ -374,7 +379,8 @@ class ServerWriter GRPC_FINAL : public WriterInterface { return false; } if (!ctx_->sent_initial_metadata_) { - ops.SendInitialMetadata(ctx_->initial_metadata_); + ops.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } call_->PerformOps(&ops); @@ -397,7 +403,8 @@ class ServerReaderWriter GRPC_FINAL : public WriterInterface, GPR_CODEGEN_ASSERT(!ctx_->sent_initial_metadata_); CallOpSet ops; - ops.SendInitialMetadata(ctx_->initial_metadata_); + ops.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; call_->PerformOps(&ops); call_->cq()->Pluck(&ops); @@ -417,7 +424,8 @@ class ServerReaderWriter GRPC_FINAL : public WriterInterface, return false; } if (!ctx_->sent_initial_metadata_) { - ops.SendInitialMetadata(ctx_->initial_metadata_); + ops.SendInitialMetadata(ctx_->initial_metadata_, + ctx_->initial_metadata_flags()); ctx_->sent_initial_metadata_ = true; } call_->PerformOps(&ops); diff --git a/src/cpp/client/client_context.cc b/src/cpp/client/client_context.cc index bf6423128a..c277d7ebe8 100644 --- a/src/cpp/client/client_context.cc +++ b/src/cpp/client/client_context.cc @@ -60,6 +60,8 @@ static ClientContext::GlobalCallbacks* g_client_callbacks = ClientContext::ClientContext() : initial_metadata_received_(false), + fail_fast_(true), + idempotent_(false), call_(nullptr), call_canceled_(false), deadline_(gpr_inf_future(GPR_CLOCK_REALTIME)), diff --git a/test/cpp/end2end/client_crash_test.cc b/test/cpp/end2end/client_crash_test.cc index c01f40dbc2..30b04fb9b9 100644 --- a/test/cpp/end2end/client_crash_test.cc +++ b/test/cpp/end2end/client_crash_test.cc @@ -88,6 +88,7 @@ TEST_F(CrashTest, KillBeforeWrite) { EchoRequest request; EchoResponse response; ClientContext context; + context.set_fail_fast(false); auto stream = stub->BidiStream(&context); @@ -113,6 +114,7 @@ TEST_F(CrashTest, KillAfterWrite) { EchoRequest request; EchoResponse response; ClientContext context; + context.set_fail_fast(false); auto stream = stub->BidiStream(&context); -- cgit v1.2.3 From 0b868c7c0713c93f2aa76460af1d03879256ba4d Mon Sep 17 00:00:00 2001 From: David Garcia Quintas Date: Fri, 1 Apr 2016 14:28:22 -0700 Subject: added grpc_client_channel_type for the creation of client channels --- .../transport/chttp2/client/insecure/channel_create.c | 7 ++++--- .../chttp2/client/secure/secure_channel_create.c | 7 ++++--- src/core/lib/client_config/client_channel_factory.c | 6 ++++-- src/core/lib/client_config/client_channel_factory.h | 16 ++++++++++++---- .../resolvers/dns_resolver_connectivity_test.c | 3 ++- test/core/client_config/resolvers/dns_resolver_test.c | 3 ++- .../client_config/resolvers/sockaddr_resolver_test.c | 3 ++- 7 files changed, 30 insertions(+), 15 deletions(-) (limited to 'src') diff --git a/src/core/ext/transport/chttp2/client/insecure/channel_create.c b/src/core/ext/transport/chttp2/client/insecure/channel_create.c index 024f4bc363..6083e0d22e 100644 --- a/src/core/ext/transport/chttp2/client/insecure/channel_create.c +++ b/src/core/ext/transport/chttp2/client/insecure/channel_create.c @@ -181,7 +181,8 @@ static grpc_subchannel *client_channel_factory_create_subchannel( static grpc_channel *client_channel_factory_create_channel( grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, - const char *target, grpc_channel_args *args) { + const char *target, grpc_client_channel_type type, + grpc_channel_args *args) { client_channel_factory *f = (client_channel_factory *)cc_factory; grpc_channel_args *final_args = grpc_channel_args_merge(args, f->merge_args); grpc_channel *channel = grpc_channel_create(exec_ctx, target, final_args, @@ -225,8 +226,8 @@ grpc_channel *grpc_insecure_channel_create(const char *target, gpr_ref_init(&f->refs, 1); f->merge_args = grpc_channel_args_copy(args); - grpc_channel *channel = - client_channel_factory_create_channel(&exec_ctx, &f->base, target, NULL); + grpc_channel *channel = client_channel_factory_create_channel( + &exec_ctx, &f->base, target, GRPC_CLIENT_CHANNEL_TYPE_REGULAR, NULL); if (channel != NULL) { f->master = channel; GRPC_CHANNEL_INTERNAL_REF(f->master, "grpc_insecure_channel_create"); diff --git a/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c b/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c index 210d9e4414..5d30805639 100644 --- a/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c +++ b/src/core/ext/transport/chttp2/client/secure/secure_channel_create.c @@ -242,7 +242,8 @@ static grpc_subchannel *client_channel_factory_create_subchannel( static grpc_channel *client_channel_factory_create_channel( grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, - const char *target, grpc_channel_args *args) { + const char *target, grpc_client_channel_type type, + grpc_channel_args *args) { client_channel_factory *f = (client_channel_factory *)cc_factory; grpc_channel_args *final_args = grpc_channel_args_merge(args, f->merge_args); @@ -328,8 +329,8 @@ grpc_channel *grpc_secure_channel_create(grpc_channel_credentials *creds, "grpc_secure_channel_create"); f->security_connector = security_connector; - grpc_channel *channel = - client_channel_factory_create_channel(&exec_ctx, &f->base, target, NULL); + grpc_channel *channel = client_channel_factory_create_channel( + &exec_ctx, &f->base, target, GRPC_CLIENT_CHANNEL_TYPE_REGULAR, NULL); if (channel != NULL) { f->master = channel; GRPC_CHANNEL_INTERNAL_REF(f->master, "grpc_secure_channel_create"); diff --git a/src/core/lib/client_config/client_channel_factory.c b/src/core/lib/client_config/client_channel_factory.c index 795776dcdd..d27b38d9f2 100644 --- a/src/core/lib/client_config/client_channel_factory.c +++ b/src/core/lib/client_config/client_channel_factory.c @@ -50,6 +50,8 @@ grpc_subchannel* grpc_client_channel_factory_create_subchannel( grpc_channel* grpc_client_channel_factory_create_channel( grpc_exec_ctx* exec_ctx, grpc_client_channel_factory* factory, - const char* target, grpc_channel_args* args) { - return factory->vtable->create_channel(exec_ctx, factory, target, args); + const char* target, grpc_client_channel_type type, + grpc_channel_args* args) { + return factory->vtable->create_client_channel(exec_ctx, factory, target, type, + args); } diff --git a/src/core/lib/client_config/client_channel_factory.h b/src/core/lib/client_config/client_channel_factory.h index 4975eecb1a..83d743ddc3 100644 --- a/src/core/lib/client_config/client_channel_factory.h +++ b/src/core/lib/client_config/client_channel_factory.h @@ -44,6 +44,12 @@ typedef struct grpc_client_channel_factory grpc_client_channel_factory; typedef struct grpc_client_channel_factory_vtable grpc_client_channel_factory_vtable; +typedef enum { + GRPC_CLIENT_CHANNEL_TYPE_REGULAR, /** for the user-level regular calls */ + GRPC_CLIENT_CHANNEL_TYPE_LOAD_BALANCING, /** for communication with a load + balancing service */ +} grpc_client_channel_type; + /** Constructor for new configured channels. Creating decorators around this type is encouraged to adapt behavior. */ struct grpc_client_channel_factory { @@ -56,9 +62,11 @@ struct grpc_client_channel_factory_vtable { grpc_subchannel *(*create_subchannel)(grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, grpc_subchannel_args *args); - grpc_channel *(*create_channel)(grpc_exec_ctx *exec_ctx, - grpc_client_channel_factory *factory, - const char *target, grpc_channel_args *args); + grpc_channel *(*create_client_channel)(grpc_exec_ctx *exec_ctx, + grpc_client_channel_factory *factory, + const char *target, + grpc_client_channel_type type, + grpc_channel_args *args); }; void grpc_client_channel_factory_ref(grpc_client_channel_factory *factory); @@ -73,6 +81,6 @@ grpc_subchannel *grpc_client_channel_factory_create_subchannel( /** Create a new grpc_channel */ grpc_channel *grpc_client_channel_factory_create_channel( grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *factory, - const char *target, grpc_channel_args *args); + const char *target, grpc_client_channel_type type, grpc_channel_args *args); #endif /* GRPC_CORE_LIB_CLIENT_CONFIG_CLIENT_CHANNEL_FACTORY_H */ diff --git a/test/core/client_config/resolvers/dns_resolver_connectivity_test.c b/test/core/client_config/resolvers/dns_resolver_connectivity_test.c index 1fd2d3d5ef..26c4e1d4ff 100644 --- a/test/core/client_config/resolvers/dns_resolver_connectivity_test.c +++ b/test/core/client_config/resolvers/dns_resolver_connectivity_test.c @@ -53,7 +53,8 @@ static grpc_subchannel *client_channel_factory_create_subchannel( static grpc_channel *client_channel_factory_create_channel( grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, - const char *target, grpc_channel_args *args) { + const char *target, grpc_client_channel_type type, + grpc_channel_args *args) { GPR_UNREACHABLE_CODE(return NULL); } diff --git a/test/core/client_config/resolvers/dns_resolver_test.c b/test/core/client_config/resolvers/dns_resolver_test.c index ce2da800bd..409d980ec1 100644 --- a/test/core/client_config/resolvers/dns_resolver_test.c +++ b/test/core/client_config/resolvers/dns_resolver_test.c @@ -51,7 +51,8 @@ static grpc_subchannel *client_channel_factory_create_subchannel( static grpc_channel *client_channel_factory_create_channel( grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, - const char *target, grpc_channel_args *args) { + const char *target, grpc_client_channel_type type, + grpc_channel_args *args) { GPR_UNREACHABLE_CODE(return NULL); } diff --git a/test/core/client_config/resolvers/sockaddr_resolver_test.c b/test/core/client_config/resolvers/sockaddr_resolver_test.c index 1e57d747f7..4eaf8ea2a4 100644 --- a/test/core/client_config/resolvers/sockaddr_resolver_test.c +++ b/test/core/client_config/resolvers/sockaddr_resolver_test.c @@ -51,7 +51,8 @@ static grpc_subchannel *client_channel_factory_create_subchannel( static grpc_channel *client_channel_factory_create_channel( grpc_exec_ctx *exec_ctx, grpc_client_channel_factory *cc_factory, - const char *target, grpc_channel_args *args) { + const char *target, grpc_client_channel_type type, + grpc_channel_args *args) { GPR_UNREACHABLE_CODE(return NULL); } -- cgit v1.2.3 From 10a002d7e3809c98b6a8068a3bf103e00dec88ea Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 14 Mar 2016 15:22:19 -0700 Subject: generate serverside base class for C# --- src/compiler/csharp_generator.cc | 43 +++++++++++++++++++++++++++++++++++++--- 1 file changed, 40 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index 5a8746df8d..e46903d194 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -81,6 +81,10 @@ std::string GetServerInterfaceName(const ServiceDescriptor* service) { return "I" + service->name(); } +std::string GetServerClassName(const ServiceDescriptor* service) { + return service->name() + "Base"; +} + std::string GetCSharpMethodType(MethodType method_type) { switch (method_type) { case METHODTYPE_NO_STREAMING: @@ -290,6 +294,8 @@ void GenerateClientInterface(Printer* out, const ServiceDescriptor *service) { void GenerateServerInterface(Printer* out, const ServiceDescriptor *service) { out->Print("// server-side interface\n"); + out->Print("[System.Obsolete(\"Service implementations should inherit" + " from the generated abstract base class instead.\")]\n"); out->Print("public interface $name$\n", "name", GetServerInterfaceName(service)); out->Print("{\n"); @@ -309,6 +315,33 @@ void GenerateServerInterface(Printer* out, const ServiceDescriptor *service) { out->Print("\n"); } +void GenerateServerClass(Printer* out, const ServiceDescriptor *service) { + out->Print("// server-side abstract class\n"); + out->Print("public abstract class $name$\n", "name", + GetServerClassName(service)); + out->Print("{\n"); + out->Indent(); + for (int i = 0; i < service->method_count(); i++) { + const MethodDescriptor *method = service->method(i); + out->Print( + "public virtual $returntype$ $methodname$($request$$response_stream_maybe$, " + "ServerCallContext context)\n", + "methodname", method->name(), "returntype", + GetMethodReturnTypeServer(method), "request", + GetMethodRequestParamServer(method), "response_stream_maybe", + GetMethodResponseStreamMaybe(method)); + out->Print("{\n"); + out->Indent(); + out->Print("throw new RpcException(" + "new Status(StatusCode.Unimplemented, \"\"));\n"); + out->Outdent(); + out->Print("}\n\n"); + } + out->Outdent(); + out->Print("}\n"); + out->Print("\n"); +} + void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Print("// client stub\n"); out->Print( @@ -427,12 +460,14 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Print("\n"); } -void GenerateBindServiceMethod(Printer* out, const ServiceDescriptor *service) { +void GenerateBindServiceMethod(Printer* out, const ServiceDescriptor *service, + bool use_server_class) { out->Print( "// creates service definition that can be registered with a server\n"); out->Print( "public static ServerServiceDefinition BindService($interface$ serviceImpl)\n", - "interface", GetServerInterfaceName(service)); + "interface", use_server_class ? GetServerClassName(service) : + GetServerInterfaceName(service)); out->Print("{\n"); out->Indent(); @@ -489,8 +524,10 @@ void GenerateService(Printer* out, const ServiceDescriptor *service) { GenerateServiceDescriptorProperty(out, service); GenerateClientInterface(out, service); GenerateServerInterface(out, service); + GenerateServerClass(out, service); GenerateClientStub(out, service); - GenerateBindServiceMethod(out, service); + GenerateBindServiceMethod(out, service, false); + GenerateBindServiceMethod(out, service, true); GenerateNewStubMethods(out, service); out->Outdent(); -- cgit v1.2.3 From d39426d5053dc1a94910721dc0788d2ecf2cbf06 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 14 Mar 2016 16:07:52 -0700 Subject: change C# service implementations to inherit from a generated base class --- src/csharp/Grpc.Examples/MathServiceImpl.cs | 10 +++++----- src/csharp/Grpc.HealthCheck/HealthServiceImpl.cs | 4 ++-- src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs | 6 +++--- src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs | 14 +++++++------- src/csharp/Grpc.IntegrationTesting/WorkerServiceImpl.cs | 10 +++++----- 5 files changed, 22 insertions(+), 22 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Examples/MathServiceImpl.cs b/src/csharp/Grpc.Examples/MathServiceImpl.cs index 71dc655e46..95c9cc3028 100644 --- a/src/csharp/Grpc.Examples/MathServiceImpl.cs +++ b/src/csharp/Grpc.Examples/MathServiceImpl.cs @@ -43,14 +43,14 @@ namespace Math /// /// Implementation of MathService server /// - public class MathServiceImpl : Math.IMath + public class MathServiceImpl : Math.MathBase { - public Task Div(DivArgs request, ServerCallContext context) + public override Task Div(DivArgs request, ServerCallContext context) { return Task.FromResult(DivInternal(request)); } - public async Task Fib(FibArgs request, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task Fib(FibArgs request, IServerStreamWriter responseStream, ServerCallContext context) { if (request.Limit <= 0) { @@ -72,7 +72,7 @@ namespace Math } } - public async Task Sum(IAsyncStreamReader requestStream, ServerCallContext context) + public override async Task Sum(IAsyncStreamReader requestStream, ServerCallContext context) { long sum = 0; await requestStream.ForEachAsync(async num => @@ -82,7 +82,7 @@ namespace Math return new Num { Num_ = sum }; } - public async Task DivMany(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task DivMany(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) { await requestStream.ForEachAsync(async divArgs => await responseStream.WriteAsync(DivInternal(divArgs))); } diff --git a/src/csharp/Grpc.HealthCheck/HealthServiceImpl.cs b/src/csharp/Grpc.HealthCheck/HealthServiceImpl.cs index a6e82aa0d4..d0406ece00 100644 --- a/src/csharp/Grpc.HealthCheck/HealthServiceImpl.cs +++ b/src/csharp/Grpc.HealthCheck/HealthServiceImpl.cs @@ -51,7 +51,7 @@ namespace Grpc.HealthCheck /// server.AddServiceDefinition(Grpc.Health.V1.Health.BindService(serviceImpl)); /// /// - public class HealthServiceImpl : Grpc.Health.V1.Health.IHealth + public class HealthServiceImpl : Grpc.Health.V1.Health.HealthBase { private readonly object myLock = new object(); private readonly Dictionary statusMap = @@ -99,7 +99,7 @@ namespace Grpc.HealthCheck /// The check request. /// The call context. /// The asynchronous response. - public Task Check(HealthCheckRequest request, ServerCallContext context) + public override Task Check(HealthCheckRequest request, ServerCallContext context) { lock (myLock) { diff --git a/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs b/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs index 7e7bc713a0..9b5db1feb6 100644 --- a/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs +++ b/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs @@ -44,19 +44,19 @@ namespace Grpc.Testing /// /// Implementation of BenchmarkService server /// - public class BenchmarkServiceImpl : BenchmarkService.IBenchmarkService + public class BenchmarkServiceImpl : BenchmarkService.BenchmarkServiceBase { public BenchmarkServiceImpl() { } - public Task UnaryCall(SimpleRequest request, ServerCallContext context) + public override Task UnaryCall(SimpleRequest request, ServerCallContext context) { var response = new SimpleResponse { Payload = CreateZerosPayload(request.ResponseSize) }; return Task.FromResult(response); } - public async Task StreamingCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task StreamingCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) { await requestStream.ForEachAsync(async request => { diff --git a/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs b/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs index 5a1b4cf319..7d505e8a9f 100644 --- a/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs +++ b/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs @@ -45,14 +45,14 @@ namespace Grpc.Testing /// /// Implementation of TestService server /// - public class TestServiceImpl : TestService.ITestService + public class TestServiceImpl : TestService.TestServiceBase { - public Task EmptyCall(Empty request, ServerCallContext context) + public override Task EmptyCall(Empty request, ServerCallContext context) { return Task.FromResult(new Empty()); } - public async Task UnaryCall(SimpleRequest request, ServerCallContext context) + public override async Task UnaryCall(SimpleRequest request, ServerCallContext context) { await EnsureEchoMetadataAsync(context); EnsureEchoStatus(request.ResponseStatus, context); @@ -61,7 +61,7 @@ namespace Grpc.Testing return response; } - public async Task StreamingOutputCall(StreamingOutputCallRequest request, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task StreamingOutputCall(StreamingOutputCallRequest request, IServerStreamWriter responseStream, ServerCallContext context) { await EnsureEchoMetadataAsync(context); EnsureEchoStatus(request.ResponseStatus, context); @@ -73,7 +73,7 @@ namespace Grpc.Testing } } - public async Task StreamingInputCall(IAsyncStreamReader requestStream, ServerCallContext context) + public override async Task StreamingInputCall(IAsyncStreamReader requestStream, ServerCallContext context) { await EnsureEchoMetadataAsync(context); @@ -85,7 +85,7 @@ namespace Grpc.Testing return new StreamingInputCallResponse { AggregatedPayloadSize = sum }; } - public async Task FullDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task FullDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) { await EnsureEchoMetadataAsync(context); @@ -100,7 +100,7 @@ namespace Grpc.Testing }); } - public async Task HalfDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task HalfDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) { throw new NotImplementedException(); } diff --git a/src/csharp/Grpc.IntegrationTesting/WorkerServiceImpl.cs b/src/csharp/Grpc.IntegrationTesting/WorkerServiceImpl.cs index e5ad0caa03..80dad9fdd9 100644 --- a/src/csharp/Grpc.IntegrationTesting/WorkerServiceImpl.cs +++ b/src/csharp/Grpc.IntegrationTesting/WorkerServiceImpl.cs @@ -45,7 +45,7 @@ namespace Grpc.Testing /// /// Implementation of WorkerService server /// - public class WorkerServiceImpl : WorkerService.IWorkerService + public class WorkerServiceImpl : WorkerService.WorkerServiceBase { readonly Action stopRequestHandler; @@ -54,7 +54,7 @@ namespace Grpc.Testing this.stopRequestHandler = GrpcPreconditions.CheckNotNull(stopRequestHandler); } - public async Task RunServer(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task RunServer(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) { GrpcPreconditions.CheckState(await requestStream.MoveNext()); var serverConfig = requestStream.Current.Setup; @@ -78,7 +78,7 @@ namespace Grpc.Testing await runner.StopAsync(); } - public async Task RunClient(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + public override async Task RunClient(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) { GrpcPreconditions.CheckState(await requestStream.MoveNext()); var clientConfig = requestStream.Current.Setup; @@ -100,12 +100,12 @@ namespace Grpc.Testing await runner.StopAsync(); } - public Task CoreCount(CoreRequest request, ServerCallContext context) + public override Task CoreCount(CoreRequest request, ServerCallContext context) { return Task.FromResult(new CoreResponse { Cores = Environment.ProcessorCount }); } - public Task QuitWorker(Void request, ServerCallContext context) + public override Task QuitWorker(Void request, ServerCallContext context) { stopRequestHandler(); return Task.FromResult(new Void()); -- cgit v1.2.3 From eeef5edd7aa251d1ce6804fdc4997bdf12ad907a Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 14 Mar 2016 16:08:39 -0700 Subject: regenerate protos --- src/csharp/Grpc.Examples/MathGrpc.cs | 36 +++++++++ src/csharp/Grpc.HealthCheck/HealthGrpc.cs | 18 +++++ src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs | 60 +++++++++++++++ src/csharp/Grpc.IntegrationTesting/TestGrpc.cs | 90 ++++++++++++++++++++++ 4 files changed, 204 insertions(+) (limited to 'src') diff --git a/src/csharp/Grpc.Examples/MathGrpc.cs b/src/csharp/Grpc.Examples/MathGrpc.cs index a6e878d0f4..ba237ddfd2 100644 --- a/src/csharp/Grpc.Examples/MathGrpc.cs +++ b/src/csharp/Grpc.Examples/MathGrpc.cs @@ -67,6 +67,7 @@ namespace Math { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface IMath { Task Div(global::Math.DivArgs request, ServerCallContext context); @@ -75,6 +76,31 @@ namespace Math { Task Sum(IAsyncStreamReader requestStream, ServerCallContext context); } + // server-side abstract class + public abstract class MathBase + { + public virtual Task Div(global::Math.DivArgs request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task DivMany(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task Fib(global::Math.FibArgs request, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task Sum(IAsyncStreamReader requestStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class MathClient : ClientBase, IMathClient { @@ -143,6 +169,16 @@ namespace Math { .AddMethod(__Method_Sum, serviceImpl.Sum).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(MathBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_Div, serviceImpl.Div) + .AddMethod(__Method_DivMany, serviceImpl.DivMany) + .AddMethod(__Method_Fib, serviceImpl.Fib) + .AddMethod(__Method_Sum, serviceImpl.Sum).Build(); + } + // creates a new client public static MathClient NewClient(Channel channel) { diff --git a/src/csharp/Grpc.HealthCheck/HealthGrpc.cs b/src/csharp/Grpc.HealthCheck/HealthGrpc.cs index 68320eb5c2..fffdf03be4 100644 --- a/src/csharp/Grpc.HealthCheck/HealthGrpc.cs +++ b/src/csharp/Grpc.HealthCheck/HealthGrpc.cs @@ -38,11 +38,22 @@ namespace Grpc.Health.V1 { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface IHealth { Task Check(global::Grpc.Health.V1.HealthCheckRequest request, ServerCallContext context); } + // server-side abstract class + public abstract class HealthBase + { + public virtual Task Check(global::Grpc.Health.V1.HealthCheckRequest request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class HealthClient : ClientBase, IHealthClient { @@ -78,6 +89,13 @@ namespace Grpc.Health.V1 { .AddMethod(__Method_Check, serviceImpl.Check).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(HealthBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_Check, serviceImpl.Check).Build(); + } + // creates a new client public static HealthClient NewClient(Channel channel) { diff --git a/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs b/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs index 996439afbf..beffa2298d 100644 --- a/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs +++ b/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs @@ -47,12 +47,28 @@ namespace Grpc.Testing { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface IBenchmarkService { Task UnaryCall(global::Grpc.Testing.SimpleRequest request, ServerCallContext context); Task StreamingCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context); } + // server-side abstract class + public abstract class BenchmarkServiceBase + { + public virtual Task UnaryCall(global::Grpc.Testing.SimpleRequest request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task StreamingCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class BenchmarkServiceClient : ClientBase, IBenchmarkServiceClient { @@ -99,6 +115,14 @@ namespace Grpc.Testing { .AddMethod(__Method_StreamingCall, serviceImpl.StreamingCall).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(BenchmarkServiceBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_UnaryCall, serviceImpl.UnaryCall) + .AddMethod(__Method_StreamingCall, serviceImpl.StreamingCall).Build(); + } + // creates a new client public static BenchmarkServiceClient NewClient(Channel channel) { @@ -170,6 +194,7 @@ namespace Grpc.Testing { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface IWorkerService { Task RunServer(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context); @@ -178,6 +203,31 @@ namespace Grpc.Testing { Task QuitWorker(global::Grpc.Testing.Void request, ServerCallContext context); } + // server-side abstract class + public abstract class WorkerServiceBase + { + public virtual Task RunServer(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task RunClient(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task CoreCount(global::Grpc.Testing.CoreRequest request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task QuitWorker(global::Grpc.Testing.Void request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class WorkerServiceClient : ClientBase, IWorkerServiceClient { @@ -256,6 +306,16 @@ namespace Grpc.Testing { .AddMethod(__Method_QuitWorker, serviceImpl.QuitWorker).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(WorkerServiceBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_RunServer, serviceImpl.RunServer) + .AddMethod(__Method_RunClient, serviceImpl.RunClient) + .AddMethod(__Method_CoreCount, serviceImpl.CoreCount) + .AddMethod(__Method_QuitWorker, serviceImpl.QuitWorker).Build(); + } + // creates a new client public static WorkerServiceClient NewClient(Channel channel) { diff --git a/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs b/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs index 2c469080d9..6b3a7cbf2d 100644 --- a/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs +++ b/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs @@ -90,6 +90,7 @@ namespace Grpc.Testing { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface ITestService { Task EmptyCall(global::Grpc.Testing.Empty request, ServerCallContext context); @@ -100,6 +101,41 @@ namespace Grpc.Testing { Task HalfDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context); } + // server-side abstract class + public abstract class TestServiceBase + { + public virtual Task EmptyCall(global::Grpc.Testing.Empty request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task UnaryCall(global::Grpc.Testing.SimpleRequest request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task StreamingInputCall(IAsyncStreamReader requestStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task FullDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task HalfDuplexCall(IAsyncStreamReader requestStream, IServerStreamWriter responseStream, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class TestServiceClient : ClientBase, ITestServiceClient { @@ -200,6 +236,18 @@ namespace Grpc.Testing { .AddMethod(__Method_HalfDuplexCall, serviceImpl.HalfDuplexCall).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(TestServiceBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_EmptyCall, serviceImpl.EmptyCall) + .AddMethod(__Method_UnaryCall, serviceImpl.UnaryCall) + .AddMethod(__Method_StreamingOutputCall, serviceImpl.StreamingOutputCall) + .AddMethod(__Method_StreamingInputCall, serviceImpl.StreamingInputCall) + .AddMethod(__Method_FullDuplexCall, serviceImpl.FullDuplexCall) + .AddMethod(__Method_HalfDuplexCall, serviceImpl.HalfDuplexCall).Build(); + } + // creates a new client public static TestServiceClient NewClient(Channel channel) { @@ -236,11 +284,22 @@ namespace Grpc.Testing { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface IUnimplementedService { Task UnimplementedCall(global::Grpc.Testing.Empty request, ServerCallContext context); } + // server-side abstract class + public abstract class UnimplementedServiceBase + { + public virtual Task UnimplementedCall(global::Grpc.Testing.Empty request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class UnimplementedServiceClient : ClientBase, IUnimplementedServiceClient { @@ -276,6 +335,13 @@ namespace Grpc.Testing { .AddMethod(__Method_UnimplementedCall, serviceImpl.UnimplementedCall).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(UnimplementedServiceBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_UnimplementedCall, serviceImpl.UnimplementedCall).Build(); + } + // creates a new client public static UnimplementedServiceClient NewClient(Channel channel) { @@ -324,12 +390,28 @@ namespace Grpc.Testing { } // server-side interface + [System.Obsolete("Service implementations should inherit from the generated abstract base class instead.")] public interface IReconnectService { Task Start(global::Grpc.Testing.Empty request, ServerCallContext context); Task Stop(global::Grpc.Testing.Empty request, ServerCallContext context); } + // server-side abstract class + public abstract class ReconnectServiceBase + { + public virtual Task Start(global::Grpc.Testing.Empty request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + public virtual Task Stop(global::Grpc.Testing.Empty request, ServerCallContext context) + { + throw new RpcException(new Status(StatusCode.Unimplemented, "")); + } + + } + // client stub public class ReconnectServiceClient : ClientBase, IReconnectServiceClient { @@ -386,6 +468,14 @@ namespace Grpc.Testing { .AddMethod(__Method_Stop, serviceImpl.Stop).Build(); } + // creates service definition that can be registered with a server + public static ServerServiceDefinition BindService(ReconnectServiceBase serviceImpl) + { + return ServerServiceDefinition.CreateBuilder(__ServiceName) + .AddMethod(__Method_Start, serviceImpl.Start) + .AddMethod(__Method_Stop, serviceImpl.Stop).Build(); + } + // creates a new client public static ReconnectServiceClient NewClient(Channel channel) { -- cgit v1.2.3 From c86a58809fffcabcbe799eac5ad030469607178f Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Fri, 18 Mar 2016 14:12:53 -0700 Subject: fix copyrights --- src/csharp/Grpc.Examples/MathServiceImpl.cs | 2 +- src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs | 2 +- src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Examples/MathServiceImpl.cs b/src/csharp/Grpc.Examples/MathServiceImpl.cs index 95c9cc3028..79c56e57a8 100644 --- a/src/csharp/Grpc.Examples/MathServiceImpl.cs +++ b/src/csharp/Grpc.Examples/MathServiceImpl.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs b/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs index 9b5db1feb6..07f2703d4a 100644 --- a/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs +++ b/src/csharp/Grpc.IntegrationTesting/BenchmarkServiceImpl.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs b/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs index 7d505e8a9f..354318e80e 100644 --- a/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs +++ b/src/csharp/Grpc.IntegrationTesting/TestServiceImpl.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without -- cgit v1.2.3 From 8cd4ae9912c925725eed22a9c906c6cfcc8f7900 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 21 Mar 2016 18:46:32 -0700 Subject: generate client-side base class --- src/compiler/csharp_generator.cc | 145 +++++++++++++++++++++++++-------------- 1 file changed, 95 insertions(+), 50 deletions(-) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index e46903d194..fb11d98fe4 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -73,6 +73,10 @@ std::string GetClientInterfaceName(const ServiceDescriptor* service) { return "I" + service->name() + "Client"; } +std::string GetClientBaseClassName(const ServiceDescriptor* service) { + return service->name() + "ClientBase"; +} + std::string GetClientClassName(const ServiceDescriptor* service) { return service->name() + "Client"; } @@ -112,10 +116,14 @@ std::string GetMethodFieldName(const MethodDescriptor *method) { return "__Method_" + method->name(); } -std::string GetMethodRequestParamMaybe(const MethodDescriptor *method) { +std::string GetMethodRequestParamMaybe(const MethodDescriptor *method, + bool invocation_param=false) { if (method->client_streaming()) { return ""; } + if (invocation_param) { + return "request, "; + } return GetClassName(method->input_type()) + " request, "; } @@ -292,6 +300,86 @@ void GenerateClientInterface(Printer* out, const ServiceDescriptor *service) { out->Print("\n"); } +void GenerateClientBaseClass(Printer* out, const ServiceDescriptor *service) { + out->Print("// abstract client class\n"); + out->Print("public abstract class $name$ : ClientBase\n", "name", + GetClientBaseClassName(service)); + out->Print("{\n"); + out->Indent(); + + // constructors + out->Print( + "public $name$(Channel channel) : base(channel)\n", + "name", GetClientBaseClassName(service)); + out->Print("{\n"); + out->Print("}\n"); + + for (int i = 0; i < service->method_count(); i++) { + const MethodDescriptor *method = service->method(i); + MethodType method_type = GetMethodType(method); + + if (method_type == METHODTYPE_NO_STREAMING) { + // unary calls have an extra synchronous stub method + out->Print( + "public virtual $response$ $methodname$($request$ request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", + "methodname", method->name(), "request", + GetClassName(method->input_type()), "response", + GetClassName(method->output_type())); + out->Print("{\n"); + out->Indent(); + out->Print("return $methodname$(request, new CallOptions(headers, deadline, cancellationToken));\n", + "methodname", method->name()); + out->Outdent(); + out->Print("}\n"); + + // overload taking CallOptions as a param + out->Print( + "public virtual $response$ $methodname$($request$ request, CallOptions options)\n", + "methodname", method->name(), "request", + GetClassName(method->input_type()), "response", + GetClassName(method->output_type())); + out->Print("{\n"); + out->Indent(); + out->Print("throw new NotImplementedException();\n"); + out->Outdent(); + out->Print("}\n"); + } + + std::string method_name = method->name(); + if (method_type == METHODTYPE_NO_STREAMING) { + method_name += "Async"; // prevent name clash with synchronous method. + } + out->Print( + "public virtual $returntype$ $methodname$($request_maybe$Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", + "methodname", method_name, "request_maybe", + GetMethodRequestParamMaybe(method), "returntype", + GetMethodReturnTypeClient(method)); + out->Print("{\n"); + out->Indent(); + + out->Print("return $methodname$($request_maybe$new CallOptions(headers, deadline, cancellationToken));\n", + "methodname", method_name, + "request_maybe", GetMethodRequestParamMaybe(method, true)); + out->Outdent(); + out->Print("}\n"); + + // overload taking CallOptions as a param + out->Print( + "public virtual $returntype$ $methodname$($request_maybe$CallOptions options)\n", + "methodname", method_name, "request_maybe", + GetMethodRequestParamMaybe(method), "returntype", + GetMethodReturnTypeClient(method)); + out->Print("{\n"); + out->Indent(); + out->Print("throw new NotImplementedException();\n"); + out->Outdent(); + out->Print("}\n"); + } + out->Outdent(); + out->Print("}\n"); + out->Print("\n"); +} + void GenerateServerInterface(Printer* out, const ServiceDescriptor *service) { out->Print("// server-side interface\n"); out->Print("[System.Obsolete(\"Service implementations should inherit" @@ -345,9 +433,9 @@ void GenerateServerClass(Printer* out, const ServiceDescriptor *service) { void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Print("// client stub\n"); out->Print( - "public class $name$ : ClientBase, $interface$\n", - "name", GetClientClassName(service), "interface", - GetClientInterfaceName(service)); + "public class $name$ : $baseclass$\n", + "name", GetClientClassName(service), + "baseclass", GetClientBaseClassName(service)); out->Print("{\n"); out->Indent(); @@ -365,21 +453,7 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { if (method_type == METHODTYPE_NO_STREAMING) { // unary calls have an extra synchronous stub method out->Print( - "public $response$ $methodname$($request$ request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", - "methodname", method->name(), "request", - GetClassName(method->input_type()), "response", - GetClassName(method->output_type())); - out->Print("{\n"); - out->Indent(); - out->Print("var call = CreateCall($methodfield$, new CallOptions(headers, deadline, cancellationToken));\n", - "methodfield", GetMethodFieldName(method)); - out->Print("return Calls.BlockingUnaryCall(call, request);\n"); - out->Outdent(); - out->Print("}\n"); - - // overload taking CallOptions as a param - out->Print( - "public $response$ $methodname$($request$ request, CallOptions options)\n", + "public override $response$ $methodname$($request$ request, CallOptions options)\n", "methodname", method->name(), "request", GetClassName(method->input_type()), "response", GetClassName(method->output_type())); @@ -397,37 +471,7 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { method_name += "Async"; // prevent name clash with synchronous method. } out->Print( - "public $returntype$ $methodname$($request_maybe$Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", - "methodname", method_name, "request_maybe", - GetMethodRequestParamMaybe(method), "returntype", - GetMethodReturnTypeClient(method)); - out->Print("{\n"); - out->Indent(); - out->Print("var call = CreateCall($methodfield$, new CallOptions(headers, deadline, cancellationToken));\n", - "methodfield", GetMethodFieldName(method)); - switch (GetMethodType(method)) { - case METHODTYPE_NO_STREAMING: - out->Print("return Calls.AsyncUnaryCall(call, request);\n"); - break; - case METHODTYPE_CLIENT_STREAMING: - out->Print("return Calls.AsyncClientStreamingCall(call);\n"); - break; - case METHODTYPE_SERVER_STREAMING: - out->Print( - "return Calls.AsyncServerStreamingCall(call, request);\n"); - break; - case METHODTYPE_BIDI_STREAMING: - out->Print("return Calls.AsyncDuplexStreamingCall(call);\n"); - break; - default: - GOOGLE_LOG(FATAL)<< "Can't get here."; - } - out->Outdent(); - out->Print("}\n"); - - // overload taking CallOptions as a param - out->Print( - "public $returntype$ $methodname$($request_maybe$CallOptions options)\n", + "public override $returntype$ $methodname$($request_maybe$CallOptions options)\n", "methodname", method_name, "request_maybe", GetMethodRequestParamMaybe(method), "returntype", GetMethodReturnTypeClient(method)); @@ -523,6 +567,7 @@ void GenerateService(Printer* out, const ServiceDescriptor *service) { } GenerateServiceDescriptorProperty(out, service); GenerateClientInterface(out, service); + GenerateClientBaseClass(out, service); GenerateServerInterface(out, service); GenerateServerClass(out, service); GenerateClientStub(out, service); -- cgit v1.2.3 From d8f7c8ae0e80f787b2c1791adecf35c8b0ef9171 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 21 Mar 2016 19:02:58 -0700 Subject: migrate from client side interface to client side abstract class --- src/csharp/Grpc.Examples.MathClient/MathClient.cs | 2 +- src/csharp/Grpc.Examples/MathExamples.cs | 12 +++++------ .../HealthClientServerTest.cs | 2 +- .../Grpc.IntegrationTesting/ClientRunners.cs | 2 +- .../Grpc.IntegrationTesting/InteropClient.cs | 24 +++++++++++----------- .../InteropClientServerTest.cs | 2 +- .../MetadataCredentialsTest.cs | 6 +++--- .../Grpc.IntegrationTesting/SslCredentialsTest.cs | 2 +- 8 files changed, 26 insertions(+), 26 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Examples.MathClient/MathClient.cs b/src/csharp/Grpc.Examples.MathClient/MathClient.cs index 64e429ed5a..3bea38fe98 100644 --- a/src/csharp/Grpc.Examples.MathClient/MathClient.cs +++ b/src/csharp/Grpc.Examples.MathClient/MathClient.cs @@ -40,7 +40,7 @@ namespace Math public static void Main(string[] args) { var channel = new Channel("127.0.0.1", 23456, ChannelCredentials.Insecure); - Math.IMathClient client = new Math.MathClient(channel); + Math.MathClientBase client = new Math.MathClient(channel); MathExamples.DivExample(client); MathExamples.DivAsyncExample(client).Wait(); diff --git a/src/csharp/Grpc.Examples/MathExamples.cs b/src/csharp/Grpc.Examples/MathExamples.cs index 8009ccbbfa..4ba1f71f78 100644 --- a/src/csharp/Grpc.Examples/MathExamples.cs +++ b/src/csharp/Grpc.Examples/MathExamples.cs @@ -38,19 +38,19 @@ namespace Math { public static class MathExamples { - public static void DivExample(Math.IMathClient client) + public static void DivExample(Math.MathClientBase client) { DivReply result = client.Div(new DivArgs { Dividend = 10, Divisor = 3 }); Console.WriteLine("Div Result: " + result); } - public static async Task DivAsyncExample(Math.IMathClient client) + public static async Task DivAsyncExample(Math.MathClientBase client) { DivReply result = await client.DivAsync(new DivArgs { Dividend = 4, Divisor = 5 }); Console.WriteLine("DivAsync Result: " + result); } - public static async Task FibExample(Math.IMathClient client) + public static async Task FibExample(Math.MathClientBase client) { using (var call = client.Fib(new FibArgs { Limit = 5 })) { @@ -59,7 +59,7 @@ namespace Math } } - public static async Task SumExample(Math.IMathClient client) + public static async Task SumExample(Math.MathClientBase client) { var numbers = new List { @@ -75,7 +75,7 @@ namespace Math } } - public static async Task DivManyExample(Math.IMathClient client) + public static async Task DivManyExample(Math.MathClientBase client) { var divArgsList = new List { @@ -90,7 +90,7 @@ namespace Math } } - public static async Task DependendRequestsExample(Math.IMathClient client) + public static async Task DependendRequestsExample(Math.MathClientBase client) { var numbers = new List { diff --git a/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs b/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs index 8318e84277..d85f1cf8bb 100644 --- a/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs +++ b/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs @@ -49,7 +49,7 @@ namespace Grpc.HealthCheck.Tests const string Host = "localhost"; Server server; Channel channel; - Grpc.Health.V1.Health.IHealthClient client; + Grpc.Health.V1.Health.HealthClientBase client; Grpc.HealthCheck.HealthServiceImpl serviceImpl; [TestFixtureSetUp] diff --git a/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs b/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs index 5bfc89d591..302094ef8d 100644 --- a/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs +++ b/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs @@ -112,7 +112,7 @@ namespace Grpc.IntegrationTesting readonly PayloadConfig payloadConfig; readonly Histogram histogram; - readonly BenchmarkService.IBenchmarkServiceClient client; + readonly BenchmarkService.BenchmarkServiceClientBase client; readonly Task runnerTask; readonly CancellationTokenSource stoppedCts; readonly WallClockStopwatch wallClockStopwatch = new WallClockStopwatch(); diff --git a/src/csharp/Grpc.IntegrationTesting/InteropClient.cs b/src/csharp/Grpc.IntegrationTesting/InteropClient.cs index b0e33e49f7..9a1323a79b 100644 --- a/src/csharp/Grpc.IntegrationTesting/InteropClient.cs +++ b/src/csharp/Grpc.IntegrationTesting/InteropClient.cs @@ -217,7 +217,7 @@ namespace Grpc.IntegrationTesting } } - public static void RunEmptyUnary(TestService.ITestServiceClient client) + public static void RunEmptyUnary(TestService.TestServiceClientBase client) { Console.WriteLine("running empty_unary"); var response = client.EmptyCall(new Empty()); @@ -225,7 +225,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static void RunLargeUnary(TestService.ITestServiceClient client) + public static void RunLargeUnary(TestService.TestServiceClientBase client) { Console.WriteLine("running large_unary"); var request = new SimpleRequest @@ -241,7 +241,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunClientStreamingAsync(TestService.ITestServiceClient client) + public static async Task RunClientStreamingAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running client_streaming"); @@ -257,7 +257,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunServerStreamingAsync(TestService.ITestServiceClient client) + public static async Task RunServerStreamingAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running server_streaming"); @@ -281,7 +281,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunPingPongAsync(TestService.ITestServiceClient client) + public static async Task RunPingPongAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running ping_pong"); @@ -338,7 +338,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunEmptyStreamAsync(TestService.ITestServiceClient client) + public static async Task RunEmptyStreamAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running empty_stream"); using (var call = client.FullDuplexCall()) @@ -434,7 +434,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunCancelAfterBeginAsync(TestService.ITestServiceClient client) + public static async Task RunCancelAfterBeginAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running cancel_after_begin"); @@ -451,7 +451,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunCancelAfterFirstResponseAsync(TestService.ITestServiceClient client) + public static async Task RunCancelAfterFirstResponseAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running cancel_after_first_response"); @@ -477,7 +477,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunTimeoutOnSleepingServerAsync(TestService.ITestServiceClient client) + public static async Task RunTimeoutOnSleepingServerAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running timeout_on_sleeping_server"); @@ -499,7 +499,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunCustomMetadataAsync(TestService.ITestServiceClient client) + public static async Task RunCustomMetadataAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running custom_metadata"); { @@ -546,7 +546,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunStatusCodeAndMessageAsync(TestService.ITestServiceClient client) + public static async Task RunStatusCodeAndMessageAsync(TestService.TestServiceClientBase client) { Console.WriteLine("running status_code_and_message"); var echoStatus = new EchoStatus @@ -580,7 +580,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static void RunUnimplementedMethod(UnimplementedService.IUnimplementedServiceClient client) + public static void RunUnimplementedMethod(UnimplementedService.UnimplementedServiceClientBase client) { Console.WriteLine("running unimplemented_method"); var e = Assert.Throws(() => client.UnimplementedCall(new Empty())); diff --git a/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs b/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs index 5facb87971..41efa33017 100644 --- a/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs @@ -51,7 +51,7 @@ namespace Grpc.IntegrationTesting const string Host = "localhost"; Server server; Channel channel; - TestService.ITestServiceClient client; + TestService.TestServiceClientBase client; [TestFixtureSetUp] public void Init() diff --git a/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs b/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs index 1c8bfed1f6..eb4079e3a5 100644 --- a/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs @@ -50,15 +50,15 @@ namespace Grpc.IntegrationTesting const string Host = "localhost"; Server server; Channel channel; - TestService.ITestServiceClient client; + TestService.TestServiceClient client; List options; - Mock serviceMock; + Mock serviceMock; AsyncAuthInterceptor asyncAuthInterceptor; [SetUp] public void Init() { - serviceMock = new Mock(); + serviceMock = new Mock(); serviceMock.Setup(m => m.UnaryCall(It.IsAny(), It.IsAny())) .Returns(new Func>(UnaryCallHandler)); diff --git a/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs b/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs index 37b2518c21..ed402c5f77 100644 --- a/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs @@ -53,7 +53,7 @@ namespace Grpc.IntegrationTesting const string Host = "localhost"; Server server; Channel channel; - TestService.ITestServiceClient client; + TestService.TestServiceClientBase client; [TestFixtureSetUp] public void Init() -- cgit v1.2.3 From 8496efa146c5882746cc05aa9ab5812853e3724c Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 22 Mar 2016 11:34:09 -0700 Subject: add concept of CallInvoker --- src/csharp/Grpc.Core/CallInvoker.cs | 84 +++++++++++++++++++++ src/csharp/Grpc.Core/DefaultCallInvoker.cs | 114 +++++++++++++++++++++++++++++ src/csharp/Grpc.Core/Grpc.Core.csproj | 2 + 3 files changed, 200 insertions(+) create mode 100644 src/csharp/Grpc.Core/CallInvoker.cs create mode 100644 src/csharp/Grpc.Core/DefaultCallInvoker.cs (limited to 'src') diff --git a/src/csharp/Grpc.Core/CallInvoker.cs b/src/csharp/Grpc.Core/CallInvoker.cs new file mode 100644 index 0000000000..e8e43968f8 --- /dev/null +++ b/src/csharp/Grpc.Core/CallInvoker.cs @@ -0,0 +1,84 @@ +#region Copyright notice and license + +// Copyright 2015, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System.Threading.Tasks; +using Grpc.Core.Internal; + +namespace Grpc.Core +{ + /// + /// Abstraction of client-side RPC invocation. + /// + /// + public abstract class CallInvoker + { + /// + /// Invokes a simple remote call in a blocking fashion. + /// + public abstract TResponse BlockingUnaryCall(Method method, CallOptions options, TRequest request) + where TRequest : class + where TResponse : class; + + /// + /// Invokes a simple remote call asynchronously. + /// + public abstract AsyncUnaryCall AsyncUnaryCall(Method method, CallOptions options, TRequest request) + where TRequest : class + where TResponse : class; + + /// + /// Invokes a server streaming call asynchronously. + /// In server streaming scenario, client sends on request and server responds with a stream of responses. + /// + public abstract AsyncServerStreamingCall AsyncServerStreamingCall(Method method, CallOptions options, TRequest request) + where TRequest : class + where TResponse : class; + + /// + /// Invokes a client streaming call asynchronously. + /// In client streaming scenario, client sends a stream of requests and server responds with a single response. + /// + public abstract AsyncClientStreamingCall AsyncClientStreamingCall(Method method, CallOptions options) + where TRequest : class + where TResponse : class; + + /// + /// Invokes a duplex streaming call asynchronously. + /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. + /// The response stream is completely independent and both side can be sending messages at the same time. + /// + public abstract AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, CallOptions options) + where TRequest : class + where TResponse : class; + } +} diff --git a/src/csharp/Grpc.Core/DefaultCallInvoker.cs b/src/csharp/Grpc.Core/DefaultCallInvoker.cs new file mode 100644 index 0000000000..2ec64019ac --- /dev/null +++ b/src/csharp/Grpc.Core/DefaultCallInvoker.cs @@ -0,0 +1,114 @@ +#region Copyright notice and license + +// Copyright 2015, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System.Threading.Tasks; +using Grpc.Core.Internal; +using Grpc.Core.Utils; + +namespace Grpc.Core +{ + /// + /// Invokes client RPCs using . + /// + public class DefaultCallInvoker : CallInvoker + { + readonly Channel channel; + + public DefaultCallInvoker(Channel channel) + { + this.channel = GrpcPreconditions.CheckNotNull(channel); + } + + public string Host + { + get; + set; + } + + /// + /// Invokes a simple remote call in a blocking fashion. + /// + public override TResponse BlockingUnaryCall(Method method, CallOptions options, TRequest request) + { + var call = CreateCall(method, options); + return Calls.BlockingUnaryCall(call, request); + } + + /// + /// Invokes a simple remote call asynchronously. + /// + public override AsyncUnaryCall AsyncUnaryCall(Method method, CallOptions options, TRequest request) + { + var call = CreateCall(method, options); + return Calls.AsyncUnaryCall(call, request); + } + + /// + /// Invokes a server streaming call asynchronously. + /// In server streaming scenario, client sends on request and server responds with a stream of responses. + /// + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, CallOptions options, TRequest request) + { + var call = CreateCall(method, options); + return Calls.AsyncServerStreamingCall(call, request); + } + + /// + /// Invokes a client streaming call asynchronously. + /// In client streaming scenario, client sends a stream of requests and server responds with a single response. + /// + public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, CallOptions options) + { + var call = CreateCall(method, options); + return Calls.AsyncClientStreamingCall(call); + } + + /// + /// Invokes a duplex streaming call asynchronously. + /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. + /// The response stream is completely independent and both side can be sending messages at the same time. + /// + public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, CallOptions options) + { + var call = CreateCall(method, options); + return Calls.AsyncDuplexStreamingCall(call); + } + + private CallInvocationDetails CreateCall(Method method, CallOptions options) + where TRequest : class + where TResponse : class + { + return new CallInvocationDetails(channel, method, Host, options); + } + } +} diff --git a/src/csharp/Grpc.Core/Grpc.Core.csproj b/src/csharp/Grpc.Core/Grpc.Core.csproj index 3189835ccd..d8c04b3adb 100644 --- a/src/csharp/Grpc.Core/Grpc.Core.csproj +++ b/src/csharp/Grpc.Core/Grpc.Core.csproj @@ -129,6 +129,8 @@ + + -- cgit v1.2.3 From 055c2dd5fc7a096d5714dd31e76190bdf22ca918 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 22 Mar 2016 14:43:56 -0700 Subject: generate only one Client class instead of abstract & concrete --- src/compiler/csharp_generator.cc | 166 ++++++++++++++------------------------- 1 file changed, 61 insertions(+), 105 deletions(-) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index fb11d98fe4..bc40880e5c 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -73,10 +73,6 @@ std::string GetClientInterfaceName(const ServiceDescriptor* service) { return "I" + service->name() + "Client"; } -std::string GetClientBaseClassName(const ServiceDescriptor* service) { - return service->name() + "ClientBase"; -} - std::string GetClientClassName(const ServiceDescriptor* service) { return service->name() + "Client"; } @@ -300,86 +296,6 @@ void GenerateClientInterface(Printer* out, const ServiceDescriptor *service) { out->Print("\n"); } -void GenerateClientBaseClass(Printer* out, const ServiceDescriptor *service) { - out->Print("// abstract client class\n"); - out->Print("public abstract class $name$ : ClientBase\n", "name", - GetClientBaseClassName(service)); - out->Print("{\n"); - out->Indent(); - - // constructors - out->Print( - "public $name$(Channel channel) : base(channel)\n", - "name", GetClientBaseClassName(service)); - out->Print("{\n"); - out->Print("}\n"); - - for (int i = 0; i < service->method_count(); i++) { - const MethodDescriptor *method = service->method(i); - MethodType method_type = GetMethodType(method); - - if (method_type == METHODTYPE_NO_STREAMING) { - // unary calls have an extra synchronous stub method - out->Print( - "public virtual $response$ $methodname$($request$ request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", - "methodname", method->name(), "request", - GetClassName(method->input_type()), "response", - GetClassName(method->output_type())); - out->Print("{\n"); - out->Indent(); - out->Print("return $methodname$(request, new CallOptions(headers, deadline, cancellationToken));\n", - "methodname", method->name()); - out->Outdent(); - out->Print("}\n"); - - // overload taking CallOptions as a param - out->Print( - "public virtual $response$ $methodname$($request$ request, CallOptions options)\n", - "methodname", method->name(), "request", - GetClassName(method->input_type()), "response", - GetClassName(method->output_type())); - out->Print("{\n"); - out->Indent(); - out->Print("throw new NotImplementedException();\n"); - out->Outdent(); - out->Print("}\n"); - } - - std::string method_name = method->name(); - if (method_type == METHODTYPE_NO_STREAMING) { - method_name += "Async"; // prevent name clash with synchronous method. - } - out->Print( - "public virtual $returntype$ $methodname$($request_maybe$Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", - "methodname", method_name, "request_maybe", - GetMethodRequestParamMaybe(method), "returntype", - GetMethodReturnTypeClient(method)); - out->Print("{\n"); - out->Indent(); - - out->Print("return $methodname$($request_maybe$new CallOptions(headers, deadline, cancellationToken));\n", - "methodname", method_name, - "request_maybe", GetMethodRequestParamMaybe(method, true)); - out->Outdent(); - out->Print("}\n"); - - // overload taking CallOptions as a param - out->Print( - "public virtual $returntype$ $methodname$($request_maybe$CallOptions options)\n", - "methodname", method_name, "request_maybe", - GetMethodRequestParamMaybe(method), "returntype", - GetMethodReturnTypeClient(method)); - out->Print("{\n"); - out->Indent(); - out->Print("throw new NotImplementedException();\n"); - out->Outdent(); - out->Print("}\n"); - } - out->Outdent(); - out->Print("}\n"); - out->Print("\n"); -} - void GenerateServerInterface(Printer* out, const ServiceDescriptor *service) { out->Print("// server-side interface\n"); out->Print("[System.Obsolete(\"Service implementations should inherit" @@ -433,18 +349,20 @@ void GenerateServerClass(Printer* out, const ServiceDescriptor *service) { void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Print("// client stub\n"); out->Print( - "public class $name$ : $baseclass$\n", - "name", GetClientClassName(service), - "baseclass", GetClientBaseClassName(service)); + "public class $name$ : ClientBase<$name$>\n", + "name", GetClientClassName(service)); out->Print("{\n"); out->Indent(); // constructors - out->Print( - "public $name$(Channel channel) : base(channel)\n", - "name", GetClientClassName(service)); + out->Print("public $name$(Channel channel) : base(channel)\n", + "name", GetClientClassName(service)); out->Print("{\n"); out->Print("}\n"); + out->Print("public $name$(CallInvoker callInvoker) : base(callInvoker)\n", + "name", GetClientClassName(service)); + out->Print("{\n"); + out->Print("}\n\n"); for (int i = 0; i < service->method_count(); i++) { const MethodDescriptor *method = service->method(i); @@ -452,16 +370,26 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { if (method_type == METHODTYPE_NO_STREAMING) { // unary calls have an extra synchronous stub method - out->Print( - "public override $response$ $methodname$($request$ request, CallOptions options)\n", - "methodname", method->name(), "request", - GetClassName(method->input_type()), "response", - GetClassName(method->output_type())); + out->Print("public virtual $response$ $methodname$($request$ request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", + "methodname", method->name(), "request", + GetClassName(method->input_type()), "response", + GetClassName(method->output_type())); + out->Print("{\n"); + out->Indent(); + out->Print("return $methodname$(request, new CallOptions(headers, deadline, cancellationToken));\n", + "methodname", method->name()); + out->Outdent(); + out->Print("}\n"); + + // overload taking CallOptions as a param + out->Print("public virtual $response$ $methodname$($request$ request, CallOptions options)\n", + "methodname", method->name(), "request", + GetClassName(method->input_type()), "response", + GetClassName(method->output_type())); out->Print("{\n"); out->Indent(); - out->Print("var call = CreateCall($methodfield$, options);\n", + out->Print("return CallInvoker.BlockingUnaryCall($methodfield$, options, request);\n", "methodfield", GetMethodFieldName(method)); - out->Print("return Calls.BlockingUnaryCall(call, request);\n"); out->Outdent(); out->Print("}\n"); } @@ -471,27 +399,44 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { method_name += "Async"; // prevent name clash with synchronous method. } out->Print( - "public override $returntype$ $methodname$($request_maybe$CallOptions options)\n", + "public virtual $returntype$ $methodname$($request_maybe$Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))\n", + "methodname", method_name, "request_maybe", + GetMethodRequestParamMaybe(method), "returntype", + GetMethodReturnTypeClient(method)); + out->Print("{\n"); + out->Indent(); + + out->Print("return $methodname$($request_maybe$new CallOptions(headers, deadline, cancellationToken));\n", + "methodname", method_name, + "request_maybe", GetMethodRequestParamMaybe(method, true)); + out->Outdent(); + out->Print("}\n"); + + // overload taking CallOptions as a param + out->Print( + "public virtual $returntype$ $methodname$($request_maybe$CallOptions options)\n", "methodname", method_name, "request_maybe", GetMethodRequestParamMaybe(method), "returntype", GetMethodReturnTypeClient(method)); out->Print("{\n"); out->Indent(); - out->Print("var call = CreateCall($methodfield$, options);\n", - "methodfield", GetMethodFieldName(method)); switch (GetMethodType(method)) { case METHODTYPE_NO_STREAMING: - out->Print("return Calls.AsyncUnaryCall(call, request);\n"); + out->Print("return CallInvoker.AsyncUnaryCall($methodfield$, options, request);\n", + "methodfield", GetMethodFieldName(method)); break; case METHODTYPE_CLIENT_STREAMING: - out->Print("return Calls.AsyncClientStreamingCall(call);\n"); + out->Print("return CallInvoker.AsyncClientStreamingCall($methodfield$, options);\n", + "methodfield", GetMethodFieldName(method)); break; case METHODTYPE_SERVER_STREAMING: out->Print( - "return Calls.AsyncServerStreamingCall(call, request);\n"); + "return CallInvoker.AsyncServerStreamingCall($methodfield$, options, request);\n", + "methodfield", GetMethodFieldName(method)); break; case METHODTYPE_BIDI_STREAMING: - out->Print("return Calls.AsyncDuplexStreamingCall(call);\n"); + out->Print("return CallInvoker.AsyncDuplexStreamingCall($methodfield$, options);\n", + "methodfield", GetMethodFieldName(method)); break; default: GOOGLE_LOG(FATAL)<< "Can't get here."; @@ -499,6 +444,17 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Outdent(); out->Print("}\n"); } + + // override NewInstance method + out->Print("protected override $name$ NewInstance(CallInvoker callInvoker)\n", + "name", GetClientClassName(service)); + out->Print("{\n"); + out->Indent(); + out->Print("return new $name$(callInvoker);\n", + "name", GetClientClassName(service)); + out->Outdent(); + out->Print("}\n"); + out->Outdent(); out->Print("}\n"); out->Print("\n"); @@ -567,7 +523,7 @@ void GenerateService(Printer* out, const ServiceDescriptor *service) { } GenerateServiceDescriptorProperty(out, service); GenerateClientInterface(out, service); - GenerateClientBaseClass(out, service); + //GenerateClientBaseClass(out, service); GenerateServerInterface(out, service); GenerateServerClass(out, service); GenerateClientStub(out, service); -- cgit v1.2.3 From d9495abc3c618a2fbe2363a31155b77085b49f70 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 22 Mar 2016 15:01:57 -0700 Subject: refactor ClientBase --- src/csharp/Grpc.Core/ClientBase.cs | 94 ++++++++++++++++++++---------- src/csharp/Grpc.Core/DefaultCallInvoker.cs | 19 +++--- 2 files changed, 75 insertions(+), 38 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index e5b398062b..f5d6ae744f 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -34,31 +34,76 @@ using System; using System.Text.RegularExpressions; using System.Threading.Tasks; +using Grpc.Core.Utils; namespace Grpc.Core { /// /// Interceptor for call headers. /// - /// Header interceptor is no longer to recommented way to perform authentication. + /// Header interceptor is no longer the recommended way to perform authentication. /// For header (initial metadata) based auth such as OAuth2 or JWT access token, use . /// public delegate void HeaderInterceptor(IMethod method, Metadata metadata); + /// + /// Generic base class for client-side stubs. + /// + public abstract class ClientBase : ClientBase + where T : ClientBase + { + /// + /// Initializes a new instance of ClientBase class. + /// + /// The channel to use for remote call invocation. + public ClientBase(Channel channel) : base(channel) + { + } + + /// + /// Initializes a new instance of ClientBase class. + /// + /// The CallInvoker for remote call invocation. + public ClientBase(CallInvoker callInvoker) : base(callInvoker) + { + } + + /// + /// Creates a new instance of client from given CallInvoker. + /// + protected abstract T NewInstance(CallInvoker callInvoker); + } + /// /// Base class for client-side stubs. /// public abstract class ClientBase { - readonly Channel channel; + readonly CallInvoker callInvoker; /// /// Initializes a new instance of ClientBase class. /// /// The channel to use for remote call invocation. - public ClientBase(Channel channel) + public ClientBase(Channel channel) : this(new DefaultCallInvoker(channel)) + { + } + + /// + /// Initializes a new instance of ClientBase class. + /// + /// The CallInvoker for remote call invocation. + public ClientBase(CallInvoker callInvoker) { - this.channel = channel; + this.callInvoker = GrpcPreconditions.CheckNotNull(callInvoker); + } + + /// + /// Gets the call invoker. + /// + protected CallInvoker CallInvoker + { + get { return this.callInvoker; } } /// @@ -85,17 +130,6 @@ namespace Grpc.Core set; } - /// - /// Channel associated with this client. - /// - public Channel Channel - { - get - { - return this.channel; - } - } - /// /// Creates a new call to given method. /// @@ -104,20 +138,20 @@ namespace Grpc.Core /// Request message type. /// Response message type. /// The call invocation details. - protected CallInvocationDetails CreateCall(Method method, CallOptions options) - where TRequest : class - where TResponse : class - { - var interceptor = HeaderInterceptor; - if (interceptor != null) - { - if (options.Headers == null) - { - options = options.WithHeaders(new Metadata()); - } - interceptor(method, options.Headers); - } - return new CallInvocationDetails(channel, method, Host, options); - } + //protected CallInvocationDetails CreateCall(Method method, CallOptions options) + // where TRequest : class + // where TResponse : class + //{ + // var interceptor = HeaderInterceptor; + // if (interceptor != null) + // { + // if (options.Headers == null) + // { + // options = options.WithHeaders(new Metadata()); + // } + // interceptor(method, options.Headers); + // } + // return new CallInvocationDetails(channel, method, Host, options); + //} } } diff --git a/src/csharp/Grpc.Core/DefaultCallInvoker.cs b/src/csharp/Grpc.Core/DefaultCallInvoker.cs index 2ec64019ac..8b77651c0c 100644 --- a/src/csharp/Grpc.Core/DefaultCallInvoker.cs +++ b/src/csharp/Grpc.Core/DefaultCallInvoker.cs @@ -44,17 +44,15 @@ namespace Grpc.Core { readonly Channel channel; + /// + /// Initializes a new instance of the class. + /// + /// Channel to use. public DefaultCallInvoker(Channel channel) { this.channel = GrpcPreconditions.CheckNotNull(channel); } - public string Host - { - get; - set; - } - /// /// Invokes a simple remote call in a blocking fashion. /// @@ -104,11 +102,16 @@ namespace Grpc.Core return Calls.AsyncDuplexStreamingCall(call); } - private CallInvocationDetails CreateCall(Method method, CallOptions options) + protected virtual string Host + { + get { return null; } + } + + protected virtual CallInvocationDetails CreateCall(Method method, CallOptions options) where TRequest : class where TResponse : class { - return new CallInvocationDetails(channel, method, Host, options); + return new CallInvocationDetails(channel, method, Host, options); } } } -- cgit v1.2.3 From 809148d6c5702a6a5a35d175ccb39c447acf9204 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 22 Mar 2016 15:09:41 -0700 Subject: migrate code to single client-side class --- src/csharp/Grpc.Examples.MathClient/MathClient.cs | 2 +- src/csharp/Grpc.Examples/MathExamples.cs | 12 +++++------ .../HealthClientServerTest.cs | 2 +- .../Grpc.IntegrationTesting/ClientRunners.cs | 2 +- .../Grpc.IntegrationTesting/InteropClient.cs | 24 +++++++++++----------- .../InteropClientServerTest.cs | 2 +- .../Grpc.IntegrationTesting/SslCredentialsTest.cs | 2 +- 7 files changed, 23 insertions(+), 23 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Examples.MathClient/MathClient.cs b/src/csharp/Grpc.Examples.MathClient/MathClient.cs index 3bea38fe98..2f3ef85b4d 100644 --- a/src/csharp/Grpc.Examples.MathClient/MathClient.cs +++ b/src/csharp/Grpc.Examples.MathClient/MathClient.cs @@ -40,7 +40,7 @@ namespace Math public static void Main(string[] args) { var channel = new Channel("127.0.0.1", 23456, ChannelCredentials.Insecure); - Math.MathClientBase client = new Math.MathClient(channel); + Math.MathClient client = new Math.MathClient(channel); MathExamples.DivExample(client); MathExamples.DivAsyncExample(client).Wait(); diff --git a/src/csharp/Grpc.Examples/MathExamples.cs b/src/csharp/Grpc.Examples/MathExamples.cs index 4ba1f71f78..95417d9034 100644 --- a/src/csharp/Grpc.Examples/MathExamples.cs +++ b/src/csharp/Grpc.Examples/MathExamples.cs @@ -38,19 +38,19 @@ namespace Math { public static class MathExamples { - public static void DivExample(Math.MathClientBase client) + public static void DivExample(Math.MathClient client) { DivReply result = client.Div(new DivArgs { Dividend = 10, Divisor = 3 }); Console.WriteLine("Div Result: " + result); } - public static async Task DivAsyncExample(Math.MathClientBase client) + public static async Task DivAsyncExample(Math.MathClient client) { DivReply result = await client.DivAsync(new DivArgs { Dividend = 4, Divisor = 5 }); Console.WriteLine("DivAsync Result: " + result); } - public static async Task FibExample(Math.MathClientBase client) + public static async Task FibExample(Math.MathClient client) { using (var call = client.Fib(new FibArgs { Limit = 5 })) { @@ -59,7 +59,7 @@ namespace Math } } - public static async Task SumExample(Math.MathClientBase client) + public static async Task SumExample(Math.MathClient client) { var numbers = new List { @@ -75,7 +75,7 @@ namespace Math } } - public static async Task DivManyExample(Math.MathClientBase client) + public static async Task DivManyExample(Math.MathClient client) { var divArgsList = new List { @@ -90,7 +90,7 @@ namespace Math } } - public static async Task DependendRequestsExample(Math.MathClientBase client) + public static async Task DependendRequestsExample(Math.MathClient client) { var numbers = new List { diff --git a/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs b/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs index d85f1cf8bb..fb292945a6 100644 --- a/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs +++ b/src/csharp/Grpc.HealthCheck.Tests/HealthClientServerTest.cs @@ -49,7 +49,7 @@ namespace Grpc.HealthCheck.Tests const string Host = "localhost"; Server server; Channel channel; - Grpc.Health.V1.Health.HealthClientBase client; + Grpc.Health.V1.Health.HealthClient client; Grpc.HealthCheck.HealthServiceImpl serviceImpl; [TestFixtureSetUp] diff --git a/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs b/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs index 302094ef8d..0bcacf76e5 100644 --- a/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs +++ b/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs @@ -112,7 +112,7 @@ namespace Grpc.IntegrationTesting readonly PayloadConfig payloadConfig; readonly Histogram histogram; - readonly BenchmarkService.BenchmarkServiceClientBase client; + readonly BenchmarkService.BenchmarkServiceClient client; readonly Task runnerTask; readonly CancellationTokenSource stoppedCts; readonly WallClockStopwatch wallClockStopwatch = new WallClockStopwatch(); diff --git a/src/csharp/Grpc.IntegrationTesting/InteropClient.cs b/src/csharp/Grpc.IntegrationTesting/InteropClient.cs index 9a1323a79b..ec001ffaa4 100644 --- a/src/csharp/Grpc.IntegrationTesting/InteropClient.cs +++ b/src/csharp/Grpc.IntegrationTesting/InteropClient.cs @@ -217,7 +217,7 @@ namespace Grpc.IntegrationTesting } } - public static void RunEmptyUnary(TestService.TestServiceClientBase client) + public static void RunEmptyUnary(TestService.TestServiceClient client) { Console.WriteLine("running empty_unary"); var response = client.EmptyCall(new Empty()); @@ -225,7 +225,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static void RunLargeUnary(TestService.TestServiceClientBase client) + public static void RunLargeUnary(TestService.TestServiceClient client) { Console.WriteLine("running large_unary"); var request = new SimpleRequest @@ -241,7 +241,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunClientStreamingAsync(TestService.TestServiceClientBase client) + public static async Task RunClientStreamingAsync(TestService.TestServiceClient client) { Console.WriteLine("running client_streaming"); @@ -257,7 +257,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunServerStreamingAsync(TestService.TestServiceClientBase client) + public static async Task RunServerStreamingAsync(TestService.TestServiceClient client) { Console.WriteLine("running server_streaming"); @@ -281,7 +281,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunPingPongAsync(TestService.TestServiceClientBase client) + public static async Task RunPingPongAsync(TestService.TestServiceClient client) { Console.WriteLine("running ping_pong"); @@ -338,7 +338,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunEmptyStreamAsync(TestService.TestServiceClientBase client) + public static async Task RunEmptyStreamAsync(TestService.TestServiceClient client) { Console.WriteLine("running empty_stream"); using (var call = client.FullDuplexCall()) @@ -434,7 +434,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunCancelAfterBeginAsync(TestService.TestServiceClientBase client) + public static async Task RunCancelAfterBeginAsync(TestService.TestServiceClient client) { Console.WriteLine("running cancel_after_begin"); @@ -451,7 +451,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunCancelAfterFirstResponseAsync(TestService.TestServiceClientBase client) + public static async Task RunCancelAfterFirstResponseAsync(TestService.TestServiceClient client) { Console.WriteLine("running cancel_after_first_response"); @@ -477,7 +477,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunTimeoutOnSleepingServerAsync(TestService.TestServiceClientBase client) + public static async Task RunTimeoutOnSleepingServerAsync(TestService.TestServiceClient client) { Console.WriteLine("running timeout_on_sleeping_server"); @@ -499,7 +499,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunCustomMetadataAsync(TestService.TestServiceClientBase client) + public static async Task RunCustomMetadataAsync(TestService.TestServiceClient client) { Console.WriteLine("running custom_metadata"); { @@ -546,7 +546,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static async Task RunStatusCodeAndMessageAsync(TestService.TestServiceClientBase client) + public static async Task RunStatusCodeAndMessageAsync(TestService.TestServiceClient client) { Console.WriteLine("running status_code_and_message"); var echoStatus = new EchoStatus @@ -580,7 +580,7 @@ namespace Grpc.IntegrationTesting Console.WriteLine("Passed!"); } - public static void RunUnimplementedMethod(UnimplementedService.UnimplementedServiceClientBase client) + public static void RunUnimplementedMethod(UnimplementedService.UnimplementedServiceClient client) { Console.WriteLine("running unimplemented_method"); var e = Assert.Throws(() => client.UnimplementedCall(new Empty())); diff --git a/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs b/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs index 41efa33017..4ee1ff5ec8 100644 --- a/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/InteropClientServerTest.cs @@ -51,7 +51,7 @@ namespace Grpc.IntegrationTesting const string Host = "localhost"; Server server; Channel channel; - TestService.TestServiceClientBase client; + TestService.TestServiceClient client; [TestFixtureSetUp] public void Init() diff --git a/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs b/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs index ed402c5f77..c7792f75f3 100644 --- a/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs @@ -53,7 +53,7 @@ namespace Grpc.IntegrationTesting const string Host = "localhost"; Server server; Channel channel; - TestService.TestServiceClientBase client; + TestService.TestServiceClient client; [TestFixtureSetUp] public void Init() -- cgit v1.2.3 From b455bcc30101e41625753888626b17a5e48f6cdc Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 22 Mar 2016 16:08:18 -0700 Subject: add host field support to CallInvoker --- src/compiler/csharp_generator.cc | 10 +++++----- src/csharp/Grpc.Core/CallInvoker.cs | 10 +++++----- src/csharp/Grpc.Core/ClientBase.cs | 10 +++++----- src/csharp/Grpc.Core/DefaultCallInvoker.cs | 29 ++++++++++++----------------- 4 files changed, 27 insertions(+), 32 deletions(-) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index bc40880e5c..4a96a909de 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -388,7 +388,7 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { GetClassName(method->output_type())); out->Print("{\n"); out->Indent(); - out->Print("return CallInvoker.BlockingUnaryCall($methodfield$, options, request);\n", + out->Print("return CallInvoker.BlockingUnaryCall($methodfield$, null, options, request);\n", "methodfield", GetMethodFieldName(method)); out->Outdent(); out->Print("}\n"); @@ -422,20 +422,20 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Indent(); switch (GetMethodType(method)) { case METHODTYPE_NO_STREAMING: - out->Print("return CallInvoker.AsyncUnaryCall($methodfield$, options, request);\n", + out->Print("return CallInvoker.AsyncUnaryCall($methodfield$, null, options, request);\n", "methodfield", GetMethodFieldName(method)); break; case METHODTYPE_CLIENT_STREAMING: - out->Print("return CallInvoker.AsyncClientStreamingCall($methodfield$, options);\n", + out->Print("return CallInvoker.AsyncClientStreamingCall($methodfield$, null, options);\n", "methodfield", GetMethodFieldName(method)); break; case METHODTYPE_SERVER_STREAMING: out->Print( - "return CallInvoker.AsyncServerStreamingCall($methodfield$, options, request);\n", + "return CallInvoker.AsyncServerStreamingCall($methodfield$, null, options, request);\n", "methodfield", GetMethodFieldName(method)); break; case METHODTYPE_BIDI_STREAMING: - out->Print("return CallInvoker.AsyncDuplexStreamingCall($methodfield$, options);\n", + out->Print("return CallInvoker.AsyncDuplexStreamingCall($methodfield$, null, options);\n", "methodfield", GetMethodFieldName(method)); break; default: diff --git a/src/csharp/Grpc.Core/CallInvoker.cs b/src/csharp/Grpc.Core/CallInvoker.cs index e8e43968f8..cec5255692 100644 --- a/src/csharp/Grpc.Core/CallInvoker.cs +++ b/src/csharp/Grpc.Core/CallInvoker.cs @@ -45,14 +45,14 @@ namespace Grpc.Core /// /// Invokes a simple remote call in a blocking fashion. /// - public abstract TResponse BlockingUnaryCall(Method method, CallOptions options, TRequest request) + public abstract TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) where TRequest : class where TResponse : class; /// /// Invokes a simple remote call asynchronously. /// - public abstract AsyncUnaryCall AsyncUnaryCall(Method method, CallOptions options, TRequest request) + public abstract AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) where TRequest : class where TResponse : class; @@ -60,7 +60,7 @@ namespace Grpc.Core /// Invokes a server streaming call asynchronously. /// In server streaming scenario, client sends on request and server responds with a stream of responses. /// - public abstract AsyncServerStreamingCall AsyncServerStreamingCall(Method method, CallOptions options, TRequest request) + public abstract AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) where TRequest : class where TResponse : class; @@ -68,7 +68,7 @@ namespace Grpc.Core /// Invokes a client streaming call asynchronously. /// In client streaming scenario, client sends a stream of requests and server responds with a single response. /// - public abstract AsyncClientStreamingCall AsyncClientStreamingCall(Method method, CallOptions options) + public abstract AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) where TRequest : class where TResponse : class; @@ -77,7 +77,7 @@ namespace Grpc.Core /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. /// The response stream is completely independent and both side can be sending messages at the same time. /// - public abstract AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, CallOptions options) + public abstract AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) where TRequest : class where TResponse : class; } diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index f5d6ae744f..9f3c4a5327 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -124,11 +124,11 @@ namespace Grpc.Core /// By default, this will be set to null with the meaning /// "use default host". /// - public string Host - { - get; - set; - } + //public string Host + //{ + // get; + // set; + //} /// /// Creates a new call to given method. diff --git a/src/csharp/Grpc.Core/DefaultCallInvoker.cs b/src/csharp/Grpc.Core/DefaultCallInvoker.cs index 8b77651c0c..5329478a15 100644 --- a/src/csharp/Grpc.Core/DefaultCallInvoker.cs +++ b/src/csharp/Grpc.Core/DefaultCallInvoker.cs @@ -56,18 +56,18 @@ namespace Grpc.Core /// /// Invokes a simple remote call in a blocking fashion. /// - public override TResponse BlockingUnaryCall(Method method, CallOptions options, TRequest request) + public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) { - var call = CreateCall(method, options); + var call = CreateCall(method, host, options); return Calls.BlockingUnaryCall(call, request); } /// /// Invokes a simple remote call asynchronously. /// - public override AsyncUnaryCall AsyncUnaryCall(Method method, CallOptions options, TRequest request) + public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) { - var call = CreateCall(method, options); + var call = CreateCall(method, host, options); return Calls.AsyncUnaryCall(call, request); } @@ -75,9 +75,9 @@ namespace Grpc.Core /// Invokes a server streaming call asynchronously. /// In server streaming scenario, client sends on request and server responds with a stream of responses. /// - public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, CallOptions options, TRequest request) + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) { - var call = CreateCall(method, options); + var call = CreateCall(method, host, options); return Calls.AsyncServerStreamingCall(call, request); } @@ -85,9 +85,9 @@ namespace Grpc.Core /// Invokes a client streaming call asynchronously. /// In client streaming scenario, client sends a stream of requests and server responds with a single response. /// - public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, CallOptions options) + public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) { - var call = CreateCall(method, options); + var call = CreateCall(method, host, options); return Calls.AsyncClientStreamingCall(call); } @@ -96,22 +96,17 @@ namespace Grpc.Core /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. /// The response stream is completely independent and both side can be sending messages at the same time. /// - public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, CallOptions options) + public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) { - var call = CreateCall(method, options); + var call = CreateCall(method, host, options); return Calls.AsyncDuplexStreamingCall(call); } - protected virtual string Host - { - get { return null; } - } - - protected virtual CallInvocationDetails CreateCall(Method method, CallOptions options) + protected virtual CallInvocationDetails CreateCall(Method method, string host, CallOptions options) where TRequest : class where TResponse : class { - return new CallInvocationDetails(channel, method, Host, options); + return new CallInvocationDetails(channel, method, host, options); } } } -- cgit v1.2.3 From c831a4443d9b50a128625c14dba944d78129cf80 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 22 Mar 2016 17:23:55 -0700 Subject: add ClientBase.WithHost and get rid of HeaderInterceptor --- src/csharp/Grpc.Core/ClientBase.cs | 69 ++--------- src/csharp/Grpc.Core/DefaultCallInvoker.cs | 2 +- src/csharp/Grpc.Core/Grpc.Core.csproj | 1 + src/csharp/Grpc.Core/InterceptingCallInvoker.cs | 136 +++++++++++++++++++++ .../Grpc.IntegrationTesting.csproj | 1 - src/csharp/tests.json | 1 - 6 files changed, 151 insertions(+), 59 deletions(-) create mode 100644 src/csharp/Grpc.Core/InterceptingCallInvoker.cs (limited to 'src') diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index 9f3c4a5327..98db9b8a6f 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -38,14 +38,6 @@ using Grpc.Core.Utils; namespace Grpc.Core { - /// - /// Interceptor for call headers. - /// - /// Header interceptor is no longer the recommended way to perform authentication. - /// For header (initial metadata) based auth such as OAuth2 or JWT access token, use . - /// - public delegate void HeaderInterceptor(IMethod method, Metadata metadata); - /// /// Generic base class for client-side stubs. /// @@ -68,6 +60,19 @@ namespace Grpc.Core { } + /// + /// Creates a new client that sets host field for calls explicitly. + /// gRPC supports multiple "hosts" being served by a single server. + /// By default (if a client was not created by calling this method), + /// host null with the meaning "use default host" is used. + /// + public T WithHost(string host) + { + GrpcPreconditions.CheckNotNull(host, "host"); + var decoratedInvoker = new InterceptingCallInvoker(CallInvoker, hostInterceptor: (h) => host); + return NewInstance(decoratedInvoker); + } + /// /// Creates a new instance of client from given CallInvoker. /// @@ -105,53 +110,5 @@ namespace Grpc.Core { get { return this.callInvoker; } } - - /// - /// Can be used to register a custom header interceptor. - /// The interceptor is invoked each time a new call on this client is started. - /// It is not recommented to use header interceptor to add auth headers to RPC calls. - /// - /// - public HeaderInterceptor HeaderInterceptor - { - get; - set; - } - - /// - /// gRPC supports multiple "hosts" being served by a single server. - /// This property can be used to set the target host explicitly. - /// By default, this will be set to null with the meaning - /// "use default host". - /// - //public string Host - //{ - // get; - // set; - //} - - /// - /// Creates a new call to given method. - /// - /// The method to invoke. - /// The call options. - /// Request message type. - /// Response message type. - /// The call invocation details. - //protected CallInvocationDetails CreateCall(Method method, CallOptions options) - // where TRequest : class - // where TResponse : class - //{ - // var interceptor = HeaderInterceptor; - // if (interceptor != null) - // { - // if (options.Headers == null) - // { - // options = options.WithHeaders(new Metadata()); - // } - // interceptor(method, options.Headers); - // } - // return new CallInvocationDetails(channel, method, Host, options); - //} } } diff --git a/src/csharp/Grpc.Core/DefaultCallInvoker.cs b/src/csharp/Grpc.Core/DefaultCallInvoker.cs index 5329478a15..912cbaa604 100644 --- a/src/csharp/Grpc.Core/DefaultCallInvoker.cs +++ b/src/csharp/Grpc.Core/DefaultCallInvoker.cs @@ -75,7 +75,7 @@ namespace Grpc.Core /// Invokes a server streaming call asynchronously. /// In server streaming scenario, client sends on request and server responds with a stream of responses. /// - public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) { var call = CreateCall(method, host, options); return Calls.AsyncServerStreamingCall(call, request); diff --git a/src/csharp/Grpc.Core/Grpc.Core.csproj b/src/csharp/Grpc.Core/Grpc.Core.csproj index d8c04b3adb..1d3b01a534 100644 --- a/src/csharp/Grpc.Core/Grpc.Core.csproj +++ b/src/csharp/Grpc.Core/Grpc.Core.csproj @@ -131,6 +131,7 @@ + diff --git a/src/csharp/Grpc.Core/InterceptingCallInvoker.cs b/src/csharp/Grpc.Core/InterceptingCallInvoker.cs new file mode 100644 index 0000000000..6b64540f2d --- /dev/null +++ b/src/csharp/Grpc.Core/InterceptingCallInvoker.cs @@ -0,0 +1,136 @@ +#region Copyright notice and license + +// Copyright 2015, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Threading.Tasks; +using Grpc.Core.Internal; +using Grpc.Core.Utils; + +namespace Grpc.Core +{ + /// + /// Decorates an underlying CallInvoker to intercept call invocations. + /// + internal class InterceptingCallInvoker : CallInvoker + { + readonly CallInvoker callInvoker; + readonly Func hostInterceptor; + readonly Func callOptionsInterceptor; + + /// + /// Initializes a new instance of the class. + /// + /// CallInvoker to decorate. + public InterceptingCallInvoker(CallInvoker callInvoker, + Func hostInterceptor = null, + Func callOptionsInterceptor = null) + { + this.callInvoker = GrpcPreconditions.CheckNotNull(callInvoker); + this.hostInterceptor = hostInterceptor; + this.callOptionsInterceptor = callOptionsInterceptor; + } + + /// + /// Intercepts a unary call. + /// + public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.BlockingUnaryCall(method, host, options, request); + } + + /// + /// Invokes a simple remote call asynchronously. + /// + public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncUnaryCall(method, host, options, request); + } + + /// + /// Invokes a server streaming call asynchronously. + /// In server streaming scenario, client sends on request and server responds with a stream of responses. + /// + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncServerStreamingCall(method, host, options, request); + } + + /// + /// Invokes a client streaming call asynchronously. + /// In client streaming scenario, client sends a stream of requests and server responds with a single response. + /// + public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncClientStreamingCall(method, host, options); + } + + /// + /// Invokes a duplex streaming call asynchronously. + /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. + /// The response stream is completely independent and both side can be sending messages at the same time. + /// + public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncDuplexStreamingCall(method, host, options); + } + + private string InterceptHost(string host) + { + // only set host if not already set to support composing interceptors. + if (hostInterceptor == null || host != null) + { + return host; + } + return hostInterceptor(host); + } + + private CallOptions InterceptCallOptions(CallOptions options) + { + if (callOptionsInterceptor == null) + { + return options; + } + return callOptionsInterceptor(options); + } + } +} diff --git a/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj b/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj index d3c572fe27..c6a9e73c10 100644 --- a/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj +++ b/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj @@ -84,7 +84,6 @@ Version.cs - diff --git a/src/csharp/tests.json b/src/csharp/tests.json index 4aa93668ad..0fe8bc6e6f 100644 --- a/src/csharp/tests.json +++ b/src/csharp/tests.json @@ -35,7 +35,6 @@ "Math.Tests.MathClientServerTest", "Grpc.HealthCheck.Tests.HealthClientServerTest", "Grpc.HealthCheck.Tests.HealthServiceImplTest", - "Grpc.IntegrationTesting.HeaderInterceptorTest", "Grpc.IntegrationTesting.HistogramTest", "Grpc.IntegrationTesting.InteropClientServerTest", "Grpc.IntegrationTesting.MetadataCredentialsTest", -- cgit v1.2.3 From b24035866e904b5e6d10b794dacde7b786fe42aa Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Wed, 23 Mar 2016 07:40:28 -0700 Subject: add parameterless constructor for ClientBase --- src/csharp/Grpc.Core/ClientBase.cs | 22 ++++++- src/csharp/Grpc.Core/Grpc.Core.csproj | 1 + src/csharp/Grpc.Core/UnimplementedCallInvoker.cs | 75 ++++++++++++++++++++++++ 3 files changed, 97 insertions(+), 1 deletion(-) create mode 100644 src/csharp/Grpc.Core/UnimplementedCallInvoker.cs (limited to 'src') diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index 98db9b8a6f..265e6c5c07 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -42,8 +42,18 @@ namespace Grpc.Core /// Generic base class for client-side stubs. /// public abstract class ClientBase : ClientBase - where T : ClientBase + where T : ClientBase { + /// + /// Initializes a new instance of ClientBase class that + /// throws NotImplementedException upon invocation of any RPC. + /// This constructor is only provided to allow creation of test doubles + /// for client classes (e.g. mocking requires a parameterless constructor). + /// + protected ClientBase() : base() + { + } + /// /// Initializes a new instance of ClientBase class. /// @@ -86,6 +96,16 @@ namespace Grpc.Core { readonly CallInvoker callInvoker; + /// + /// Initializes a new instance of ClientBase class that + /// throws NotImplementedException upon invocation of any RPC. + /// This constructor is only provided to allow creation of test doubles + /// for client classes (e.g. mocking requires a parameterless constructor). + /// + protected ClientBase() : this(new UnimplementedCallInvoker()) + { + } + /// /// Initializes a new instance of ClientBase class. /// diff --git a/src/csharp/Grpc.Core/Grpc.Core.csproj b/src/csharp/Grpc.Core/Grpc.Core.csproj index 1d3b01a534..7d950bd978 100644 --- a/src/csharp/Grpc.Core/Grpc.Core.csproj +++ b/src/csharp/Grpc.Core/Grpc.Core.csproj @@ -132,6 +132,7 @@ + diff --git a/src/csharp/Grpc.Core/UnimplementedCallInvoker.cs b/src/csharp/Grpc.Core/UnimplementedCallInvoker.cs new file mode 100644 index 0000000000..7f046cbca9 --- /dev/null +++ b/src/csharp/Grpc.Core/UnimplementedCallInvoker.cs @@ -0,0 +1,75 @@ +#region Copyright notice and license + +// Copyright 2015, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Threading.Tasks; +using Grpc.Core.Internal; +using Grpc.Core.Utils; + +namespace Grpc.Core +{ + /// + /// Call invoker that throws NotImplementedException for all requests. + /// + internal class UnimplementedCallInvoker : CallInvoker + { + public UnimplementedCallInvoker() + { + } + + public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + throw new NotImplementedException(); + } + + public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + throw new NotImplementedException(); + } + + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) + { + throw new NotImplementedException(); + } + + public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) + { + throw new NotImplementedException(); + } + + public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) + { + throw new NotImplementedException(); + } + } +} -- cgit v1.2.3 From efb77848800ca23d64bc5f295ac70bf16cf03ca1 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Wed, 23 Mar 2016 07:47:36 -0700 Subject: update codegen to generate parameterless constructor for clients --- src/compiler/csharp_generator.cc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index 4a96a909de..1343233423 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -362,6 +362,12 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Print("public $name$(CallInvoker callInvoker) : base(callInvoker)\n", "name", GetClientClassName(service)); out->Print("{\n"); + out->Print("}\n"); + out->Print("///Parameterless constructor to allow creation" + " of test doubles.\n"); + out->Print("protected $name$() : base()\n", + "name", GetClientClassName(service)); + out->Print("{\n"); out->Print("}\n\n"); for (int i = 0; i < service->method_count(); i++) { -- cgit v1.2.3 From 054fae7e9d44414a1f27ea0dd6cbba237f735adf Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Wed, 23 Mar 2016 07:54:50 -0700 Subject: move implementations of CallInvoker to Grpc.Core.Internal --- src/csharp/Grpc.Core/ClientBase.cs | 1 + src/csharp/Grpc.Core/Grpc.Core.csproj | 4 +- src/csharp/Grpc.Core/InterceptingCallInvoker.cs | 136 --------------------- .../Grpc.Core/Internal/InterceptingCallInvoker.cs | 136 +++++++++++++++++++++ .../Grpc.Core/Internal/UnimplementedCallInvoker.cs | 75 ++++++++++++ src/csharp/Grpc.Core/UnimplementedCallInvoker.cs | 75 ------------ 6 files changed, 214 insertions(+), 213 deletions(-) delete mode 100644 src/csharp/Grpc.Core/InterceptingCallInvoker.cs create mode 100644 src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs create mode 100644 src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs delete mode 100644 src/csharp/Grpc.Core/UnimplementedCallInvoker.cs (limited to 'src') diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index 265e6c5c07..b21d01c5e2 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -34,6 +34,7 @@ using System; using System.Text.RegularExpressions; using System.Threading.Tasks; +using Grpc.Core.Internal; using Grpc.Core.Utils; namespace Grpc.Core diff --git a/src/csharp/Grpc.Core/Grpc.Core.csproj b/src/csharp/Grpc.Core/Grpc.Core.csproj index 7d950bd978..251a688946 100644 --- a/src/csharp/Grpc.Core/Grpc.Core.csproj +++ b/src/csharp/Grpc.Core/Grpc.Core.csproj @@ -131,8 +131,8 @@ - - + + diff --git a/src/csharp/Grpc.Core/InterceptingCallInvoker.cs b/src/csharp/Grpc.Core/InterceptingCallInvoker.cs deleted file mode 100644 index 6b64540f2d..0000000000 --- a/src/csharp/Grpc.Core/InterceptingCallInvoker.cs +++ /dev/null @@ -1,136 +0,0 @@ -#region Copyright notice and license - -// Copyright 2015, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -#endregion - -using System; -using System.Threading.Tasks; -using Grpc.Core.Internal; -using Grpc.Core.Utils; - -namespace Grpc.Core -{ - /// - /// Decorates an underlying CallInvoker to intercept call invocations. - /// - internal class InterceptingCallInvoker : CallInvoker - { - readonly CallInvoker callInvoker; - readonly Func hostInterceptor; - readonly Func callOptionsInterceptor; - - /// - /// Initializes a new instance of the class. - /// - /// CallInvoker to decorate. - public InterceptingCallInvoker(CallInvoker callInvoker, - Func hostInterceptor = null, - Func callOptionsInterceptor = null) - { - this.callInvoker = GrpcPreconditions.CheckNotNull(callInvoker); - this.hostInterceptor = hostInterceptor; - this.callOptionsInterceptor = callOptionsInterceptor; - } - - /// - /// Intercepts a unary call. - /// - public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) - { - host = InterceptHost(host); - options = InterceptCallOptions(options); - return callInvoker.BlockingUnaryCall(method, host, options, request); - } - - /// - /// Invokes a simple remote call asynchronously. - /// - public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) - { - host = InterceptHost(host); - options = InterceptCallOptions(options); - return callInvoker.AsyncUnaryCall(method, host, options, request); - } - - /// - /// Invokes a server streaming call asynchronously. - /// In server streaming scenario, client sends on request and server responds with a stream of responses. - /// - public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) - { - host = InterceptHost(host); - options = InterceptCallOptions(options); - return callInvoker.AsyncServerStreamingCall(method, host, options, request); - } - - /// - /// Invokes a client streaming call asynchronously. - /// In client streaming scenario, client sends a stream of requests and server responds with a single response. - /// - public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) - { - host = InterceptHost(host); - options = InterceptCallOptions(options); - return callInvoker.AsyncClientStreamingCall(method, host, options); - } - - /// - /// Invokes a duplex streaming call asynchronously. - /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. - /// The response stream is completely independent and both side can be sending messages at the same time. - /// - public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) - { - host = InterceptHost(host); - options = InterceptCallOptions(options); - return callInvoker.AsyncDuplexStreamingCall(method, host, options); - } - - private string InterceptHost(string host) - { - // only set host if not already set to support composing interceptors. - if (hostInterceptor == null || host != null) - { - return host; - } - return hostInterceptor(host); - } - - private CallOptions InterceptCallOptions(CallOptions options) - { - if (callOptionsInterceptor == null) - { - return options; - } - return callOptionsInterceptor(options); - } - } -} diff --git a/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs b/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs new file mode 100644 index 0000000000..1b8c54a6da --- /dev/null +++ b/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs @@ -0,0 +1,136 @@ +#region Copyright notice and license + +// Copyright 2015, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Threading.Tasks; +using Grpc.Core; +using Grpc.Core.Utils; + +namespace Grpc.Core.Internal +{ + /// + /// Decorates an underlying CallInvoker to intercept call invocations. + /// + internal class InterceptingCallInvoker : CallInvoker + { + readonly CallInvoker callInvoker; + readonly Func hostInterceptor; + readonly Func callOptionsInterceptor; + + /// + /// Initializes a new instance of the class. + /// + /// CallInvoker to decorate. + public InterceptingCallInvoker(CallInvoker callInvoker, + Func hostInterceptor = null, + Func callOptionsInterceptor = null) + { + this.callInvoker = GrpcPreconditions.CheckNotNull(callInvoker); + this.hostInterceptor = hostInterceptor; + this.callOptionsInterceptor = callOptionsInterceptor; + } + + /// + /// Intercepts a unary call. + /// + public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.BlockingUnaryCall(method, host, options, request); + } + + /// + /// Invokes a simple remote call asynchronously. + /// + public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncUnaryCall(method, host, options, request); + } + + /// + /// Invokes a server streaming call asynchronously. + /// In server streaming scenario, client sends on request and server responds with a stream of responses. + /// + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncServerStreamingCall(method, host, options, request); + } + + /// + /// Invokes a client streaming call asynchronously. + /// In client streaming scenario, client sends a stream of requests and server responds with a single response. + /// + public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncClientStreamingCall(method, host, options); + } + + /// + /// Invokes a duplex streaming call asynchronously. + /// In duplex streaming scenario, client sends a stream of requests and server responds with a stream of responses. + /// The response stream is completely independent and both side can be sending messages at the same time. + /// + public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) + { + host = InterceptHost(host); + options = InterceptCallOptions(options); + return callInvoker.AsyncDuplexStreamingCall(method, host, options); + } + + private string InterceptHost(string host) + { + // only set host if not already set to support composing interceptors. + if (hostInterceptor == null || host != null) + { + return host; + } + return hostInterceptor(host); + } + + private CallOptions InterceptCallOptions(CallOptions options) + { + if (callOptionsInterceptor == null) + { + return options; + } + return callOptionsInterceptor(options); + } + } +} diff --git a/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs b/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs new file mode 100644 index 0000000000..c8f2a1ee7e --- /dev/null +++ b/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs @@ -0,0 +1,75 @@ +#region Copyright notice and license + +// Copyright 2015, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Threading.Tasks; +using Grpc.Core; +using Grpc.Core.Utils; + +namespace Grpc.Core.Internal +{ + /// + /// Call invoker that throws NotImplementedException for all requests. + /// + internal class UnimplementedCallInvoker : CallInvoker + { + public UnimplementedCallInvoker() + { + } + + public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + throw new NotImplementedException(); + } + + public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) + { + throw new NotImplementedException(); + } + + public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) + { + throw new NotImplementedException(); + } + + public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) + { + throw new NotImplementedException(); + } + + public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) + { + throw new NotImplementedException(); + } + } +} diff --git a/src/csharp/Grpc.Core/UnimplementedCallInvoker.cs b/src/csharp/Grpc.Core/UnimplementedCallInvoker.cs deleted file mode 100644 index 7f046cbca9..0000000000 --- a/src/csharp/Grpc.Core/UnimplementedCallInvoker.cs +++ /dev/null @@ -1,75 +0,0 @@ -#region Copyright notice and license - -// Copyright 2015, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -#endregion - -using System; -using System.Threading.Tasks; -using Grpc.Core.Internal; -using Grpc.Core.Utils; - -namespace Grpc.Core -{ - /// - /// Call invoker that throws NotImplementedException for all requests. - /// - internal class UnimplementedCallInvoker : CallInvoker - { - public UnimplementedCallInvoker() - { - } - - public override TResponse BlockingUnaryCall(Method method, string host, CallOptions options, TRequest request) - { - throw new NotImplementedException(); - } - - public override AsyncUnaryCall AsyncUnaryCall(Method method, string host, CallOptions options, TRequest request) - { - throw new NotImplementedException(); - } - - public override AsyncServerStreamingCall AsyncServerStreamingCall(Method method, string host, CallOptions options, TRequest request) - { - throw new NotImplementedException(); - } - - public override AsyncClientStreamingCall AsyncClientStreamingCall(Method method, string host, CallOptions options) - { - throw new NotImplementedException(); - } - - public override AsyncDuplexStreamingCall AsyncDuplexStreamingCall(Method method, string host, CallOptions options) - { - throw new NotImplementedException(); - } - } -} -- cgit v1.2.3 From 2f0a837819a594db1397aff69f51323e948d2aba Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Wed, 23 Mar 2016 09:16:49 -0700 Subject: introduce concept of opaque client base configuration --- src/compiler/csharp_generator.cc | 13 +++- src/csharp/Grpc.Core/ClientBase.cs | 71 +++++++++++++++++++--- .../Grpc.Core/Internal/InterceptingCallInvoker.cs | 4 +- 3 files changed, 72 insertions(+), 16 deletions(-) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index 1343233423..a83290af12 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -363,11 +363,18 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { "name", GetClientClassName(service)); out->Print("{\n"); out->Print("}\n"); - out->Print("///Parameterless constructor to allow creation" + out->Print("///Protected parameterless constructor to allow creation" " of test doubles.\n"); out->Print("protected $name$() : base()\n", "name", GetClientClassName(service)); out->Print("{\n"); + out->Print("}\n"); + out->Print("///Protected constructor to allow creation of configured" + " clients.\n"); + out->Print("protected $name$(ClientBaseConfiguration configuration)" + " : base(configuration)\n", + "name", GetClientClassName(service)); + out->Print("{\n"); out->Print("}\n\n"); for (int i = 0; i < service->method_count(); i++) { @@ -452,11 +459,11 @@ void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { } // override NewInstance method - out->Print("protected override $name$ NewInstance(CallInvoker callInvoker)\n", + out->Print("protected override $name$ NewInstance(ClientBaseConfiguration configuration)\n", "name", GetClientClassName(service)); out->Print("{\n"); out->Indent(); - out->Print("return new $name$(callInvoker);\n", + out->Print("return new $name$(configuration);\n", "name", GetClientClassName(service)); out->Outdent(); out->Print("}\n"); diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index b21d01c5e2..e2e47893cc 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -31,9 +31,6 @@ #endregion -using System; -using System.Text.RegularExpressions; -using System.Threading.Tasks; using Grpc.Core.Internal; using Grpc.Core.Utils; @@ -55,6 +52,14 @@ namespace Grpc.Core { } + /// + /// Initializes a new instance of ClientBase class. + /// + /// The configuration. + protected ClientBase(ClientBaseConfiguration configuration) : base(configuration) + { + } + /// /// Initializes a new instance of ClientBase class. /// @@ -79,15 +84,14 @@ namespace Grpc.Core /// public T WithHost(string host) { - GrpcPreconditions.CheckNotNull(host, "host"); - var decoratedInvoker = new InterceptingCallInvoker(CallInvoker, hostInterceptor: (h) => host); - return NewInstance(decoratedInvoker); + var newConfiguration = this.Configuration.WithHost(host); + return NewInstance(newConfiguration); } /// - /// Creates a new instance of client from given CallInvoker. + /// Creates a new instance of client from given ClientBaseConfiguration. /// - protected abstract T NewInstance(CallInvoker callInvoker); + protected abstract T NewInstance(ClientBaseConfiguration configuration); } /// @@ -95,6 +99,7 @@ namespace Grpc.Core /// public abstract class ClientBase { + readonly ClientBaseConfiguration configuration; readonly CallInvoker callInvoker; /// @@ -107,6 +112,16 @@ namespace Grpc.Core { } + /// + /// Initializes a new instance of ClientBase class. + /// + /// The configuration. + protected ClientBase(ClientBaseConfiguration configuration) + { + this.configuration = GrpcPreconditions.CheckNotNull(configuration, "configuration"); + this.callInvoker = configuration.CreateDecoratedCallInvoker(); + } + /// /// Initializes a new instance of ClientBase class. /// @@ -119,9 +134,8 @@ namespace Grpc.Core /// Initializes a new instance of ClientBase class. /// /// The CallInvoker for remote call invocation. - public ClientBase(CallInvoker callInvoker) + public ClientBase(CallInvoker callInvoker) : this(new ClientBaseConfiguration(callInvoker, null)) { - this.callInvoker = GrpcPreconditions.CheckNotNull(callInvoker); } /// @@ -131,5 +145,42 @@ namespace Grpc.Core { get { return this.callInvoker; } } + + /// + /// Gets the configuration. + /// + internal ClientBaseConfiguration Configuration + { + get { return this.configuration; } + } + + /// + /// Represents configuration of ClientBase. The class itself is visible to + /// subclasses, but contents are marked as internal to make the instances opaque. + /// The verbose name of this class was chosen to make name clash in generated code + /// less likely. + /// + protected internal class ClientBaseConfiguration + { + readonly CallInvoker undecoratedCallInvoker; + readonly string host; + + internal ClientBaseConfiguration(CallInvoker undecoratedCallInvoker, string host) + { + this.undecoratedCallInvoker = GrpcPreconditions.CheckNotNull(undecoratedCallInvoker); + this.host = host; + } + + internal CallInvoker CreateDecoratedCallInvoker() + { + return new InterceptingCallInvoker(undecoratedCallInvoker, hostInterceptor: (h) => host); + } + + internal ClientBaseConfiguration WithHost(string host) + { + GrpcPreconditions.CheckNotNull(host, "host"); + return new ClientBaseConfiguration(this.undecoratedCallInvoker, host); + } + } } } diff --git a/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs b/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs index 1b8c54a6da..53569760ac 100644 --- a/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs +++ b/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs @@ -50,7 +50,6 @@ namespace Grpc.Core.Internal /// /// Initializes a new instance of the class. /// - /// CallInvoker to decorate. public InterceptingCallInvoker(CallInvoker callInvoker, Func hostInterceptor = null, Func callOptionsInterceptor = null) @@ -116,8 +115,7 @@ namespace Grpc.Core.Internal private string InterceptHost(string host) { - // only set host if not already set to support composing interceptors. - if (hostInterceptor == null || host != null) + if (hostInterceptor == null) { return host; } -- cgit v1.2.3 From 5a4e1e30eb16bbb5e37675de858015554e014847 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Fri, 25 Mar 2016 16:51:55 -0700 Subject: make client side interface obsolete --- src/compiler/csharp_generator.cc | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/compiler/csharp_generator.cc b/src/compiler/csharp_generator.cc index a83290af12..69e2738d53 100644 --- a/src/compiler/csharp_generator.cc +++ b/src/compiler/csharp_generator.cc @@ -250,6 +250,8 @@ void GenerateServiceDescriptorProperty(Printer* out, const ServiceDescriptor *se void GenerateClientInterface(Printer* out, const ServiceDescriptor *service) { out->Print("// client interface\n"); + out->Print("[System.Obsolete(\"Client side interfaced will be removed " + "in the next release. Use client class directly.\")]\n"); out->Print("public interface $name$\n", "name", GetClientInterfaceName(service)); out->Print("{\n"); @@ -349,8 +351,9 @@ void GenerateServerClass(Printer* out, const ServiceDescriptor *service) { void GenerateClientStub(Printer* out, const ServiceDescriptor *service) { out->Print("// client stub\n"); out->Print( - "public class $name$ : ClientBase<$name$>\n", - "name", GetClientClassName(service)); + "public class $name$ : ClientBase<$name$>, $interface$\n", + "name", GetClientClassName(service), + "interface", GetClientInterfaceName(service)); out->Print("{\n"); out->Indent(); @@ -536,7 +539,6 @@ void GenerateService(Printer* out, const ServiceDescriptor *service) { } GenerateServiceDescriptorProperty(out, service); GenerateClientInterface(out, service); - //GenerateClientBaseClass(out, service); GenerateServerInterface(out, service); GenerateServerClass(out, service); GenerateClientStub(out, service); -- cgit v1.2.3 From acb842c205dc8e2feecba7e150fa39071db7c894 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Fri, 25 Mar 2016 16:54:14 -0700 Subject: fix copyrights --- src/csharp/Grpc.Core/CallInvoker.cs | 2 +- src/csharp/Grpc.Core/ClientBase.cs | 2 +- src/csharp/Grpc.Core/DefaultCallInvoker.cs | 2 +- src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs | 2 +- src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs | 2 +- src/csharp/Grpc.Examples.MathClient/MathClient.cs | 2 +- src/csharp/Grpc.Examples/MathExamples.cs | 2 +- src/csharp/Grpc.IntegrationTesting/InteropClient.cs | 2 +- src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs | 2 +- src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Core/CallInvoker.cs b/src/csharp/Grpc.Core/CallInvoker.cs index cec5255692..39199b1fd5 100644 --- a/src/csharp/Grpc.Core/CallInvoker.cs +++ b/src/csharp/Grpc.Core/CallInvoker.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.Core/ClientBase.cs b/src/csharp/Grpc.Core/ClientBase.cs index e2e47893cc..5517233e3c 100644 --- a/src/csharp/Grpc.Core/ClientBase.cs +++ b/src/csharp/Grpc.Core/ClientBase.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.Core/DefaultCallInvoker.cs b/src/csharp/Grpc.Core/DefaultCallInvoker.cs index 912cbaa604..1a99e41153 100644 --- a/src/csharp/Grpc.Core/DefaultCallInvoker.cs +++ b/src/csharp/Grpc.Core/DefaultCallInvoker.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs b/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs index 53569760ac..ef48dc7121 100644 --- a/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs +++ b/src/csharp/Grpc.Core/Internal/InterceptingCallInvoker.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs b/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs index c8f2a1ee7e..0c7340873b 100644 --- a/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs +++ b/src/csharp/Grpc.Core/Internal/UnimplementedCallInvoker.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.Examples.MathClient/MathClient.cs b/src/csharp/Grpc.Examples.MathClient/MathClient.cs index 2f3ef85b4d..aadef6833d 100644 --- a/src/csharp/Grpc.Examples.MathClient/MathClient.cs +++ b/src/csharp/Grpc.Examples.MathClient/MathClient.cs @@ -1,5 +1,5 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.Examples/MathExamples.cs b/src/csharp/Grpc.Examples/MathExamples.cs index 95417d9034..6075420974 100644 --- a/src/csharp/Grpc.Examples/MathExamples.cs +++ b/src/csharp/Grpc.Examples/MathExamples.cs @@ -1,5 +1,5 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.IntegrationTesting/InteropClient.cs b/src/csharp/Grpc.IntegrationTesting/InteropClient.cs index ec001ffaa4..7ca5221936 100644 --- a/src/csharp/Grpc.IntegrationTesting/InteropClient.cs +++ b/src/csharp/Grpc.IntegrationTesting/InteropClient.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs b/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs index eb4079e3a5..f95af5008f 100644 --- a/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/MetadataCredentialsTest.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs b/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs index c7792f75f3..3df45b5f70 100644 --- a/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs +++ b/src/csharp/Grpc.IntegrationTesting/SslCredentialsTest.cs @@ -1,6 +1,6 @@ #region Copyright notice and license -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without -- cgit v1.2.3 From ddc4e346bc3a59cef38bdf3e79fb2f1940bb4df2 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 21 Mar 2016 19:03:14 -0700 Subject: regenerate code --- src/csharp/Grpc.Examples/MathGrpc.cs | 69 ++++---- src/csharp/Grpc.HealthCheck/HealthGrpc.cs | 39 ++-- src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs | 128 +++++++------ src/csharp/Grpc.IntegrationTesting/TestGrpc.cs | 197 ++++++++++++--------- 4 files changed, 246 insertions(+), 187 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.Examples/MathGrpc.cs b/src/csharp/Grpc.Examples/MathGrpc.cs index ba237ddfd2..f3bb0d1cdc 100644 --- a/src/csharp/Grpc.Examples/MathGrpc.cs +++ b/src/csharp/Grpc.Examples/MathGrpc.cs @@ -52,6 +52,7 @@ namespace Math { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface IMathClient { global::Math.DivReply Div(global::Math.DivArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -102,60 +103,66 @@ namespace Math { } // client stub - public class MathClient : ClientBase, IMathClient + public class MathClient : ClientBase, IMathClient { public MathClient(Channel channel) : base(channel) { } - public global::Math.DivReply Div(global::Math.DivArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public MathClient(CallInvoker callInvoker) : base(callInvoker) { - var call = CreateCall(__Method_Div, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); } - public global::Math.DivReply Div(global::Math.DivArgs request, CallOptions options) + ///Protected parameterless constructor to allow creation of test doubles. + protected MathClient() : base() { - var call = CreateCall(__Method_Div, options); - return Calls.BlockingUnaryCall(call, request); } - public AsyncUnaryCall DivAsync(global::Math.DivArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + ///Protected constructor to allow creation of configured clients. + protected MathClient(ClientBaseConfiguration configuration) : base(configuration) { - var call = CreateCall(__Method_Div, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); } - public AsyncUnaryCall DivAsync(global::Math.DivArgs request, CallOptions options) + + public virtual global::Math.DivReply Div(global::Math.DivArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return Div(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual global::Math.DivReply Div(global::Math.DivArgs request, CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_Div, null, options, request); + } + public virtual AsyncUnaryCall DivAsync(global::Math.DivArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return DivAsync(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual AsyncUnaryCall DivAsync(global::Math.DivArgs request, CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_Div, null, options, request); + } + public virtual AsyncDuplexStreamingCall DivMany(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_Div, options); - return Calls.AsyncUnaryCall(call, request); + return DivMany(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncDuplexStreamingCall DivMany(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncDuplexStreamingCall DivMany(CallOptions options) { - var call = CreateCall(__Method_DivMany, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncDuplexStreamingCall(call); + return CallInvoker.AsyncDuplexStreamingCall(__Method_DivMany, null, options); } - public AsyncDuplexStreamingCall DivMany(CallOptions options) + public virtual AsyncServerStreamingCall Fib(global::Math.FibArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_DivMany, options); - return Calls.AsyncDuplexStreamingCall(call); + return Fib(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncServerStreamingCall Fib(global::Math.FibArgs request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncServerStreamingCall Fib(global::Math.FibArgs request, CallOptions options) { - var call = CreateCall(__Method_Fib, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncServerStreamingCall(call, request); + return CallInvoker.AsyncServerStreamingCall(__Method_Fib, null, options, request); } - public AsyncServerStreamingCall Fib(global::Math.FibArgs request, CallOptions options) + public virtual AsyncClientStreamingCall Sum(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_Fib, options); - return Calls.AsyncServerStreamingCall(call, request); + return Sum(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncClientStreamingCall Sum(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncClientStreamingCall Sum(CallOptions options) { - var call = CreateCall(__Method_Sum, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncClientStreamingCall(call); + return CallInvoker.AsyncClientStreamingCall(__Method_Sum, null, options); } - public AsyncClientStreamingCall Sum(CallOptions options) + protected override MathClient NewInstance(ClientBaseConfiguration configuration) { - var call = CreateCall(__Method_Sum, options); - return Calls.AsyncClientStreamingCall(call); + return new MathClient(configuration); } } diff --git a/src/csharp/Grpc.HealthCheck/HealthGrpc.cs b/src/csharp/Grpc.HealthCheck/HealthGrpc.cs index fffdf03be4..72e11cca3a 100644 --- a/src/csharp/Grpc.HealthCheck/HealthGrpc.cs +++ b/src/csharp/Grpc.HealthCheck/HealthGrpc.cs @@ -29,6 +29,7 @@ namespace Grpc.Health.V1 { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface IHealthClient { global::Grpc.Health.V1.HealthCheckResponse Check(global::Grpc.Health.V1.HealthCheckRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -55,30 +56,42 @@ namespace Grpc.Health.V1 { } // client stub - public class HealthClient : ClientBase, IHealthClient + public class HealthClient : ClientBase, IHealthClient { public HealthClient(Channel channel) : base(channel) { } - public global::Grpc.Health.V1.HealthCheckResponse Check(global::Grpc.Health.V1.HealthCheckRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public HealthClient(CallInvoker callInvoker) : base(callInvoker) { - var call = CreateCall(__Method_Check, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); } - public global::Grpc.Health.V1.HealthCheckResponse Check(global::Grpc.Health.V1.HealthCheckRequest request, CallOptions options) + ///Protected parameterless constructor to allow creation of test doubles. + protected HealthClient() : base() { - var call = CreateCall(__Method_Check, options); - return Calls.BlockingUnaryCall(call, request); } - public AsyncUnaryCall CheckAsync(global::Grpc.Health.V1.HealthCheckRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + ///Protected constructor to allow creation of configured clients. + protected HealthClient(ClientBaseConfiguration configuration) : base(configuration) { - var call = CreateCall(__Method_Check, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); } - public AsyncUnaryCall CheckAsync(global::Grpc.Health.V1.HealthCheckRequest request, CallOptions options) + + public virtual global::Grpc.Health.V1.HealthCheckResponse Check(global::Grpc.Health.V1.HealthCheckRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return Check(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual global::Grpc.Health.V1.HealthCheckResponse Check(global::Grpc.Health.V1.HealthCheckRequest request, CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_Check, null, options, request); + } + public virtual AsyncUnaryCall CheckAsync(global::Grpc.Health.V1.HealthCheckRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return CheckAsync(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual AsyncUnaryCall CheckAsync(global::Grpc.Health.V1.HealthCheckRequest request, CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_Check, null, options, request); + } + protected override HealthClient NewInstance(ClientBaseConfiguration configuration) { - var call = CreateCall(__Method_Check, options); - return Calls.AsyncUnaryCall(call, request); + return new HealthClient(configuration); } } diff --git a/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs b/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs index beffa2298d..46b16cf202 100644 --- a/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs +++ b/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs @@ -36,6 +36,7 @@ namespace Grpc.Testing { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface IBenchmarkServiceClient { global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -70,40 +71,50 @@ namespace Grpc.Testing { } // client stub - public class BenchmarkServiceClient : ClientBase, IBenchmarkServiceClient + public class BenchmarkServiceClient : ClientBase, IBenchmarkServiceClient { public BenchmarkServiceClient(Channel channel) : base(channel) { } - public global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public BenchmarkServiceClient(CallInvoker callInvoker) : base(callInvoker) { - var call = CreateCall(__Method_UnaryCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); } - public global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, CallOptions options) + ///Protected parameterless constructor to allow creation of test doubles. + protected BenchmarkServiceClient() : base() { - var call = CreateCall(__Method_UnaryCall, options); - return Calls.BlockingUnaryCall(call, request); } - public AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + ///Protected constructor to allow creation of configured clients. + protected BenchmarkServiceClient(ClientBaseConfiguration configuration) : base(configuration) { - var call = CreateCall(__Method_UnaryCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); } - public AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, CallOptions options) + + public virtual global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return UnaryCall(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_UnaryCall, null, options, request); + } + public virtual AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return UnaryCallAsync(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_UnaryCall, null, options, request); + } + public virtual AsyncDuplexStreamingCall StreamingCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_UnaryCall, options); - return Calls.AsyncUnaryCall(call, request); + return StreamingCall(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncDuplexStreamingCall StreamingCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncDuplexStreamingCall StreamingCall(CallOptions options) { - var call = CreateCall(__Method_StreamingCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncDuplexStreamingCall(call); + return CallInvoker.AsyncDuplexStreamingCall(__Method_StreamingCall, null, options); } - public AsyncDuplexStreamingCall StreamingCall(CallOptions options) + protected override BenchmarkServiceClient NewInstance(ClientBaseConfiguration configuration) { - var call = CreateCall(__Method_StreamingCall, options); - return Calls.AsyncDuplexStreamingCall(call); + return new BenchmarkServiceClient(configuration); } } @@ -177,6 +188,7 @@ namespace Grpc.Testing { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface IWorkerServiceClient { AsyncDuplexStreamingCall RunServer(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -229,70 +241,74 @@ namespace Grpc.Testing { } // client stub - public class WorkerServiceClient : ClientBase, IWorkerServiceClient + public class WorkerServiceClient : ClientBase, IWorkerServiceClient { public WorkerServiceClient(Channel channel) : base(channel) { } - public AsyncDuplexStreamingCall RunServer(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public WorkerServiceClient(CallInvoker callInvoker) : base(callInvoker) + { + } + ///Protected parameterless constructor to allow creation of test doubles. + protected WorkerServiceClient() : base() + { + } + ///Protected constructor to allow creation of configured clients. + protected WorkerServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + public virtual AsyncDuplexStreamingCall RunServer(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return RunServer(new CallOptions(headers, deadline, cancellationToken)); + } + public virtual AsyncDuplexStreamingCall RunServer(CallOptions options) { - var call = CreateCall(__Method_RunServer, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncDuplexStreamingCall(call); + return CallInvoker.AsyncDuplexStreamingCall(__Method_RunServer, null, options); } - public AsyncDuplexStreamingCall RunServer(CallOptions options) + public virtual AsyncDuplexStreamingCall RunClient(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_RunServer, options); - return Calls.AsyncDuplexStreamingCall(call); + return RunClient(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncDuplexStreamingCall RunClient(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncDuplexStreamingCall RunClient(CallOptions options) { - var call = CreateCall(__Method_RunClient, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncDuplexStreamingCall(call); + return CallInvoker.AsyncDuplexStreamingCall(__Method_RunClient, null, options); } - public AsyncDuplexStreamingCall RunClient(CallOptions options) + public virtual global::Grpc.Testing.CoreResponse CoreCount(global::Grpc.Testing.CoreRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_RunClient, options); - return Calls.AsyncDuplexStreamingCall(call); + return CoreCount(request, new CallOptions(headers, deadline, cancellationToken)); } - public global::Grpc.Testing.CoreResponse CoreCount(global::Grpc.Testing.CoreRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual global::Grpc.Testing.CoreResponse CoreCount(global::Grpc.Testing.CoreRequest request, CallOptions options) { - var call = CreateCall(__Method_CoreCount, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); + return CallInvoker.BlockingUnaryCall(__Method_CoreCount, null, options, request); } - public global::Grpc.Testing.CoreResponse CoreCount(global::Grpc.Testing.CoreRequest request, CallOptions options) + public virtual AsyncUnaryCall CoreCountAsync(global::Grpc.Testing.CoreRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_CoreCount, options); - return Calls.BlockingUnaryCall(call, request); + return CoreCountAsync(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncUnaryCall CoreCountAsync(global::Grpc.Testing.CoreRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncUnaryCall CoreCountAsync(global::Grpc.Testing.CoreRequest request, CallOptions options) { - var call = CreateCall(__Method_CoreCount, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.AsyncUnaryCall(__Method_CoreCount, null, options, request); } - public AsyncUnaryCall CoreCountAsync(global::Grpc.Testing.CoreRequest request, CallOptions options) + public virtual global::Grpc.Testing.Void QuitWorker(global::Grpc.Testing.Void request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_CoreCount, options); - return Calls.AsyncUnaryCall(call, request); + return QuitWorker(request, new CallOptions(headers, deadline, cancellationToken)); } - public global::Grpc.Testing.Void QuitWorker(global::Grpc.Testing.Void request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual global::Grpc.Testing.Void QuitWorker(global::Grpc.Testing.Void request, CallOptions options) { - var call = CreateCall(__Method_QuitWorker, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); + return CallInvoker.BlockingUnaryCall(__Method_QuitWorker, null, options, request); } - public global::Grpc.Testing.Void QuitWorker(global::Grpc.Testing.Void request, CallOptions options) + public virtual AsyncUnaryCall QuitWorkerAsync(global::Grpc.Testing.Void request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_QuitWorker, options); - return Calls.BlockingUnaryCall(call, request); + return QuitWorkerAsync(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncUnaryCall QuitWorkerAsync(global::Grpc.Testing.Void request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncUnaryCall QuitWorkerAsync(global::Grpc.Testing.Void request, CallOptions options) { - var call = CreateCall(__Method_QuitWorker, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.AsyncUnaryCall(__Method_QuitWorker, null, options, request); } - public AsyncUnaryCall QuitWorkerAsync(global::Grpc.Testing.Void request, CallOptions options) + protected override WorkerServiceClient NewInstance(ClientBaseConfiguration configuration) { - var call = CreateCall(__Method_QuitWorker, options); - return Calls.AsyncUnaryCall(call, request); + return new WorkerServiceClient(configuration); } } diff --git a/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs b/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs index 6b3a7cbf2d..b84ec2d984 100644 --- a/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs +++ b/src/csharp/Grpc.IntegrationTesting/TestGrpc.cs @@ -69,6 +69,7 @@ namespace Grpc.Testing { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface ITestServiceClient { global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -137,90 +138,90 @@ namespace Grpc.Testing { } // client stub - public class TestServiceClient : ClientBase, ITestServiceClient + public class TestServiceClient : ClientBase, ITestServiceClient { public TestServiceClient(Channel channel) : base(channel) { } - public global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public TestServiceClient(CallInvoker callInvoker) : base(callInvoker) { - var call = CreateCall(__Method_EmptyCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); } - public global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, CallOptions options) + ///Protected parameterless constructor to allow creation of test doubles. + protected TestServiceClient() : base() { - var call = CreateCall(__Method_EmptyCall, options); - return Calls.BlockingUnaryCall(call, request); } - public AsyncUnaryCall EmptyCallAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + ///Protected constructor to allow creation of configured clients. + protected TestServiceClient(ClientBaseConfiguration configuration) : base(configuration) { - var call = CreateCall(__Method_EmptyCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); } - public AsyncUnaryCall EmptyCallAsync(global::Grpc.Testing.Empty request, CallOptions options) + + public virtual global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return EmptyCall(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, CallOptions options) + { + return CallInvoker.BlockingUnaryCall(__Method_EmptyCall, null, options, request); + } + public virtual AsyncUnaryCall EmptyCallAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return EmptyCallAsync(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual AsyncUnaryCall EmptyCallAsync(global::Grpc.Testing.Empty request, CallOptions options) { - var call = CreateCall(__Method_EmptyCall, options); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.AsyncUnaryCall(__Method_EmptyCall, null, options, request); } - public global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_UnaryCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); + return UnaryCall(request, new CallOptions(headers, deadline, cancellationToken)); } - public global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, CallOptions options) + public virtual global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, CallOptions options) { - var call = CreateCall(__Method_UnaryCall, options); - return Calls.BlockingUnaryCall(call, request); + return CallInvoker.BlockingUnaryCall(__Method_UnaryCall, null, options, request); } - public AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_UnaryCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); + return UnaryCallAsync(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, CallOptions options) + public virtual AsyncUnaryCall UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, CallOptions options) { - var call = CreateCall(__Method_UnaryCall, options); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.AsyncUnaryCall(__Method_UnaryCall, null, options, request); } - public AsyncServerStreamingCall StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncServerStreamingCall StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_StreamingOutputCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncServerStreamingCall(call, request); + return StreamingOutputCall(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncServerStreamingCall StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, CallOptions options) + public virtual AsyncServerStreamingCall StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, CallOptions options) { - var call = CreateCall(__Method_StreamingOutputCall, options); - return Calls.AsyncServerStreamingCall(call, request); + return CallInvoker.AsyncServerStreamingCall(__Method_StreamingOutputCall, null, options, request); } - public AsyncClientStreamingCall StreamingInputCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncClientStreamingCall StreamingInputCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_StreamingInputCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncClientStreamingCall(call); + return StreamingInputCall(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncClientStreamingCall StreamingInputCall(CallOptions options) + public virtual AsyncClientStreamingCall StreamingInputCall(CallOptions options) { - var call = CreateCall(__Method_StreamingInputCall, options); - return Calls.AsyncClientStreamingCall(call); + return CallInvoker.AsyncClientStreamingCall(__Method_StreamingInputCall, null, options); } - public AsyncDuplexStreamingCall FullDuplexCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncDuplexStreamingCall FullDuplexCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_FullDuplexCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncDuplexStreamingCall(call); + return FullDuplexCall(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncDuplexStreamingCall FullDuplexCall(CallOptions options) + public virtual AsyncDuplexStreamingCall FullDuplexCall(CallOptions options) { - var call = CreateCall(__Method_FullDuplexCall, options); - return Calls.AsyncDuplexStreamingCall(call); + return CallInvoker.AsyncDuplexStreamingCall(__Method_FullDuplexCall, null, options); } - public AsyncDuplexStreamingCall HalfDuplexCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncDuplexStreamingCall HalfDuplexCall(Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_HalfDuplexCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncDuplexStreamingCall(call); + return HalfDuplexCall(new CallOptions(headers, deadline, cancellationToken)); } - public AsyncDuplexStreamingCall HalfDuplexCall(CallOptions options) + public virtual AsyncDuplexStreamingCall HalfDuplexCall(CallOptions options) { - var call = CreateCall(__Method_HalfDuplexCall, options); - return Calls.AsyncDuplexStreamingCall(call); + return CallInvoker.AsyncDuplexStreamingCall(__Method_HalfDuplexCall, null, options); + } + protected override TestServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new TestServiceClient(configuration); } } @@ -275,6 +276,7 @@ namespace Grpc.Testing { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface IUnimplementedServiceClient { global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -301,30 +303,42 @@ namespace Grpc.Testing { } // client stub - public class UnimplementedServiceClient : ClientBase, IUnimplementedServiceClient + public class UnimplementedServiceClient : ClientBase, IUnimplementedServiceClient { public UnimplementedServiceClient(Channel channel) : base(channel) { } - public global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public UnimplementedServiceClient(CallInvoker callInvoker) : base(callInvoker) + { + } + ///Protected parameterless constructor to allow creation of test doubles. + protected UnimplementedServiceClient() : base() { - var call = CreateCall(__Method_UnimplementedCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); } - public global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, CallOptions options) + ///Protected constructor to allow creation of configured clients. + protected UnimplementedServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + public virtual global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_UnimplementedCall, options); - return Calls.BlockingUnaryCall(call, request); + return UnimplementedCall(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncUnaryCall UnimplementedCallAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, CallOptions options) { - var call = CreateCall(__Method_UnimplementedCall, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.BlockingUnaryCall(__Method_UnimplementedCall, null, options, request); } - public AsyncUnaryCall UnimplementedCallAsync(global::Grpc.Testing.Empty request, CallOptions options) + public virtual AsyncUnaryCall UnimplementedCallAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_UnimplementedCall, options); - return Calls.AsyncUnaryCall(call, request); + return UnimplementedCallAsync(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual AsyncUnaryCall UnimplementedCallAsync(global::Grpc.Testing.Empty request, CallOptions options) + { + return CallInvoker.AsyncUnaryCall(__Method_UnimplementedCall, null, options, request); + } + protected override UnimplementedServiceClient NewInstance(ClientBaseConfiguration configuration) + { + return new UnimplementedServiceClient(configuration); } } @@ -377,6 +391,7 @@ namespace Grpc.Testing { } // client interface + [System.Obsolete("Client side interfaced will be removed in the next release. Use client class directly.")] public interface IReconnectServiceClient { global::Grpc.Testing.Empty Start(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)); @@ -413,50 +428,58 @@ namespace Grpc.Testing { } // client stub - public class ReconnectServiceClient : ClientBase, IReconnectServiceClient + public class ReconnectServiceClient : ClientBase, IReconnectServiceClient { public ReconnectServiceClient(Channel channel) : base(channel) { } - public global::Grpc.Testing.Empty Start(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public ReconnectServiceClient(CallInvoker callInvoker) : base(callInvoker) + { + } + ///Protected parameterless constructor to allow creation of test doubles. + protected ReconnectServiceClient() : base() + { + } + ///Protected constructor to allow creation of configured clients. + protected ReconnectServiceClient(ClientBaseConfiguration configuration) : base(configuration) + { + } + + public virtual global::Grpc.Testing.Empty Start(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + { + return Start(request, new CallOptions(headers, deadline, cancellationToken)); + } + public virtual global::Grpc.Testing.Empty Start(global::Grpc.Testing.Empty request, CallOptions options) { - var call = CreateCall(__Method_Start, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); + return CallInvoker.BlockingUnaryCall(__Method_Start, null, options, request); } - public global::Grpc.Testing.Empty Start(global::Grpc.Testing.Empty request, CallOptions options) + public virtual AsyncUnaryCall StartAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_Start, options); - return Calls.BlockingUnaryCall(call, request); + return StartAsync(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncUnaryCall StartAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncUnaryCall StartAsync(global::Grpc.Testing.Empty request, CallOptions options) { - var call = CreateCall(__Method_Start, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.AsyncUnaryCall(__Method_Start, null, options, request); } - public AsyncUnaryCall StartAsync(global::Grpc.Testing.Empty request, CallOptions options) + public virtual global::Grpc.Testing.ReconnectInfo Stop(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_Start, options); - return Calls.AsyncUnaryCall(call, request); + return Stop(request, new CallOptions(headers, deadline, cancellationToken)); } - public global::Grpc.Testing.ReconnectInfo Stop(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual global::Grpc.Testing.ReconnectInfo Stop(global::Grpc.Testing.Empty request, CallOptions options) { - var call = CreateCall(__Method_Stop, new CallOptions(headers, deadline, cancellationToken)); - return Calls.BlockingUnaryCall(call, request); + return CallInvoker.BlockingUnaryCall(__Method_Stop, null, options, request); } - public global::Grpc.Testing.ReconnectInfo Stop(global::Grpc.Testing.Empty request, CallOptions options) + public virtual AsyncUnaryCall StopAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) { - var call = CreateCall(__Method_Stop, options); - return Calls.BlockingUnaryCall(call, request); + return StopAsync(request, new CallOptions(headers, deadline, cancellationToken)); } - public AsyncUnaryCall StopAsync(global::Grpc.Testing.Empty request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken)) + public virtual AsyncUnaryCall StopAsync(global::Grpc.Testing.Empty request, CallOptions options) { - var call = CreateCall(__Method_Stop, new CallOptions(headers, deadline, cancellationToken)); - return Calls.AsyncUnaryCall(call, request); + return CallInvoker.AsyncUnaryCall(__Method_Stop, null, options, request); } - public AsyncUnaryCall StopAsync(global::Grpc.Testing.Empty request, CallOptions options) + protected override ReconnectServiceClient NewInstance(ClientBaseConfiguration configuration) { - var call = CreateCall(__Method_Stop, options); - return Calls.AsyncUnaryCall(call, request); + return new ReconnectServiceClient(configuration); } } -- cgit v1.2.3 From f390c837d7edbe14430607fa7899e6ea08d631b3 Mon Sep 17 00:00:00 2001 From: David Garcia Quintas Date: Fri, 1 Apr 2016 16:48:04 -0700 Subject: removed incorrect include --- src/core/lib/client_config/client_channel_factory.h | 1 - 1 file changed, 1 deletion(-) (limited to 'src') diff --git a/src/core/lib/client_config/client_channel_factory.h b/src/core/lib/client_config/client_channel_factory.h index 83d743ddc3..0b71cd9bdb 100644 --- a/src/core/lib/client_config/client_channel_factory.h +++ b/src/core/lib/client_config/client_channel_factory.h @@ -34,7 +34,6 @@ #ifndef GRPC_CORE_LIB_CLIENT_CONFIG_CLIENT_CHANNEL_FACTORY_H #define GRPC_CORE_LIB_CLIENT_CONFIG_CLIENT_CHANNEL_FACTORY_H -#include #include #include "src/core/lib/channel/channel_stack.h" -- cgit v1.2.3 From 5d2703012858201810069e04d218f26d95bc22d1 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Fri, 1 Apr 2016 17:28:49 -0700 Subject: add some test for the newly generated code --- .../Grpc.IntegrationTesting/GeneratedClientTest.cs | 106 +++++++++++++++++++ .../GeneratedServiceBaseTest.cs | 116 +++++++++++++++++++++ .../Grpc.IntegrationTesting.csproj | 2 + src/csharp/tests.json | 2 + 4 files changed, 226 insertions(+) create mode 100644 src/csharp/Grpc.IntegrationTesting/GeneratedClientTest.cs create mode 100644 src/csharp/Grpc.IntegrationTesting/GeneratedServiceBaseTest.cs (limited to 'src') diff --git a/src/csharp/Grpc.IntegrationTesting/GeneratedClientTest.cs b/src/csharp/Grpc.IntegrationTesting/GeneratedClientTest.cs new file mode 100644 index 0000000000..37786b6c30 --- /dev/null +++ b/src/csharp/Grpc.IntegrationTesting/GeneratedClientTest.cs @@ -0,0 +1,106 @@ +#region Copyright notice and license + +// Copyright 2015-2016, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Threading; +using System.Threading.Tasks; +using Grpc.Core; +using Grpc.Core.Utils; +using Grpc.Testing; +using Moq; +using NUnit.Framework; + +namespace Grpc.IntegrationTesting +{ + public class GeneratedClientTest + { + TestService.TestServiceClient unimplementedClient = new UnimplementedTestServiceClient(); + + [Test] + public void ExpandedParamOverloadCanBeMocked() + { + var expected = new SimpleResponse(); + + var mockClient = new Mock(); + // mocking is relatively clumsy because one needs to specify value for all the optional params. + mockClient.Setup(m => m.UnaryCall(It.IsAny(), null, null, CancellationToken.None)).Returns(expected); + + Assert.AreSame(expected, mockClient.Object.UnaryCall(new SimpleRequest())); + } + + [Test] + public void CallOptionsOverloadCanBeMocked() + { + var expected = new SimpleResponse(); + + var mockClient = new Mock(); + mockClient.Setup(m => m.UnaryCall(It.IsAny(), It.IsAny())).Returns(expected); + + Assert.AreSame(expected, mockClient.Object.UnaryCall(new SimpleRequest(), new CallOptions())); + } + + [Test] + public void DefaultMethodStubThrows_UnaryCall() + { + Assert.Throws(typeof(NotImplementedException), () => unimplementedClient.UnaryCall(new SimpleRequest())); + } + + [Test] + public void DefaultMethodStubThrows_ClientStreaming() + { + Assert.Throws(typeof(NotImplementedException), () => unimplementedClient.StreamingInputCall()); + } + + [Test] + public void DefaultMethodStubThrows_ServerStreaming() + { + Assert.Throws(typeof(NotImplementedException), () => unimplementedClient.StreamingOutputCall(new StreamingOutputCallRequest())); + } + + [Test] + public void DefaultMethodStubThrows_DuplexStreaming() + { + Assert.Throws(typeof(NotImplementedException), () => unimplementedClient.FullDuplexCall()); + } + + /// + /// Subclass of the generated client that doesn't override any method stubs. + /// + private class UnimplementedTestServiceClient : TestService.TestServiceClient + { + } + } +} diff --git a/src/csharp/Grpc.IntegrationTesting/GeneratedServiceBaseTest.cs b/src/csharp/Grpc.IntegrationTesting/GeneratedServiceBaseTest.cs new file mode 100644 index 0000000000..99aa729030 --- /dev/null +++ b/src/csharp/Grpc.IntegrationTesting/GeneratedServiceBaseTest.cs @@ -0,0 +1,116 @@ +#region Copyright notice and license + +// Copyright 2015-2016, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Threading; +using System.Threading.Tasks; +using Grpc.Core; +using Grpc.Core.Utils; +using Grpc.Testing; +using Moq; +using NUnit.Framework; + +namespace Grpc.IntegrationTesting +{ + public class GeneratedServiceBaseTest + { + const string Host = "localhost"; + Server server; + Channel channel; + TestService.TestServiceClient client; + + [SetUp] + public void Init() + { + server = new Server + { + Services = { TestService.BindService(new UnimplementedTestServiceImpl()) }, + Ports = { { Host, ServerPort.PickUnused, SslServerCredentials.Insecure } } + }; + server.Start(); + channel = new Channel(Host, server.Ports.Single().BoundPort, ChannelCredentials.Insecure); + client = TestService.NewClient(channel); + } + + [TearDown] + public void Cleanup() + { + channel.ShutdownAsync().Wait(); + server.ShutdownAsync().Wait(); + } + + [Test] + public void UnimplementedByDefault_Unary() + { + var ex = Assert.Throws(() => client.UnaryCall(new SimpleRequest { })); + Assert.AreEqual(StatusCode.Unimplemented, ex.Status.StatusCode); + } + + [Test] + public async Task UnimplementedByDefault_ClientStreaming() + { + var call = client.StreamingInputCall(); + + var ex = Assert.Throws(async () => await call); + Assert.AreEqual(StatusCode.Unimplemented, ex.Status.StatusCode); + } + + [Test] + public async Task UnimplementedByDefault_ServerStreamingCall() + { + var call = client.StreamingOutputCall(new StreamingOutputCallRequest()); + + var ex = Assert.Throws(async () => await call.ResponseStream.MoveNext()); + Assert.AreEqual(StatusCode.Unimplemented, ex.Status.StatusCode); + } + + [Test] + public async Task UnimplementedByDefault_DuplexStreamingCall() + { + var call = client.FullDuplexCall(); + + var ex = Assert.Throws(async () => await call.ResponseStream.MoveNext()); + Assert.AreEqual(StatusCode.Unimplemented, ex.Status.StatusCode); + } + + /// + /// Implementation of TestService that doesn't override any methods. + /// + private class UnimplementedTestServiceImpl : TestService.TestServiceBase + { + } + } +} diff --git a/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj b/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj index c6a9e73c10..64d14b0df5 100644 --- a/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj +++ b/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj @@ -113,6 +113,8 @@ + + diff --git a/src/csharp/tests.json b/src/csharp/tests.json index 0fe8bc6e6f..a0c6cd3bc5 100644 --- a/src/csharp/tests.json +++ b/src/csharp/tests.json @@ -36,6 +36,8 @@ "Grpc.HealthCheck.Tests.HealthClientServerTest", "Grpc.HealthCheck.Tests.HealthServiceImplTest", "Grpc.IntegrationTesting.HistogramTest", + "Grpc.IntegrationTesting.GeneratedClientTest", + "Grpc.IntegrationTesting.GeneratedServiceBaseTest", "Grpc.IntegrationTesting.InteropClientServerTest", "Grpc.IntegrationTesting.MetadataCredentialsTest", "Grpc.IntegrationTesting.RunnerClientServerTest", -- cgit v1.2.3 From 06cb1a9d938b566f79e59e5e9ba31979e13274ba Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 4 Apr 2016 08:10:47 -0700 Subject: Initial interface rework to allow knowing whether to pull payload at registration, not at request time --- include/grpc/grpc.h | 15 +++- include/grpc/impl/codegen/grpc_types.h | 4 +- src/core/lib/surface/server.c | 139 ++++++++++++++++++--------------- src/cpp/server/server.cc | 18 ++++- test/core/bad_client/bad_client.c | 6 +- test/core/surface/server_test.c | 20 +++-- 6 files changed, 121 insertions(+), 81 deletions(-) (limited to 'src') diff --git a/include/grpc/grpc.h b/include/grpc/grpc.h index 8b460722e2..5c868aece3 100644 --- a/include/grpc/grpc.h +++ b/include/grpc/grpc.h @@ -289,6 +289,14 @@ GRPCAPI grpc_call_error grpc_server_request_call( grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new); +/** How to handle payloads for a registered method */ +typedef enum { + /** Don't try to read the payload */ + GRPC_SRM_PAYLOAD_NONE, + /** Read the initial payload as a byte buffer */ + GRPC_SRM_PAYLOAD_READ_INITIAL_BYTE_BUFFER +} grpc_server_register_method_payload_handling; + /** Registers a method in the server. Methods to this (host, method) pair will not be reported by grpc_server_request_call, but instead be reported by @@ -296,9 +304,10 @@ GRPCAPI grpc_call_error grpc_server_request_call( registered_method (as returned by this function). Must be called before grpc_server_start. Returns NULL on failure. */ -GRPCAPI void *grpc_server_register_method(grpc_server *server, - const char *method, const char *host, - uint32_t flags); +GRPCAPI void *grpc_server_register_method( + grpc_server *server, const char *method, const char *host, + grpc_server_register_method_payload_handling payload_handling, + uint32_t flags); /** Request notification of a new pre-registered call. 'cq_for_notification' must have been registered to the server via diff --git a/include/grpc/impl/codegen/grpc_types.h b/include/grpc/impl/codegen/grpc_types.h index b09b1cdf44..38da99b4d7 100644 --- a/include/grpc/impl/codegen/grpc_types.h +++ b/include/grpc/impl/codegen/grpc_types.h @@ -185,7 +185,9 @@ typedef enum grpc_call_error { server */ GRPC_CALL_ERROR_NOT_SERVER_COMPLETION_QUEUE, /** this batch of operations leads to more operations than allowed */ - GRPC_CALL_ERROR_BATCH_TOO_BIG + GRPC_CALL_ERROR_BATCH_TOO_BIG, + /** payload type requested is not the type registered */ + GRPC_CALL_ERROR_PAYLOAD_TYPE_MISMATCH } grpc_call_error; /* Write Flags: */ diff --git a/src/core/lib/surface/server.c b/src/core/lib/surface/server.c index 1898bee1c1..ac5a2b4160 100644 --- a/src/core/lib/surface/server.c +++ b/src/core/lib/surface/server.c @@ -173,6 +173,7 @@ struct request_matcher { struct registered_method { char *method; char *host; + grpc_server_register_method_payload_handling payload_handling; uint32_t flags; request_matcher request_matcher; registered_method *next; @@ -417,6 +418,69 @@ static void destroy_channel(grpc_exec_ctx *exec_ctx, channel_data *chand) { &op); } +static void publish_registered_or_batch(grpc_exec_ctx *exec_ctx, + void *user_data, bool success); + +static void cpstr(char **dest, size_t *capacity, grpc_mdstr *value) { + gpr_slice slice = value->slice; + size_t len = GPR_SLICE_LENGTH(slice); + + if (len + 1 > *capacity) { + *capacity = GPR_MAX(len + 1, *capacity * 2); + *dest = gpr_realloc(*dest, *capacity); + } + memcpy(*dest, grpc_mdstr_as_c_string(value), len + 1); +} + +static void begin_call(grpc_exec_ctx *exec_ctx, grpc_server *server, + call_data *calld, requested_call *rc) { + grpc_op ops[1]; + grpc_op *op = ops; + + memset(ops, 0, sizeof(ops)); + + /* called once initial metadata has been read by the call, but BEFORE + the ioreq to fetch it out of the call has been executed. + This means metadata related fields can be relied on in calld, but to + fill in the metadata array passed by the client, we need to perform + an ioreq op, that should complete immediately. */ + + grpc_call_set_completion_queue(exec_ctx, calld->call, rc->cq_bound_to_call); + grpc_closure_init(&rc->publish, publish_registered_or_batch, rc); + *rc->call = calld->call; + calld->cq_new = rc->cq_for_notification; + GPR_SWAP(grpc_metadata_array, *rc->initial_metadata, calld->initial_metadata); + switch (rc->type) { + case BATCH_CALL: + GPR_ASSERT(calld->host != NULL); + GPR_ASSERT(calld->path != NULL); + cpstr(&rc->data.batch.details->host, + &rc->data.batch.details->host_capacity, calld->host); + cpstr(&rc->data.batch.details->method, + &rc->data.batch.details->method_capacity, calld->path); + rc->data.batch.details->deadline = calld->deadline; + rc->data.batch.details->flags = + 0 | (calld->recv_idempotent_request + ? GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST + : 0); + break; + case REGISTERED_CALL: + *rc->data.registered.deadline = calld->deadline; + if (rc->data.registered.optional_payload) { + op->op = GRPC_OP_RECV_MESSAGE; + op->data.recv_message = rc->data.registered.optional_payload; + op++; + } + break; + default: + GPR_UNREACHABLE_CODE(return ); + } + + GRPC_CALL_INTERNAL_REF(calld->call, "server"); + grpc_call_start_batch_and_execute(exec_ctx, calld->call, ops, + (size_t)(op - ops), &rc->publish); +} + static void finish_start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_server *server, grpc_call_element *elem, request_matcher *rm) { call_data *calld = elem->call_data; @@ -840,8 +904,10 @@ static int streq(const char *a, const char *b) { return 0 == strcmp(a, b); } -void *grpc_server_register_method(grpc_server *server, const char *method, - const char *host, uint32_t flags) { +void *grpc_server_register_method( + grpc_server *server, const char *method, const char *host, + grpc_server_register_method_payload_handling payload_handling, + uint32_t flags) { registered_method *m; GRPC_API_TRACE( "grpc_server_register_method(server=%p, method=%s, host=%s, " @@ -1209,6 +1275,12 @@ grpc_call_error grpc_server_request_registered_call( error = GRPC_CALL_ERROR_NOT_SERVER_COMPLETION_QUEUE; goto done; } + if ((optional_payload == NULL) != + (rm->payload_handling == GRPC_SRM_PAYLOAD_NONE)) { + gpr_free(rc); + error = GRPC_CALL_ERROR_PAYLOAD_TYPE_MISMATCH; + goto done; + } grpc_cq_begin_op(cq_for_notification, tag); rc->type = REGISTERED_CALL; rc->server = server; @@ -1226,69 +1298,6 @@ done: return error; } -static void publish_registered_or_batch(grpc_exec_ctx *exec_ctx, - void *user_data, bool success); - -static void cpstr(char **dest, size_t *capacity, grpc_mdstr *value) { - gpr_slice slice = value->slice; - size_t len = GPR_SLICE_LENGTH(slice); - - if (len + 1 > *capacity) { - *capacity = GPR_MAX(len + 1, *capacity * 2); - *dest = gpr_realloc(*dest, *capacity); - } - memcpy(*dest, grpc_mdstr_as_c_string(value), len + 1); -} - -static void begin_call(grpc_exec_ctx *exec_ctx, grpc_server *server, - call_data *calld, requested_call *rc) { - grpc_op ops[1]; - grpc_op *op = ops; - - memset(ops, 0, sizeof(ops)); - - /* called once initial metadata has been read by the call, but BEFORE - the ioreq to fetch it out of the call has been executed. - This means metadata related fields can be relied on in calld, but to - fill in the metadata array passed by the client, we need to perform - an ioreq op, that should complete immediately. */ - - grpc_call_set_completion_queue(exec_ctx, calld->call, rc->cq_bound_to_call); - grpc_closure_init(&rc->publish, publish_registered_or_batch, rc); - *rc->call = calld->call; - calld->cq_new = rc->cq_for_notification; - GPR_SWAP(grpc_metadata_array, *rc->initial_metadata, calld->initial_metadata); - switch (rc->type) { - case BATCH_CALL: - GPR_ASSERT(calld->host != NULL); - GPR_ASSERT(calld->path != NULL); - cpstr(&rc->data.batch.details->host, - &rc->data.batch.details->host_capacity, calld->host); - cpstr(&rc->data.batch.details->method, - &rc->data.batch.details->method_capacity, calld->path); - rc->data.batch.details->deadline = calld->deadline; - rc->data.batch.details->flags = - 0 | (calld->recv_idempotent_request - ? GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST - : 0); - break; - case REGISTERED_CALL: - *rc->data.registered.deadline = calld->deadline; - if (rc->data.registered.optional_payload) { - op->op = GRPC_OP_RECV_MESSAGE; - op->data.recv_message = rc->data.registered.optional_payload; - op++; - } - break; - default: - GPR_UNREACHABLE_CODE(return ); - } - - GRPC_CALL_INTERNAL_REF(calld->call, "server"); - grpc_call_start_batch_and_execute(exec_ctx, calld->call, ops, - (size_t)(op - ops), &rc->publish); -} - static void done_request_event(grpc_exec_ctx *exec_ctx, void *req, grpc_cq_completion *c) { requested_call *rc = req; diff --git a/src/cpp/server/server.cc b/src/cpp/server/server.cc index 3e44c502fc..fafe31e84c 100644 --- a/src/cpp/server/server.cc +++ b/src/cpp/server/server.cc @@ -321,6 +321,19 @@ void Server::SetGlobalCallbacks(GlobalCallbacks* callbacks) { g_callbacks.reset(callbacks); } +static grpc_server_register_method_payload_handling PayloadHandlingForMethod( + RpcServiceMethod* method) { + switch (method->method_type()) { + case RpcMethod::NORMAL_RPC: + case RpcMethod::SERVER_STREAMING: + return GRPC_SRM_PAYLOAD_READ_INITIAL_BYTE_BUFFER; + case RpcMethod::CLIENT_STREAMING: + case RpcMethod::BIDI_STREAMING: + return GRPC_SRM_PAYLOAD_NONE; + } + GPR_UNREACHABLE_CODE(return GRPC_SRM_PAYLOAD_NONE;); +} + bool Server::RegisterService(const grpc::string* host, Service* service) { bool has_async_methods = service->has_async_methods(); if (has_async_methods) { @@ -334,8 +347,9 @@ bool Server::RegisterService(const grpc::string* host, Service* service) { continue; } RpcServiceMethod* method = it->get(); - void* tag = grpc_server_register_method(server_, method->name(), - host ? host->c_str() : nullptr, 0); + void* tag = grpc_server_register_method( + server_, method->name(), host ? host->c_str() : nullptr, + PayloadHandlingForMethod(method), 0); if (tag == nullptr) { gpr_log(GPR_DEBUG, "Attempt to register %s multiple times", method->name()); diff --git a/test/core/bad_client/bad_client.c b/test/core/bad_client/bad_client.c index 433ecf69df..1e1b227159 100644 --- a/test/core/bad_client/bad_client.c +++ b/test/core/bad_client/bad_client.c @@ -107,9 +107,9 @@ void grpc_run_bad_client_test(grpc_bad_client_server_side_validator validator, gpr_event_init(&a.done_write); a.validator = validator; grpc_server_register_completion_queue(a.server, a.cq, NULL); - a.registered_method = - grpc_server_register_method(a.server, GRPC_BAD_CLIENT_REGISTERED_METHOD, - GRPC_BAD_CLIENT_REGISTERED_HOST, 0); + a.registered_method = grpc_server_register_method( + a.server, GRPC_BAD_CLIENT_REGISTERED_METHOD, + GRPC_BAD_CLIENT_REGISTERED_HOST, GRPC_SRM_PAYLOAD_NONE, 0); grpc_server_start(a.server); transport = grpc_create_chttp2_transport(&exec_ctx, NULL, sfd.server, 0); server_setup_transport(&a, transport); diff --git a/test/core/surface/server_test.c b/test/core/surface/server_test.c index 4c62d8caad..7bb45434f4 100644 --- a/test/core/surface/server_test.c +++ b/test/core/surface/server_test.c @@ -42,19 +42,25 @@ void test_register_method_fail(void) { grpc_server *server = grpc_server_create(NULL, NULL); void *method; void *method_old; - method = grpc_server_register_method(server, NULL, NULL, 0); + method = + grpc_server_register_method(server, NULL, NULL, GRPC_SRM_PAYLOAD_NONE, 0); GPR_ASSERT(method == NULL); - method_old = grpc_server_register_method(server, "m", "h", 0); + method_old = + grpc_server_register_method(server, "m", "h", GRPC_SRM_PAYLOAD_NONE, 0); GPR_ASSERT(method_old != NULL); - method = grpc_server_register_method(server, "m", "h", 0); + method = grpc_server_register_method( + server, "m", "h", GRPC_SRM_PAYLOAD_READ_INITIAL_BYTE_BUFFER, 0); GPR_ASSERT(method == NULL); - method_old = grpc_server_register_method( - server, "m2", "h2", GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST); + method_old = + grpc_server_register_method(server, "m2", "h2", GRPC_SRM_PAYLOAD_NONE, + GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST); GPR_ASSERT(method_old != NULL); - method = grpc_server_register_method(server, "m2", "h2", 0); + method = + grpc_server_register_method(server, "m2", "h2", GRPC_SRM_PAYLOAD_NONE, 0); GPR_ASSERT(method == NULL); method = grpc_server_register_method( - server, "m2", "h2", GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST); + server, "m2", "h2", GRPC_SRM_PAYLOAD_READ_INITIAL_BYTE_BUFFER, + GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST); GPR_ASSERT(method == NULL); grpc_server_destroy(server); } -- cgit v1.2.3 From 5ada3d20c8d427cea7eca0b8fa82ed1d9a5c5c8e Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 4 Apr 2016 08:30:59 -0700 Subject: Add missing line --- src/core/lib/surface/server.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/core/lib/surface/server.c b/src/core/lib/surface/server.c index ac5a2b4160..2829a86a94 100644 --- a/src/core/lib/surface/server.c +++ b/src/core/lib/surface/server.c @@ -936,6 +936,7 @@ void *grpc_server_register_method( m->method = gpr_strdup(method); m->host = gpr_strdup(host); m->next = server->registered_methods; + m->payload_handling = payload_handling; m->flags = flags; server->registered_methods = m; return m; -- cgit v1.2.3 From 8851269f5e592125a5ddaa661cee77d0bd5259ac Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 4 Apr 2016 09:32:52 -0700 Subject: Fix head-of-line blocking in server --- src/core/lib/surface/server.c | 161 +++++++++++++++++++++++------------------- 1 file changed, 90 insertions(+), 71 deletions(-) (limited to 'src') diff --git a/src/core/lib/surface/server.c b/src/core/lib/surface/server.c index 2829a86a94..37cc2bd101 100644 --- a/src/core/lib/surface/server.c +++ b/src/core/lib/surface/server.c @@ -95,7 +95,6 @@ typedef struct requested_call { grpc_byte_buffer **optional_payload; } registered; } data; - grpc_closure publish; } requested_call; typedef struct channel_registered_method { @@ -156,15 +155,21 @@ struct call_data { bool recv_idempotent_request; grpc_metadata_array initial_metadata; + request_matcher *request_matcher; + grpc_byte_buffer *payload; + grpc_closure got_initial_metadata; grpc_closure server_on_recv_initial_metadata; grpc_closure kill_zombie_closure; grpc_closure *on_done_recv_initial_metadata; + grpc_closure publish; + call_data *pending_next; }; struct request_matcher { + grpc_server *server; call_data *pending_head; call_data *pending_tail; gpr_stack_lockfree *requests; @@ -227,8 +232,7 @@ struct grpc_server { #define SERVER_FROM_CALL_ELEM(elem) \ (((channel_data *)(elem)->channel_data)->server) -static void begin_call(grpc_exec_ctx *exec_ctx, grpc_server *server, - call_data *calld, requested_call *rc); +static void publish_new_rpc(grpc_exec_ctx *exec_ctx, void *calld, bool success); static void fail_call(grpc_exec_ctx *exec_ctx, grpc_server *server, requested_call *rc); /* Before calling maybe_finish_shutdown, we must hold mu_global and not @@ -304,8 +308,10 @@ static void channel_broadcaster_shutdown(grpc_exec_ctx *exec_ctx, * request_matcher */ -static void request_matcher_init(request_matcher *rm, size_t entries) { +static void request_matcher_init(request_matcher *rm, size_t entries, + grpc_server *server) { memset(rm, 0, sizeof(*rm)); + rm->server = server; rm->requests = gpr_stack_lockfree_create(entries); } @@ -418,9 +424,6 @@ static void destroy_channel(grpc_exec_ctx *exec_ctx, channel_data *chand) { &op); } -static void publish_registered_or_batch(grpc_exec_ctx *exec_ctx, - void *user_data, bool success); - static void cpstr(char **dest, size_t *capacity, grpc_mdstr *value) { gpr_slice slice = value->slice; size_t len = GPR_SLICE_LENGTH(slice); @@ -432,22 +435,28 @@ static void cpstr(char **dest, size_t *capacity, grpc_mdstr *value) { memcpy(*dest, grpc_mdstr_as_c_string(value), len + 1); } -static void begin_call(grpc_exec_ctx *exec_ctx, grpc_server *server, - call_data *calld, requested_call *rc) { - grpc_op ops[1]; - grpc_op *op = ops; +static void done_request_event(grpc_exec_ctx *exec_ctx, void *req, + grpc_cq_completion *c) { + requested_call *rc = req; + grpc_server *server = rc->server; - memset(ops, 0, sizeof(ops)); + if (rc >= server->requested_calls && + rc < server->requested_calls + server->max_requested_calls) { + GPR_ASSERT(rc - server->requested_calls <= INT_MAX); + gpr_stack_lockfree_push(server->request_freelist, + (int)(rc - server->requested_calls)); + } else { + gpr_free(req); + } - /* called once initial metadata has been read by the call, but BEFORE - the ioreq to fetch it out of the call has been executed. - This means metadata related fields can be relied on in calld, but to - fill in the metadata array passed by the client, we need to perform - an ioreq op, that should complete immediately. */ + server_unref(exec_ctx, server); +} +static void publish_call(grpc_exec_ctx *exec_ctx, grpc_server *server, + call_data *calld, requested_call *rc) { grpc_call_set_completion_queue(exec_ctx, calld->call, rc->cq_bound_to_call); - grpc_closure_init(&rc->publish, publish_registered_or_batch, rc); - *rc->call = calld->call; + grpc_call *call = calld->call; + *rc->call = call; calld->cq_new = rc->cq_for_notification; GPR_SWAP(grpc_metadata_array, *rc->initial_metadata, calld->initial_metadata); switch (rc->type) { @@ -467,35 +476,38 @@ static void begin_call(grpc_exec_ctx *exec_ctx, grpc_server *server, case REGISTERED_CALL: *rc->data.registered.deadline = calld->deadline; if (rc->data.registered.optional_payload) { - op->op = GRPC_OP_RECV_MESSAGE; - op->data.recv_message = rc->data.registered.optional_payload; - op++; + *rc->data.registered.optional_payload = calld->payload; } break; default: GPR_UNREACHABLE_CODE(return ); } - GRPC_CALL_INTERNAL_REF(calld->call, "server"); - grpc_call_start_batch_and_execute(exec_ctx, calld->call, ops, - (size_t)(op - ops), &rc->publish); + grpc_call_element *elem = + grpc_call_stack_element(grpc_call_get_call_stack(call), 0); + channel_data *chand = elem->channel_data; + server_ref(chand->server); + grpc_cq_end_op(exec_ctx, calld->cq_new, rc->tag, true, done_request_event, rc, + &rc->completion); } -static void finish_start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_server *server, - grpc_call_element *elem, request_matcher *rm) { - call_data *calld = elem->call_data; - int request_id; +static void publish_new_rpc(grpc_exec_ctx *exec_ctx, void *arg, bool success) { + call_data *calld = arg; + request_matcher *rm = calld->request_matcher; + grpc_server *server = rm->server; - if (gpr_atm_acq_load(&server->shutdown_flag)) { + if (!success || gpr_atm_acq_load(&server->shutdown_flag)) { gpr_mu_lock(&calld->mu_state); calld->state = ZOMBIED; gpr_mu_unlock(&calld->mu_state); - grpc_closure_init(&calld->kill_zombie_closure, kill_zombie, elem); + grpc_closure_init( + &calld->kill_zombie_closure, kill_zombie, + grpc_call_stack_element(grpc_call_get_call_stack(calld->call), 0)); grpc_exec_ctx_enqueue(exec_ctx, &calld->kill_zombie_closure, true, NULL); return; } - request_id = gpr_stack_lockfree_pop(rm->requests); + int request_id = gpr_stack_lockfree_pop(rm->requests); if (request_id == -1) { gpr_mu_lock(&server->mu_call); gpr_mu_lock(&calld->mu_state); @@ -513,7 +525,41 @@ static void finish_start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_server *server, gpr_mu_lock(&calld->mu_state); calld->state = ACTIVATED; gpr_mu_unlock(&calld->mu_state); - begin_call(exec_ctx, server, calld, &server->requested_calls[request_id]); + publish_call(exec_ctx, server, calld, &server->requested_calls[request_id]); + } +} + +static void finish_start_new_rpc( + grpc_exec_ctx *exec_ctx, grpc_server *server, grpc_call_element *elem, + request_matcher *rm, + grpc_server_register_method_payload_handling payload_handling) { + call_data *calld = elem->call_data; + + if (gpr_atm_acq_load(&server->shutdown_flag)) { + gpr_mu_lock(&calld->mu_state); + calld->state = ZOMBIED; + gpr_mu_unlock(&calld->mu_state); + grpc_closure_init(&calld->kill_zombie_closure, kill_zombie, elem); + grpc_exec_ctx_enqueue(exec_ctx, &calld->kill_zombie_closure, true, NULL); + return; + } + + calld->request_matcher = rm; + + switch (payload_handling) { + case GRPC_SRM_PAYLOAD_NONE: + publish_new_rpc(exec_ctx, calld, true); + break; + case GRPC_SRM_PAYLOAD_READ_INITIAL_BYTE_BUFFER: { + grpc_op op; + memset(&op, 0, sizeof(op)); + op.op = GRPC_OP_RECV_MESSAGE; + op.data.recv_message = &calld->payload; + grpc_closure_init(&calld->publish, publish_new_rpc, calld); + grpc_call_start_batch_and_execute(exec_ctx, calld->call, &op, 1, + &calld->publish); + break; + } } } @@ -539,7 +585,8 @@ static void start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_call_element *elem) { !calld->recv_idempotent_request) continue; finish_start_new_rpc(exec_ctx, server, elem, - &rm->server_registered_method->request_matcher); + &rm->server_registered_method->request_matcher, + rm->server_registered_method->payload_handling); return; } /* check for a wildcard method definition (no host set) */ @@ -554,12 +601,14 @@ static void start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_call_element *elem) { !calld->recv_idempotent_request) continue; finish_start_new_rpc(exec_ctx, server, elem, - &rm->server_registered_method->request_matcher); + &rm->server_registered_method->request_matcher, + rm->server_registered_method->payload_handling); return; } } finish_start_new_rpc(exec_ctx, server, elem, - &server->unregistered_request_matcher); + &server->unregistered_request_matcher, + GRPC_SRM_PAYLOAD_NONE); } static int num_listeners(grpc_server *server) { @@ -888,7 +937,7 @@ grpc_server *grpc_server_create(const grpc_channel_args *args, void *reserved) { gpr_stack_lockfree_push(server->request_freelist, (int)i); } request_matcher_init(&server->unregistered_request_matcher, - server->max_requested_calls); + server->max_requested_calls, server); server->requested_calls = gpr_malloc(server->max_requested_calls * sizeof(*server->requested_calls)); @@ -932,7 +981,8 @@ void *grpc_server_register_method( } m = gpr_malloc(sizeof(registered_method)); memset(m, 0, sizeof(*m)); - request_matcher_init(&m->request_matcher, server->max_requested_calls); + request_matcher_init(&m->request_matcher, server->max_requested_calls, + server); m->method = gpr_strdup(method); m->host = gpr_strdup(host); m->next = server->registered_methods; @@ -1210,8 +1260,8 @@ static grpc_call_error queue_call_request(grpc_exec_ctx *exec_ctx, GPR_ASSERT(calld->state == PENDING); calld->state = ACTIVATED; gpr_mu_unlock(&calld->mu_state); - begin_call(exec_ctx, server, calld, - &server->requested_calls[request_id]); + publish_call(exec_ctx, server, calld, + &server->requested_calls[request_id]); } gpr_mu_lock(&server->mu_call); } @@ -1299,23 +1349,6 @@ done: return error; } -static void done_request_event(grpc_exec_ctx *exec_ctx, void *req, - grpc_cq_completion *c) { - requested_call *rc = req; - grpc_server *server = rc->server; - - if (rc >= server->requested_calls && - rc < server->requested_calls + server->max_requested_calls) { - GPR_ASSERT(rc - server->requested_calls <= INT_MAX); - gpr_stack_lockfree_push(server->request_freelist, - (int)(rc - server->requested_calls)); - } else { - gpr_free(req); - } - - server_unref(exec_ctx, server); -} - static void fail_call(grpc_exec_ctx *exec_ctx, grpc_server *server, requested_call *rc) { *rc->call = NULL; @@ -1326,20 +1359,6 @@ static void fail_call(grpc_exec_ctx *exec_ctx, grpc_server *server, done_request_event, rc, &rc->completion); } -static void publish_registered_or_batch(grpc_exec_ctx *exec_ctx, void *prc, - bool success) { - requested_call *rc = prc; - grpc_call *call = *rc->call; - grpc_call_element *elem = - grpc_call_stack_element(grpc_call_get_call_stack(call), 0); - call_data *calld = elem->call_data; - channel_data *chand = elem->channel_data; - server_ref(chand->server); - grpc_cq_end_op(exec_ctx, calld->cq_new, rc->tag, success, done_request_event, - rc, &rc->completion); - GRPC_CALL_INTERNAL_UNREF(exec_ctx, call, "server"); -} - const grpc_channel_args *grpc_server_get_channel_args(grpc_server *server) { return server->channel_args; } -- cgit v1.2.3 From 725aaf23367d88ef83c0fce538120eb35b9bf641 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 4 Apr 2016 10:11:23 -0700 Subject: Fix codegen --- src/python/grpcio/grpc/_cython/imports.generated.h | 2 +- src/ruby/ext/grpc/rb_grpc_imports.generated.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/python/grpcio/grpc/_cython/imports.generated.h b/src/python/grpcio/grpc/_cython/imports.generated.h index adcd8e954a..272e85b485 100644 --- a/src/python/grpcio/grpc/_cython/imports.generated.h +++ b/src/python/grpcio/grpc/_cython/imports.generated.h @@ -283,7 +283,7 @@ extern grpc_call_destroy_type grpc_call_destroy_import; 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); extern grpc_server_request_call_type grpc_server_request_call_import; #define grpc_server_request_call grpc_server_request_call_import -typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host, uint32_t flags); +typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host, grpc_server_register_method_payload_handling payload_handling, uint32_t flags); extern grpc_server_register_method_type grpc_server_register_method_import; #define grpc_server_register_method grpc_server_register_method_import typedef grpc_call_error(*grpc_server_request_registered_call_type)(grpc_server *server, void *registered_method, grpc_call **call, gpr_timespec *deadline, grpc_metadata_array *request_metadata, grpc_byte_buffer **optional_payload, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new); diff --git a/src/ruby/ext/grpc/rb_grpc_imports.generated.h b/src/ruby/ext/grpc/rb_grpc_imports.generated.h index 22ea84c750..c526f434c6 100644 --- a/src/ruby/ext/grpc/rb_grpc_imports.generated.h +++ b/src/ruby/ext/grpc/rb_grpc_imports.generated.h @@ -283,7 +283,7 @@ extern grpc_call_destroy_type grpc_call_destroy_import; 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); extern grpc_server_request_call_type grpc_server_request_call_import; #define grpc_server_request_call grpc_server_request_call_import -typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host, uint32_t flags); +typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host, grpc_server_register_method_payload_handling payload_handling, uint32_t flags); extern grpc_server_register_method_type grpc_server_register_method_import; #define grpc_server_register_method grpc_server_register_method_import typedef grpc_call_error(*grpc_server_request_registered_call_type)(grpc_server *server, void *registered_method, grpc_call **call, gpr_timespec *deadline, grpc_metadata_array *request_metadata, grpc_byte_buffer **optional_payload, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new); -- cgit v1.2.3 From 895c1113abe42a29f329cb4bcb9e908b36fc16b7 Mon Sep 17 00:00:00 2001 From: murgatroid99 Date: Mon, 4 Apr 2016 11:27:51 -0700 Subject: Make ruby library conform to status code spec --- src/ruby/lib/grpc/generic/rpc_server.rb | 4 ++-- src/ruby/spec/generic/rpc_server_spec.rb | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/ruby/lib/grpc/generic/rpc_server.rb b/src/ruby/lib/grpc/generic/rpc_server.rb index 4b5578b018..5ba77db173 100644 --- a/src/ruby/lib/grpc/generic/rpc_server.rb +++ b/src/ruby/lib/grpc/generic/rpc_server.rb @@ -403,7 +403,7 @@ module GRPC loop_handle_server_calls end - # Sends UNAVAILABLE if there are too many unprocessed jobs + # Sends RESOURCE_EXHAUSTED if there are too many unprocessed jobs def available?(an_rpc) jobs_count, max = @pool.jobs_waiting, @max_waiting_requests GRPC.logger.info("waiting: #{jobs_count}, max: #{max}") @@ -411,7 +411,7 @@ module GRPC GRPC.logger.warn("NOT AVAILABLE: too many jobs_waiting: #{an_rpc}") noop = proc { |x| x } c = ActiveCall.new(an_rpc.call, @cq, noop, noop, an_rpc.deadline) - c.send_status(StatusCodes::UNAVAILABLE, '') + c.send_status(StatusCodes::RESOURCE_EXHAUSTED, '') nil end diff --git a/src/ruby/spec/generic/rpc_server_spec.rb b/src/ruby/spec/generic/rpc_server_spec.rb index e16ba60387..e688057cb1 100644 --- a/src/ruby/spec/generic/rpc_server_spec.rb +++ b/src/ruby/spec/generic/rpc_server_spec.rb @@ -426,7 +426,7 @@ describe GRPC::RpcServer do threads.each(&:join) end - it 'should return UNAVAILABLE on too many jobs', server: true do + it 'should return RESOURCE_EXHAUSTED on too many jobs', server: true do opts = { a_channel_arg: 'an_arg', server_override: @server, @@ -449,7 +449,8 @@ describe GRPC::RpcServer do begin stub.an_rpc(req) rescue GRPC::BadStatus => e - one_failed_as_unavailable = e.code == StatusCodes::UNAVAILABLE + one_failed_as_unavailable = + e.code == StatusCodes::RESOURCE_EXHAUSTED end end end -- cgit v1.2.3 From 73cf3db0a52f70c3fad9bbe63981d92f8ae86f7e Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 4 Apr 2016 23:31:35 -0700 Subject: Fix --- src/core/ext/lb_policy/pick_first/pick_first.c | 1 - 1 file changed, 1 deletion(-) (limited to 'src') diff --git a/src/core/ext/lb_policy/pick_first/pick_first.c b/src/core/ext/lb_policy/pick_first/pick_first.c index 53c14f8f0a..9ff5590ae0 100644 --- a/src/core/ext/lb_policy/pick_first/pick_first.c +++ b/src/core/ext/lb_policy/pick_first/pick_first.c @@ -164,7 +164,6 @@ static void pf_cancel_picks(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, initial_metadata_flags_eq) { grpc_pollset_set_del_pollset(exec_ctx, p->base.interested_parties, pp->pollset); - *pp->target = NULL; grpc_exec_ctx_enqueue(exec_ctx, pp->on_complete, false, NULL); gpr_free(pp); } else { -- cgit v1.2.3 From 084aa62861b26e10030f15c14f367de8cb92d81d Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Tue, 5 Apr 2016 08:36:49 -0700 Subject: Remove unnecessary -2016 from copyrights --- README.md | 2 +- src/core/lib/iomgr/ev_poll_and_epoll_posix.c | 2 +- src/core/lib/iomgr/ev_posix.c | 2 +- src/core/lib/iomgr/ev_posix.h | 2 +- src/csharp/grpc.native.csharp/grpc.native.csharp.nuspec | 2 +- src/python/grpcio/grpc/beta/implementations.py | 2 +- src/python/grpcio/tests/interop/_secure_interop_test.py | 2 +- src/python/grpcio/tests/interop/client.py | 2 +- src/python/grpcio/tests/unit/beta/_beta_features_test.py | 2 +- src/python/grpcio/tests/unit/beta/_face_interface_test.py | 2 +- test/core/end2end/fixtures/proxy.c | 2 +- test/core/end2end/tests/idempotent_request.c | 2 +- test/core/internal_api_canaries/iomgr.c | 2 +- test/core/internal_api_canaries/support.c | 2 +- test/core/internal_api_canaries/transport.c | 2 +- test/core/surface/server_test.c | 2 +- tools/gce/create_interop_worker.sh | 2 +- tools/run_tests/performance/build_performance.sh | 2 +- tools/run_tests/performance/remote_host_build.sh | 2 +- tools/run_tests/performance/remote_host_prepare.sh | 2 +- tools/run_tests/performance/run_worker_csharp.sh | 2 +- tools/run_tests/performance/run_worker_node.sh | 2 +- 22 files changed, 22 insertions(+), 22 deletions(-) (limited to 'src') diff --git a/README.md b/README.md index abb4905392..3ee2b9f5ca 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![Join the chat at https://gitter.im/grpc/grpc](https://badges.gitter.im/grpc/grpc.svg)](https://gitter.im/grpc/grpc?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) -Copyright 2015-2016 Google Inc. +Copyright 2015 Google Inc. #Documentation diff --git a/src/core/lib/iomgr/ev_poll_and_epoll_posix.c b/src/core/lib/iomgr/ev_poll_and_epoll_posix.c index dba335490b..3c8127e1a8 100644 --- a/src/core/lib/iomgr/ev_poll_and_epoll_posix.c +++ b/src/core/lib/iomgr/ev_poll_and_epoll_posix.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/src/core/lib/iomgr/ev_posix.c b/src/core/lib/iomgr/ev_posix.c index 235a7df08d..0eb95a2e09 100644 --- a/src/core/lib/iomgr/ev_posix.c +++ b/src/core/lib/iomgr/ev_posix.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/src/core/lib/iomgr/ev_posix.h b/src/core/lib/iomgr/ev_posix.h index 9d27b2bcda..1fa9f5ef2d 100644 --- a/src/core/lib/iomgr/ev_posix.h +++ b/src/core/lib/iomgr/ev_posix.h @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/src/csharp/grpc.native.csharp/grpc.native.csharp.nuspec b/src/csharp/grpc.native.csharp/grpc.native.csharp.nuspec index 6a1795b709..cc688e2bc7 100644 --- a/src/csharp/grpc.native.csharp/grpc.native.csharp.nuspec +++ b/src/csharp/grpc.native.csharp/grpc.native.csharp.nuspec @@ -10,7 +10,7 @@ false Native extension needed by gRPC C# library. This is not the package you are looking for, it is only meant to be used as a dependency. Release of gRPC C core $version$ libraries. - Copyright 2015-2016 + Copyright 2015 gRPC C# Native Extension Native library required by gRPC C# gRPC native diff --git a/src/python/grpcio/grpc/beta/implementations.py b/src/python/grpcio/grpc/beta/implementations.py index 06ee7aa26e..742e94dc65 100644 --- a/src/python/grpcio/grpc/beta/implementations.py +++ b/src/python/grpcio/grpc/beta/implementations.py @@ -1,4 +1,4 @@ -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/src/python/grpcio/tests/interop/_secure_interop_test.py b/src/python/grpcio/tests/interop/_secure_interop_test.py index 1a1a063a6f..86d7e43351 100644 --- a/src/python/grpcio/tests/interop/_secure_interop_test.py +++ b/src/python/grpcio/tests/interop/_secure_interop_test.py @@ -1,4 +1,4 @@ -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/src/python/grpcio/tests/interop/client.py b/src/python/grpcio/tests/interop/client.py index 02a37cc6bc..1d10d7e45d 100644 --- a/src/python/grpcio/tests/interop/client.py +++ b/src/python/grpcio/tests/interop/client.py @@ -1,4 +1,4 @@ -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/src/python/grpcio/tests/unit/beta/_beta_features_test.py b/src/python/grpcio/tests/unit/beta/_beta_features_test.py index b8b77a96c1..bb2893a21b 100644 --- a/src/python/grpcio/tests/unit/beta/_beta_features_test.py +++ b/src/python/grpcio/tests/unit/beta/_beta_features_test.py @@ -1,4 +1,4 @@ -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/src/python/grpcio/tests/unit/beta/_face_interface_test.py b/src/python/grpcio/tests/unit/beta/_face_interface_test.py index ea19ee47ae..3a67516906 100644 --- a/src/python/grpcio/tests/unit/beta/_face_interface_test.py +++ b/src/python/grpcio/tests/unit/beta/_face_interface_test.py @@ -1,4 +1,4 @@ -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/test/core/end2end/fixtures/proxy.c b/test/core/end2end/fixtures/proxy.c index 1ca53cdad9..a6487a17ac 100644 --- a/test/core/end2end/fixtures/proxy.c +++ b/test/core/end2end/fixtures/proxy.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/end2end/tests/idempotent_request.c b/test/core/end2end/tests/idempotent_request.c index 485a854441..1bc6450414 100644 --- a/test/core/end2end/tests/idempotent_request.c +++ b/test/core/end2end/tests/idempotent_request.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/internal_api_canaries/iomgr.c b/test/core/internal_api_canaries/iomgr.c index 04d66994cd..f87a80cd90 100644 --- a/test/core/internal_api_canaries/iomgr.c +++ b/test/core/internal_api_canaries/iomgr.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/internal_api_canaries/support.c b/test/core/internal_api_canaries/support.c index 7e00e0d2ff..c51cbf2522 100644 --- a/test/core/internal_api_canaries/support.c +++ b/test/core/internal_api_canaries/support.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/internal_api_canaries/transport.c b/test/core/internal_api_canaries/transport.c index 01daabaa56..0617865412 100644 --- a/test/core/internal_api_canaries/transport.c +++ b/test/core/internal_api_canaries/transport.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/test/core/surface/server_test.c b/test/core/surface/server_test.c index 4c62d8caad..beb685b338 100644 --- a/test/core/surface/server_test.c +++ b/test/core/surface/server_test.c @@ -1,6 +1,6 @@ /* * - * Copyright 2015-2016, Google Inc. + * Copyright 2015, Google Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/tools/gce/create_interop_worker.sh b/tools/gce/create_interop_worker.sh index 3c49c6102a..9170d82144 100755 --- a/tools/gce/create_interop_worker.sh +++ b/tools/gce/create_interop_worker.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/tools/run_tests/performance/build_performance.sh b/tools/run_tests/performance/build_performance.sh index 829c2e3040..e5c0f86369 100755 --- a/tools/run_tests/performance/build_performance.sh +++ b/tools/run_tests/performance/build_performance.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/tools/run_tests/performance/remote_host_build.sh b/tools/run_tests/performance/remote_host_build.sh index fee4167d33..b8886080a5 100755 --- a/tools/run_tests/performance/remote_host_build.sh +++ b/tools/run_tests/performance/remote_host_build.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/tools/run_tests/performance/remote_host_prepare.sh b/tools/run_tests/performance/remote_host_prepare.sh index c70e1d3963..18633d1420 100755 --- a/tools/run_tests/performance/remote_host_prepare.sh +++ b/tools/run_tests/performance/remote_host_prepare.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/tools/run_tests/performance/run_worker_csharp.sh b/tools/run_tests/performance/run_worker_csharp.sh index ce34b203c3..b91df09b42 100755 --- a/tools/run_tests/performance/run_worker_csharp.sh +++ b/tools/run_tests/performance/run_worker_csharp.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without diff --git a/tools/run_tests/performance/run_worker_node.sh b/tools/run_tests/performance/run_worker_node.sh index 36bf1b20a0..46b6ff0177 100755 --- a/tools/run_tests/performance/run_worker_node.sh +++ b/tools/run_tests/performance/run_worker_node.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2015-2016, Google Inc. +# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without -- cgit v1.2.3 From 27137fbc85603afdac32543c91cd5128d936f6ba Mon Sep 17 00:00:00 2001 From: Sree Kuchibhotla Date: Tue, 5 Apr 2016 09:59:05 -0700 Subject: Fix a typo in metrics.proto. No code is using double_value yet and hence no other code changes are needed --- src/proto/grpc/testing/metrics.proto | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/proto/grpc/testing/metrics.proto b/src/proto/grpc/testing/metrics.proto index 0cc4b60239..1202b20b8f 100644 --- a/src/proto/grpc/testing/metrics.proto +++ b/src/proto/grpc/testing/metrics.proto @@ -1,4 +1,4 @@ -// Copyright 2015, Google Inc. +// Copyright 2015-2016, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without @@ -42,7 +42,7 @@ message GaugeResponse { string name = 1; oneof value { int64 long_value = 2; - double double_vale = 3; + double double_value = 3; string string_value = 4; } } -- cgit v1.2.3 From e81adf3b7b61ff3b0f8918c085fcd7004b2ed53d Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Mon, 4 Apr 2016 15:59:50 -0700 Subject: Add more features for C# performance worker --- .../Grpc.IntegrationTesting/ClientRunners.cs | 123 +++++++++++------ .../Grpc.IntegrationTesting.csproj | 1 + .../Grpc.IntegrationTesting/InterarrivalTimers.cs | 150 +++++++++++++++++++++ 3 files changed, 235 insertions(+), 39 deletions(-) create mode 100644 src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs (limited to 'src') diff --git a/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs b/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs index 0bcacf76e5..f954ca5f34 100644 --- a/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs +++ b/src/csharp/Grpc.IntegrationTesting/ClientRunners.cs @@ -61,15 +61,7 @@ namespace Grpc.IntegrationTesting public static IClientRunner CreateStarted(ClientConfig config) { Logger.Debug("ClientConfig: {0}", config); - string target = config.ServerTargets.Single(); - GrpcPreconditions.CheckArgument(config.LoadParams.LoadCase == LoadParams.LoadOneofCase.ClosedLoop, - "Only closed loop scenario supported for C#"); - GrpcPreconditions.CheckArgument(config.ClientChannels == 1, "ClientConfig.ClientChannels needs to be 1"); - if (config.OutstandingRpcsPerChannel != 0) - { - Logger.Warning("ClientConfig.OutstandingRpcsPerChannel is not supported for C#. Ignoring the value"); - } if (config.AsyncClientThreads != 0) { Logger.Warning("ClientConfig.AsyncClientThreads is not supported for C#. Ignoring the value"); @@ -83,22 +75,40 @@ namespace Grpc.IntegrationTesting Logger.Warning("ClientConfig.CoreList is not supported for C#. Ignoring the value"); } - var credentials = config.SecurityParams != null ? TestCredentials.CreateSslCredentials() : ChannelCredentials.Insecure; + var channels = CreateChannels(config.ClientChannels, config.ServerTargets, config.SecurityParams); + + return new ClientRunnerImpl(channels, + config.ClientType, + config.RpcType, + config.OutstandingRpcsPerChannel, + config.LoadParams, + config.PayloadConfig, + config.HistogramParams); + } + + private static List CreateChannels(int clientChannels, IEnumerable serverTargets, SecurityParams securityParams) + { + GrpcPreconditions.CheckArgument(clientChannels > 0, "clientChannels needs to be at least 1."); + GrpcPreconditions.CheckArgument(serverTargets.Count() > 0, "at least one serverTarget needs to be specified."); + + var credentials = securityParams != null ? TestCredentials.CreateSslCredentials() : ChannelCredentials.Insecure; List channelOptions = null; - if (config.SecurityParams != null && config.SecurityParams.ServerHostOverride != "") + if (securityParams != null && securityParams.ServerHostOverride != "") { channelOptions = new List { - new ChannelOption(ChannelOptions.SslTargetNameOverride, config.SecurityParams.ServerHostOverride) + new ChannelOption(ChannelOptions.SslTargetNameOverride, securityParams.ServerHostOverride) }; } - var channel = new Channel(target, credentials, channelOptions); - return new ClientRunnerImpl(channel, - config.ClientType, - config.RpcType, - config.PayloadConfig, - config.HistogramParams); + var result = new List(); + for (int i = 0; i < clientChannels; i++) + { + var target = serverTargets.ElementAt(i % serverTargets.Count()); + var channel = new Channel(target, credentials, channelOptions); + result.Add(channel); + } + return result; } } @@ -106,30 +116,35 @@ namespace Grpc.IntegrationTesting { const double SecondsToNanos = 1e9; - readonly Channel channel; + readonly List channels; readonly ClientType clientType; readonly RpcType rpcType; readonly PayloadConfig payloadConfig; readonly Histogram histogram; - readonly BenchmarkService.BenchmarkServiceClient client; - readonly Task runnerTask; - readonly CancellationTokenSource stoppedCts; + readonly List runnerTasks; + readonly CancellationTokenSource stoppedCts = new CancellationTokenSource(); readonly WallClockStopwatch wallClockStopwatch = new WallClockStopwatch(); - public ClientRunnerImpl(Channel channel, ClientType clientType, RpcType rpcType, PayloadConfig payloadConfig, HistogramParams histogramParams) + public ClientRunnerImpl(List channels, ClientType clientType, RpcType rpcType, int outstandingRpcsPerChannel, LoadParams loadParams, PayloadConfig payloadConfig, HistogramParams histogramParams) { - this.channel = GrpcPreconditions.CheckNotNull(channel); + GrpcPreconditions.CheckArgument(outstandingRpcsPerChannel > 0, "outstandingRpcsPerChannel"); + this.channels = new List(channels); this.clientType = clientType; this.rpcType = rpcType; this.payloadConfig = payloadConfig; this.histogram = new Histogram(histogramParams.Resolution, histogramParams.MaxPossible); - this.stoppedCts = new CancellationTokenSource(); - this.client = BenchmarkService.NewClient(channel); - - var threadBody = GetThreadBody(); - this.runnerTask = Task.Factory.StartNew(threadBody, TaskCreationOptions.LongRunning); + this.runnerTasks = new List(); + foreach (var channel in this.channels) + { + for (int i = 0; i < outstandingRpcsPerChannel; i++) + { + var timer = CreateTimer(loadParams, 1.0 / this.channels.Count / outstandingRpcsPerChannel); + var threadBody = GetThreadBody(channel, timer); + this.runnerTasks.Add(Task.Factory.StartNew(threadBody, TaskCreationOptions.LongRunning)); + } + } } public ClientStats GetStats(bool reset) @@ -150,12 +165,19 @@ namespace Grpc.IntegrationTesting public async Task StopAsync() { stoppedCts.Cancel(); - await runnerTask; - await channel.ShutdownAsync(); + foreach (var runnerTask in runnerTasks) + { + await runnerTask; + } + foreach (var channel in channels) + { + await channel.ShutdownAsync(); + } } - private void RunClosedLoopUnary() + private void RunUnary(Channel channel, IInterarrivalTimer timer) { + var client = BenchmarkService.NewClient(channel); var request = CreateSimpleRequest(); var stopwatch = new Stopwatch(); @@ -167,11 +189,14 @@ namespace Grpc.IntegrationTesting // spec requires data point in nanoseconds. histogram.AddObservation(stopwatch.Elapsed.TotalSeconds * SecondsToNanos); + + timer.WaitForNext(); } } - private async Task RunClosedLoopUnaryAsync() + private async Task RunUnaryAsync(Channel channel, IInterarrivalTimer timer) { + var client = BenchmarkService.NewClient(channel); var request = CreateSimpleRequest(); var stopwatch = new Stopwatch(); @@ -183,11 +208,14 @@ namespace Grpc.IntegrationTesting // spec requires data point in nanoseconds. histogram.AddObservation(stopwatch.Elapsed.TotalSeconds * SecondsToNanos); + + await timer.WaitForNextAsync(); } } - private async Task RunClosedLoopStreamingAsync() + private async Task RunStreamingPingPongAsync(Channel channel, IInterarrivalTimer timer) { + var client = BenchmarkService.NewClient(channel); var request = CreateSimpleRequest(); var stopwatch = new Stopwatch(); @@ -202,6 +230,8 @@ namespace Grpc.IntegrationTesting // spec requires data point in nanoseconds. histogram.AddObservation(stopwatch.Elapsed.TotalSeconds * SecondsToNanos); + + await timer.WaitForNextAsync(); } // finish the streaming call @@ -210,7 +240,7 @@ namespace Grpc.IntegrationTesting } } - private async Task RunGenericClosedLoopStreamingAsync() + private async Task RunGenericStreamingAsync(Channel channel, IInterarrivalTimer timer) { var request = CreateByteBufferRequest(); var stopwatch = new Stopwatch(); @@ -228,6 +258,8 @@ namespace Grpc.IntegrationTesting // spec requires data point in nanoseconds. histogram.AddObservation(stopwatch.Elapsed.TotalSeconds * SecondsToNanos); + + await timer.WaitForNextAsync(); } // finish the streaming call @@ -236,7 +268,7 @@ namespace Grpc.IntegrationTesting } } - private Action GetThreadBody() + private Action GetThreadBody(Channel channel, IInterarrivalTimer timer) { if (payloadConfig.PayloadCase == PayloadConfig.PayloadOneofCase.BytebufParams) { @@ -244,7 +276,7 @@ namespace Grpc.IntegrationTesting GrpcPreconditions.CheckArgument(rpcType == RpcType.STREAMING, "Generic client only supports streaming calls"); return () => { - RunGenericClosedLoopStreamingAsync().Wait(); + RunGenericStreamingAsync(channel, timer).Wait(); }; } @@ -252,7 +284,7 @@ namespace Grpc.IntegrationTesting if (clientType == ClientType.SYNC_CLIENT) { GrpcPreconditions.CheckArgument(rpcType == RpcType.UNARY, "Sync client can only be used for Unary calls in C#"); - return RunClosedLoopUnary; + return () => RunUnary(channel, timer); } else if (clientType == ClientType.ASYNC_CLIENT) { @@ -261,12 +293,12 @@ namespace Grpc.IntegrationTesting case RpcType.UNARY: return () => { - RunClosedLoopUnaryAsync().Wait(); + RunUnaryAsync(channel, timer).Wait(); }; case RpcType.STREAMING: return () => { - RunClosedLoopStreamingAsync().Wait(); + RunStreamingPingPongAsync(channel, timer).Wait(); }; } } @@ -292,5 +324,18 @@ namespace Grpc.IntegrationTesting { return new Payload { Body = ByteString.CopyFrom(new byte[size]) }; } + + private static IInterarrivalTimer CreateTimer(LoadParams loadParams, double loadMultiplier) + { + switch (loadParams.LoadCase) + { + case LoadParams.LoadOneofCase.ClosedLoop: + return new ClosedLoopInterarrivalTimer(); + case LoadParams.LoadOneofCase.Poisson: + return new PoissonInterarrivalTimer(loadParams.Poisson.OfferedLoad * loadMultiplier); + default: + throw new ArgumentException("Unknown load type"); + } + } } } diff --git a/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj b/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj index 64d14b0df5..7ea80b11f0 100644 --- a/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj +++ b/src/csharp/Grpc.IntegrationTesting/Grpc.IntegrationTesting.csproj @@ -115,6 +115,7 @@ + diff --git a/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs b/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs new file mode 100644 index 0000000000..e8d7cbe8bb --- /dev/null +++ b/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs @@ -0,0 +1,150 @@ +#region Copyright notice and license + +// Copyright 2016, Google Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#endregion + +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.IO; +using System.Linq; +using System.Text.RegularExpressions; +using System.Threading; +using System.Threading.Tasks; +using Google.Protobuf; +using Grpc.Core; +using Grpc.Core.Utils; +using Grpc.Testing; + +namespace Grpc.IntegrationTesting +{ + public interface IInterarrivalTimer + { + void WaitForNext(); + + Task WaitForNextAsync(); + } + + /// + /// Interarrival timer that doesn't wait at all. + /// + public class ClosedLoopInterarrivalTimer : IInterarrivalTimer + { + public ClosedLoopInterarrivalTimer() + { + } + + public void WaitForNext() + { + // NOP + } + + public Task WaitForNextAsync() + { + return Task.FromResult(null); + } + } + + /// + /// Interarrival timer that generates Poisson process load. + /// + public class PoissonInterarrivalTimer : IInterarrivalTimer + { + const double NanosToSeconds = 1e-9; + + readonly ExponentialDistribution exponentialDistribution; + DateTime? lastEventTime; + + public PoissonInterarrivalTimer(double offeredLoad) + { + this.exponentialDistribution = new ExponentialDistribution(new Random(), offeredLoad); + this.lastEventTime = DateTime.UtcNow; + } + + public void WaitForNext() + { + var waitDuration = GetNextWaitDuration(); + int millisTimeout = (int) Math.Round(waitDuration.TotalMilliseconds); + if (millisTimeout > 0) + { + // TODO(jtattermusch): probably only works well for a relatively low interarrival rate + Thread.Sleep(millisTimeout); + } + } + + public async Task WaitForNextAsync() + { + var waitDuration = GetNextWaitDuration(); + int millisTimeout = (int) Math.Round(waitDuration.TotalMilliseconds); + if (millisTimeout > 0) + { + // TODO(jtattermusch): probably only works well for a relatively low interarrival rate + await Task.Delay(millisTimeout); + } + } + + private TimeSpan GetNextWaitDuration() + { + if (!lastEventTime.HasValue) + { + this.lastEventTime = DateTime.Now; + } + + var origLastEventTime = this.lastEventTime.Value; + this.lastEventTime = origLastEventTime + TimeSpan.FromSeconds(exponentialDistribution.Next() * NanosToSeconds); + return this.lastEventTime.Value - origLastEventTime; + } + + /// + /// Exp generator. + /// + private class ExponentialDistribution + { + readonly Random random; + readonly double lambda; + readonly double lambdaReciprocal; + + public ExponentialDistribution(Random random, double lambda) + { + this.random = random; + this.lambda = lambda; + this.lambdaReciprocal = 1.0 / lambda; + } + + public double Next() + { + double uniform = random.NextDouble(); + // Use 1.0-uni above to avoid NaN if uni is 0 + return lambdaReciprocal * (-Math.Log(1.0 - uniform)); + } + } + } +} -- cgit v1.2.3 From eff9cf0d6794203b17d17d129a311ccf9fb9c33f Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 5 Apr 2016 10:37:35 -0700 Subject: make interarrival timer generate the right QPS with poisson load --- src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src') diff --git a/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs b/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs index e8d7cbe8bb..6492d34890 100644 --- a/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs +++ b/src/csharp/Grpc.IntegrationTesting/InterarrivalTimers.cs @@ -78,8 +78,6 @@ namespace Grpc.IntegrationTesting /// public class PoissonInterarrivalTimer : IInterarrivalTimer { - const double NanosToSeconds = 1e-9; - readonly ExponentialDistribution exponentialDistribution; DateTime? lastEventTime; @@ -119,7 +117,7 @@ namespace Grpc.IntegrationTesting } var origLastEventTime = this.lastEventTime.Value; - this.lastEventTime = origLastEventTime + TimeSpan.FromSeconds(exponentialDistribution.Next() * NanosToSeconds); + this.lastEventTime = origLastEventTime + TimeSpan.FromSeconds(exponentialDistribution.Next()); return this.lastEventTime.Value - origLastEventTime; } -- cgit v1.2.3 From bf2e73d8ae1bd7f318087077c45b67c4a422d3f7 Mon Sep 17 00:00:00 2001 From: David Garcia Quintas Date: Mon, 4 Apr 2016 18:03:47 -0700 Subject: Added fuzzers for load_balancer_api parsing functions --- Makefile | 134 + build.yaml | 24 + src/core/ext/lb_policy/grpclb/load_balancer_api.c | 25 +- .../0c35544f40d428d103e9c5b969ad9cd16767b110 | Bin 0 -> 51 bytes .../0c60ee9ed55c9af6190b132ef6636c1d2abe4540 | 1 + .../0ecb3e69889c036a86d21eb942077dc9abd649be | Bin 0 -> 36 bytes .../1324c95dafe597fe05f9babe92fe6fbf181c1897 | 1 + .../14eb42f7423081b455820daa2c02b358315dc0fa | 1 + .../23121c5f633db5d7c1a9f2225240754246fee513 | Bin 0 -> 42 bytes .../235548307ee9f2b0855fded42a871990d9ade956 | Bin 0 -> 64 bytes .../28ed3a797da3c48c309a4ef792147f3c56cfec40 | 1 + .../2bf123dbfa1d37a04493b5662a4b3b9c147485fc | Bin 0 -> 64 bytes .../2d4c0908ecc0310ea234d10b6bdb4f4ca3c41dd1 | 1 + .../304e8cdc9122b709ec2c063a5c8c38489a788033 | Bin 0 -> 43 bytes .../324d4a2aed8bc1840fee212fd38dadec80a72ea2 | Bin 0 -> 50 bytes .../33353a0b011901a13d010c6b165074ccdaa717ac | 1 + .../37dfead09389fcd9b9d24ef817a0fed13d8ff2b0 | Bin 0 -> 42 bytes .../47879cc364be304754f6af15563ad6f9a538da41 | Bin 0 -> 44 bytes .../49a5cef4c730ecab22712b156ddba5106f165afd | 1 + .../4bbbbb794a098deeacff73b774c30f12c54ceacb | 1 + .../4c498ce69c8476f745693deb23272930e05cad60 | Bin 0 -> 42 bytes .../4fb5e3085c32e9bccac9e18343cca07017d037de | Bin 0 -> 44 bytes .../4fe5e46c1299e7f3e8a41dde3ae1bf1b60b4a43c | 1 + .../670cc6bae958cb4f15e7297fe63959ac5799aa42 | Bin 0 -> 44 bytes .../675f3263af7d1bbb084872f2b23f6d363227e85d | Bin 0 -> 42 bytes .../67fe0d2acc727c8a39a707b92c6cebda9bd20986 | 1 + .../6d15065785eb8f4b5f17357a520cb4815a2cb355 | 1 + .../73285d7a70d73b517648067520d921e4477dbbfa | Bin 0 -> 7 bytes .../747d1ed8bee4c6f0438beaf88ae76d8ef9f63da2 | 1 + .../763878a34b3adeb99a03b54d09768a4451617016 | 1 + .../7b4b0c2555178333ba15203a930c88ef7e7500e7 | Bin 0 -> 43 bytes .../7b8a91aa46e370eb61307b4998889dc89775462f | 1 + .../7cd11836c64f98742fa7beccec5c981ef4dd62ae | Bin 0 -> 37 bytes .../7d8f4f045e70e8a2cb45dc3c001504f5c2614b16 | Bin 0 -> 16 bytes .../7e9848558fb004e14795b3ebd3e1488dcde1db8c | 1 + .../89734c37ee267e69a6950c6d60ee541c1be5ccff | Bin 0 -> 44 bytes .../9034aaf45143996a2b14465c352ab0c6fa26b221 | 1 + .../91e3b6a3484ab4b95cdeecc5aefe1291824060e8 | 1 + .../95cd94c858e5e97f7df4a5eb7552e5e0d5ce1ec4 | 1 + .../971f42d5a4d9816145ebc9dd28ba33ed3f5860b0 | Bin 0 -> 44 bytes .../9db3a1854de87fd643b910aeab50553afc73e667 | Bin 0 -> 52 bytes .../a147873135c6c52d4da03c260a0165bc0ab1b979 | Bin 0 -> 44 bytes .../a710eead945dabbbffa213a980c75f9463a27398 | 1 + .../a72406e3ca06d941fe8e168bbf67da88a81c947b | 1 + .../a8a62a7ebb7d68b211ae319e082575935c07d188 | Bin 0 -> 60 bytes .../a8abd012eb59b862bf9bc1ea443d2f35a1a2e222 | 1 + .../aab56035a3533b5d83a32a439f179eb678250113 | Bin 0 -> 42 bytes .../ac174acef2c5da26fadc7270bab9c8c4e938c463 | 1 + .../acbbd60eeb76e41ce254d0fef353b92abe69c831 | 2 + .../c1eed32e1e353737987da851ad760312ea8e557c | 1 + .../c4214ace2c4bab24bb356f71aedca08544baad70 | 1 + .../c4f87a6290aee1acfc1f26083974ce94621fca64 | 1 + .../d285d78d3ba966b4b199453d38ead1aa36a7484f | Bin 0 -> 63 bytes .../df5200f371cff3cae0e1595cd86d641725f5d1ba | 1 + .../dfc66cb172919102f3ba14f6816228aa46f78154 | 1 + .../e53e789a4c175c6a2c468472f1047d0fe8db1177 | Bin 0 -> 3 bytes .../e67fe6794e755ea801272980f2c272edb027f6dc | 1 + .../ead61e86fedf118df8e44ed70ce002be651cf291 | Bin 0 -> 44 bytes .../eced8b29efbdc82eb8a1d0865c5f382f0ff78446 | 1 + .../f58a9135d07ea9a5e3e710f6b3bf6d48d5942dfd | Bin 0 -> 44 bytes .../f8c2c4ddd2f474b4839f13a9be862c00ab0ece77 | Bin 0 -> 2 bytes .../faa1781e1444bba5b8c677bc5e2a38d023a1ec65 | 1 + .../fccda587af845f0685275960649d8f4a45272a95 | 1 + .../000def12957806bb0d40005cb651d35b4cde7b4e | 3 + .../0068af2acc3020f344ee84b2c8adfb90492354c3 | 1 + .../009132022c3a1660b701728ac92e26baf82e8eac | Bin 0 -> 64 bytes .../00bf0233aa1155b34a3081e4a2b7a1c9cdf8ea1e | 2 + .../013197cfb12b59755b807501c6d6615859f9cd3f | 1 + .../018a4332eb19f2398162317cb6ad2e8cf700dfd6 | 1 + .../0273d3496bf5f4594e59083ac319f8f863a15be0 | 1 + .../0355002521e74dcdb3a0c633338bd02ab1d85312 | 3 + .../053d8d6ceeba9453c97d0ee5374db863e6f77ad4 | Bin 0 -> 2 bytes .../0628c29e3ae264f8fa08652435bb3e61afe60883 | 1 + .../065e91578e5359b70a668164310af6f0dd40e922 | 2 + .../06b4b617d5937da8a7b58aed5341dc5ef6d1bcd7 | 1 + .../07216a4f5934890b89d845f6256546c2681350ce | 3 + .../08584e8308b7f52f0fe380358800d7f585cba89c | 1 + .../085a37568e99ec5855bd96affd259921515479e8 | 2 + .../0903d1e9297179c18de6a3707b16f27d0d54ed67 | 1 + .../0aa20a75bff4e8af10330c66d288e900146f1a39 | 1 + .../0ae76e2b24ca999bd5e09e517aa4d88f5b5f58a4 | 1 + .../0c3025fdfb008a6563ea2a2bb6cbc79b8ccbf8f3 | 2 + .../0d219165cd317142afa36b8b5476cc022c95c4e6 | Bin 0 -> 26 bytes .../0e053123dd6256de5aff55b0731f913de250c18e | 2 + .../0e065f98325849ac05eed515865b33dba0264cd4 | 1 + .../0e4ff715d491c9f0b471c400b71804739b6d400a | 2 + .../0ec94942046cd7e00bc058204c1d046075ca9531 | 1 + .../0f0e8da530eb8c924cee6985d9c3dfd93274ef8c | 1 + .../0ff365225c981d74b89499d1e708684ed4d0b570 | 2 + .../113b1efff1677c1b9a24f89aec0c3ecc228ddf62 | 2 + .../11697d621eab6743ba22715722d5b23830b79075 | 1 + .../12463318b795c756f389bc0fb1cca9645eafef28 | 1 + .../12784250cf16ec999529f601ae5c5798e853d34a | 1 + .../13122d08c1cee0dae6434605917d4cc6d8ea8cc5 | 1 + .../148a1118649dd8aa9b4ed778efdf7c1611aa5d27 | Bin 0 -> 61 bytes .../15dea2bb5fb36a3dd5172796da66a821a32918e7 | 2 + .../16488fe15a7e33cb41f2b7c159c99154464b3fd3 | 1 + .../1870a48a3c9c1dd9027cbd85beb503b43cff6e89 | 2 + .../1900b6a9123667a79020319aa7fd54d230bc7073 | 2 + .../1a000f1cbccd2ab6f7e623e015ed2e84284c9dbf | 2 + .../1c1d403f6175d52ac4430d1ef2401b549761707e | Bin 0 -> 63 bytes .../1c2ae0e1915e18dffc2215e9121f1afe0e4335c4 | 3 + .../1c5d2eef52426db9d0842f3d57b27a219434c512 | 1 + .../1d0676867c1ebce84531035fa7eb86ed00762df5 | 1 + .../1d92b263fa70450b0d0aeb81bf5d2f69eefbbd99 | 1 + .../1e843ed4864d6a808b671dd6769ae191ac8a13ad | 1 + .../1eb06a34ee568d584c4b33472788889bc68af3f5 | 3 + .../2169c2b4d560d74a5487df68b56f3af1d648f544 | 1 + .../21f8f7583e58c1c81a3ac8237b5fa58071edf8a4 | 1 + .../231e348407fdcb14412c691b0b20982940160ccd | 1 + .../27b8f060e3296eaef77dcdd4c2cd11d5650604ac | 2 + .../28ed3a797da3c48c309a4ef792147f3c56cfec40 | 1 + .../291fcc6e043942638fa3c865c0a1be5e4dcc0e70 | 2 + .../2a7f6c1f8fdc090b24ceb90ab4f3a7b331c06c86 | 2 + .../2b85f180fe56f84925b274819ce10a8972a594e7 | 1 + .../2dea73d7d10ba0dcfd103f7542bdf7458e772b2b | 1 + .../2e9c19f98ef88b83ec2dea8b1b7f92b8337f757b | 1 + .../2fbd59ffb74aba392b86f4fe2ff8067b6d45cce8 | 3 + .../31059c32ea28d37b7442f51b20e966665662783c | 1 + .../31f78e35feb36037864df5f8f47136f8e6e4768a | 2 + .../326d322d1aa31696a14518830e544770f12146ee | Bin 0 -> 64 bytes .../337df26552e0884ff133cc1be8e72020be38f457 | 1 + .../33a2a0aa86956097e034b5ee16aeceacee7efc34 | 2 + .../33d175d1ecb3a85be7dd93d24efc3ddda0a85ad6 | 1 + .../3718a1b790db16bcfc4ec30691fab24ea7bb0b74 | 3 + .../37aa3946054035b712102a62b71c94747dfd1491 | 3 + .../37b697adc0708ad12e4ed7355f3f8fdf1b7919ca | 1 + .../37bf4642c5e5a806e2042cdf5ead9bf3c97b9ac1 | 2 + .../37d94ca6a20303389b35404f3dfd20aaa9ff0851 | 1 + .../39278604f6a1102366464bbe769ae846e542bc56 | 2 + .../396b57d9a11a1b135e36ad266e155cc0c3b77d21 | 2 + .../39a49db120a807fe4e80c502254a5009625c7599 | 1 + .../39f04d1c6d4beefa3e3d6eae3a5317d969787055 | 3 + .../3b199b80209fa0b8ffedba4381019f8729cc09d6 | 1 + .../3ccf7ffb96c3e4789409db33cc12bfd8ddc24c1a | 1 + .../3d04382d1fe11ff3b717100aece7f9eff2d04b9b | 4 + .../3d4eb9f836bb40cf4c734073bcba8b73e4cc93ae | 1 + .../41dc8c55e41d32c30865f9761931ddd4c5b740f8 | 1 + .../41ef7b74d212f8f7f6681edcffd0db719030d31d | 1 + .../431187b5926fa7d0823305a9f87635616ea3ef27 | Bin 0 -> 63 bytes .../44c6da04b8378986721f7225e70a1514695c176c | 1 + .../450161236e37a1dfc0da6398c4876df82ff640ac | 1 + .../45257a176ca6a05ec65a6df430bbb6b85d0a676f | 2 + .../46d1c2f2edcc9cdc0d1698fa0c8853cb19a6e7d9 | 1 + .../4764bd4297bf0c405348d2bb87b8fbc02beadcb8 | 2 + .../48199bfd0e2c160f56d03e881bb5dfe276eec462 | 2 + .../48e865c56e8db13640d6ecbfc0f2486eb77e07d1 | 2 + .../499b003b8b98edd9dbe2668c8c6af948769d7e87 | 1 + .../4a55591c4b390c5a36cecc6f1b6f5105300b546b | 1 + .../4d33f97ec69c64e14dcf205be36a6319ddb8a20d | 1 + .../4dbfb08904739928e19c2f459040b35ac410f699 | 3 + .../501bd6fe1de2719cf8d2c517a071e5d883fbe766 | 1 + .../5208871ea8948223b64b304336cea41ac3240244 | 1 + .../5348c71be34967458403bd4b58bb2a8a744d35ee | 1 + .../54362c2f6965268d0835a992c3ba656171b8f044 | 4 + .../54411aa13f6d9118028171935322bbbc74c15329 | 2 + .../54c50af22d147f192918499b4b3819eb389468a4 | 1 + .../55441aac903d96b36bf8a11bc804234bcf0c04da | 1 + .../56e1a7c279482a57fcbca43468df96a791ee22b4 | 1 + .../57cbea7c563d5c4b6b290271b0009c3f348d92da | 2 + .../57e11c7a62f0fc807d7b51bb1ef0f0e22f43795b | 3 + .../585183c1a240df6926689fe1bd8cb434664db4d8 | 1 + .../5b2ee8ca40508bf108a729dcb228191670ec34d6 | 1 + .../5b47eabaf74479348fd0318f174d649dbe96e7d2 | 2 + .../5ba93c9db0cff93f52b521d7420e43f6eda2784f | Bin 0 -> 1 bytes .../5cc827e33932ccf8c72c6a839074e856d93463d8 | 1 + .../5cc89bbf687f94ff87241a8f935905e1c441de33 | 3 + .../5ec6596f12462fe9f36924c262f97408b54bbba8 | 3 + .../5f8f3af69295223fb04c37d28035bb75b4cbd705 | 2 + .../5fd76d48b9fefecbdabd4511decc161b25db79dd | 2 + .../614cf839ccac2d896d61a0ba0ab1f42b2fabafea | 1 + .../618305cc2d3d3814d78b77ffbf421b769bd862cf | 2 + .../61dfcd913c4f0a8d005bd089c34e95d8dbbf1897 | 1 + .../65a89e10aab00039680e1f7d014737b634c74d8d | 1 + .../66a273dbf5e37410efd45518a42b06a65cffe1f0 | 3 + .../673ff0de0702e8098892060a5365c175d8ef18fc | 1 + .../68465c782c37bfdd98ac493b0458444bb94336e5 | 2 + .../688451dee13d0be420598c6e205a3bc419173e18 | 1 + .../68a1d9150e1380c219e0a1deb3993f321e000ecd | 2 + .../69f49bf7ae8886f5b4c6296fdb1c570256919604 | 2 + .../6a425f414cd69ffffdbaa34d03eb43841b432e11 | 1 + .../6ca9e6e85f9b007a0920b0112decbd1403d506da | 1 + .../6cd62e3d67b4154639adbe753115bfdd770edddb | 1 + .../6d4f2de4cc427417d6335ff5396ea2588509bb5b | 2 + .../6ea84030dd0b5b03e4720c244ea8b4ec65e1f236 | 1 + .../710c1fc8cf7dc1386312c34de5057933fcf868b3 | 2 + .../720e81dcaf83f867288a90293c5de3b088d5c556 | 1 + .../72cdc8f78ab5237f96ed354264c726ac79ec429c | 1 + .../73535a4f7af7e4c6aa23556cacd63f6929ac33fe | 1 + .../73d7b933a5673a4d6f5905006ef6266dda1e4fba | Bin 0 -> 22 bytes .../753aea13c82d1f8841c2bd4309b1b55d0ae2ba8d | Bin 0 -> 64 bytes .../754428e00e8a1d0471e00bd9e8f060ab88ab640e | 1 + .../761c29151b23b4d14ce6261626641df1182f7a96 | Bin 0 -> 64 bytes .../7658451dd805f277a5b1c3d4065d752d2d8de5f4 | 2 + .../767e91cedcd9bc1bdac882acc34a53cc23cf4d02 | 1 + .../77d3754bdd4ea358369c936ed36b974b4181f6ab | 1 + .../7a95295bebe6237f65deb15ffeccab22716d574d | 2 + .../7ad88b82e87fbfb3d4bddaa2f6e201a151e3a007 | 3 + .../7b1010cc012e34af1d03e8845868ff0e1db3a601 | 3 + .../7d3ddbd11e82807321c9a53835ea897cf43aa7f2 | 1 + .../7da9c5ab5f049da297b0f4c1322edd696202d02a | 1 + .../7e265a019c02e5d089152849ac00bb005fa644f5 | 2 + .../7f33bff4f740eb898b908374b0c1badd47566947 | 2 + .../81f13b9b65891f2bfce77cb183a06045c461fee6 | 1 + .../846a14a480ffa1ad0f6333f3ecf2be3057ce6aed | 2 + .../87373a7f89feba2d50591b433f69877044155af2 | 2 + .../8833ba4c780c94fc6c3c466f849c0387acefdb20 | 1 + .../8c23a5ecd20db4da2c061f3463254e9de104c8b9 | 1 + .../8d883f1577ca8c334b7c6d75ccb71209d71ced13 | 1 + .../8dc80bd5f5d1fea64412203e304432edcf5f52c4 | 2 + .../8fc9a9ea6ad7d6d51e770076eaddacad9f970c6f | 2 + .../8fd167de17534776ef57aba2f27675789a11b8db | 3 + .../9117d3e51560813b3ce4615dced18fa0e4d0a25a | 1 + .../921c68eaa8776f7544e195ae52224355d08a2d4d | 1 + .../9293945411fca2dc81fc34b36b575a384e6d489e | 1 + .../933287d66c3ff3f0a21f2c583c763f2f65872ef8 | 1 + .../933d1d91283403f0a56571f533f482e9744eb735 | 1 + .../93855fc41b3e3004ca6ba85f34b985042d4c9869 | 2 + .../9544f445c39470f05785b52cfc31bb73bda22659 | 2 + .../97757217fde05ff4fc15c864bf29e9f560fd1c62 | 2 + .../9877c0f2d40dd43878bb0209bbc4b5fa93bec55a | 1 + .../98bc5065f79dd9d20cdac14ba28f0cf39908cb5f | 1 + .../992860817f7fb0e49423607355dab973aa7ab815 | 1 + .../995ee3d74bc6042fd6a8908c9df5a4cb530378d8 | 2 + .../9a38c24a6e87e99a72a3a4f007b117ec191a1705 | 1 + .../9aa97a0ffcdc37a8ef487355fb7271eb6891deaa | 2 + .../9b9fddc17ed7bc05a81c18f01e800a4e9efd0c8d | 1 + .../a0d4cb9a5a30bb01e8e4f68d636fb173632ed29d | 1 + .../a1e070288ec564d10a8c59779aa07fa771fa1d4f | 1 + .../a23d10723415d20f4ef1ed9b14d9dc24494856a0 | Bin 0 -> 54 bytes .../a245750cfe4212dca7bfde918de85f64eb053232 | 1 + .../a24bbe3600f4dfd61bb8415c6a291e0521e4f267 | 1 + .../a25104d039a549c8d457ecea3b55369ed312f086 | 3 + .../a33c4fcabe6aebe012cd01c8cb851a9ab0a12098 | 3 + .../a393e1727b0decca9f193179765c3a83d7096437 | 1 + .../a5507f06be4735a3a9e416ea986d52c1a6a20909 | 1 + .../a5adf028c902d17dd6a7ddeadabbed2b36420313 | 1 + .../a6aa1237a282ee3a93f2544bb6bb7704e565209e | Bin 0 -> 56 bytes .../a871185cabce7b96c9e2f6ffb40d9901c774b335 | 2 + .../a89d0e67bf53e22533a635f103d1fd400969ad56 | 1 + .../a8d1b4e5672a501d7a6cd14b2929297f3a82e035 | 1 + .../aa614cc8d05a3a58c30a890c10b9a0c1d609b228 | 1 + .../aa65320376f63805cc82b247612b2e05b87bdbee | Bin 0 -> 33 bytes .../abd3f6e2cc8887942de20e1c257427b825aed0ad | 2 + .../ad0653a3a63675a7ce797e69b4673866b88ace33 | 2 + .../ae2ce27806f67312e0d0e29a492db9ab9cb9bf4e | 1 + .../ae4c0e671bd004165a1e7877d9c67249a165d2df | 1 + .../af75c24dff7e22948ed141c763a1309e6f540bcc | 1 + .../b0f228c6d0cbbc9f10117f344d5aae6f001d00fa | 3 + .../b2c6eab05580b85cda591093d3f05c44bf453fce | Bin 0 -> 63 bytes .../b35281c0aae174d1ddc8999d97b9713f8004f285 | 1 + .../b484ae40795cf9730ba94d5a4ca40aa47b88eacb | 2 + .../b49c2fed1417a981ba29b32be73ee1700bea7ec9 | 1 + .../b68542373c05c0ed25231d09955b2c699d37c45b | 1 + .../b6d42cbe913f7275b574a71f0768781bdb6f45b7 | 1 + .../b80b6c2cae83c2097c7e4c1fb181d47cb8fd0519 | 2 + .../b90ab62d8591182fd90cd21cdb893178d97f7e0e | 1 + .../ba45c93ee6b8b286798d8791ec049207c448f7cd | 1 + .../ba67e81ef0f9a14bf5a1ca228bff87c681e83a44 | 1 + .../bbd1f06ddee4fbbd0e5c9c915889862e5df34f9c | 1 + .../bd982feb5dd4362e6bd9746ed216c25ce2749df4 | 1 + .../be77053335e6496288fcf8b6c4d0b4abf86493ff | 1 + .../bfb53203499969fac4f4be48e1bcd9235c2fa101 | 2 + .../c143576bdb5b34ad89fa3319507ae382a721f587 | 1 + .../c1ac502a15c53a90a1934f4a31d30f93db36dc8a | 1 + .../c1b29883768551fa5aadc38ba6eaad8007b9b85b | 3 + .../c2331fe0660ab5e411f6d38968c706aed390d8f6 | 1 + .../c32647119c244cc018bb1863853d5c7bd37090df | 1 + .../c4098733900c27861bbf74a71afcbbd93d62f8ee | 3 + .../c4f5769bf3b4f2a55c006b4cf5a3bba44b347241 | 2 + .../c6ea7b2d47402a458d5d03235bb042b61e05b2e8 | 1 + .../c7255dc48b42d44f6c0676d6009051b7e1aa885b | 1 + .../c7d77af55176ae0ae5e59f46e48e1e6ea108d799 | Bin 0 -> 64 bytes .../c80827341dcdf1c21b303b82ec7e6df7eaf63f3d | 1 + .../c9501031a75c067b6602e2831f03421b87be4496 | 1 + .../c98f88d962dfbc2a83e08bfbd8a87b0cc5a8b330 | 1 + .../ccd33fa22b2983978f9617b3cde76ea05b683c2c | 3 + .../cd0e7701fd79879c56f680817a0d2705751b1f44 | 2 + .../cd1c2b5c2684d831aab5265e9cd6f1ee045dab9b | Bin 0 -> 28 bytes .../cf98e8b01e7a759f28a9c5f59c896317d74ac47c | 3 + .../d1d171589e035be85dc347278f0735151a342d68 | 1 + .../d243143bf9b8adf6be92a157428ec6cbfd785423 | 1 + .../d2cd278979f2842ebd890f1d84712750273ad0fc | 2 + .../d2e96eb2699c7dd4a183f13d3a063a1aa9c192fd | 1 + .../d3178f8b0d26275667c27bb8533a61643213e4d8 | 2 + .../d46f536ea4b601c0ff313a5eb5b47e2b55aa9eb0 | 1 + .../d4be3038631eac422022ee23f43b47905a15b2b5 | 1 + .../d56b30a2d1b5a2a13ae00392bcb4ca72085310d9 | 2 + .../d67f85948143218d11e2fb7936a119741036045d | 1 + .../d6930ea81dfd91856a06a0c16483e47616642b4b | 1 + .../d737c10038a92add90e2ebea5c174ed249de8018 | 1 + .../d758a67f018b176dfc7d29630cf8cb587f5b2a6b | 2 + .../dc7139105787f3ba67d7971d80796e9cf5786a91 | 1 + .../dc8ec35f43e994b9c4ac61275d6b934990d42181 | 2 + .../dd2694fe12a018bc6af6f288b5c22a030eec8049 | Bin 0 -> 2 bytes .../de7424f44508582a953f137195533b7a0191eda7 | 1 + .../de91a02040d792dfcb71a4cb5aa4c1c006201273 | 1 + .../deb576067b11f6e2a3a39b0f2ef38ddae5c67b18 | 1 + .../df58248c414f342c81e056b40bee12d17a08bf61 | 1 + .../e076020b2826abd3a4b960fb33a35fd7d0606dd8 | Bin 0 -> 49 bytes .../e0bcf682342967c002621acd2563a2157826d156 | Bin 0 -> 50 bytes .../e1edca08a7654b42a64647abb0e773eddddb580b | 2 + .../e2fa528289b5971f5b40b3687a2a6f0d17348de6 | 2 + .../e52af0ba8750572b98f3a8968de77811ddff0893 | 1 + .../e5a0f40647f805b5001645ce2d94505e72fa64f3 | 2 + .../e69762f0c6a2750c0b03503a6aec90ffc94bcb72 | 1 + .../e7064f0b80f61dbc65915311032d27baa569ae2a | 1 + .../e863a4420854c36168d2b8dd39ce474ebe11cd26 | 1 + .../e8993f97bb9c83f87c64cfc429095eeaccf32953 | 1 + .../e9875d9a54b3ebc57df4da886cd30a39252ac666 | 3 + .../e98a9d92bbbac9b1e64c0641e967adebd681b2aa | 1 + .../eb7c31f48c77b742fa29126ac78a2c06c41208e8 | 1 + .../ec174492517f988010ed3ddbd003cb388f477bb6 | 1 + .../ec4d6a393be7ec80ccb8c531337a7fc3ef140e66 | 1 + .../ecd40909ab5e2c61841d9fb95b8aacc87651100c | Bin 0 -> 43 bytes .../ed17c8ddb6cc8a0b653dc87aca999d31e80c781a | 1 + .../ee0b476126bb1c2249b299323718ecef1250645e | 2 + .../ee1fb6a0b4139c07f1cf6bce850eaac9a2db29ba | 1 + .../eeac145c017ed35305f0ae69f820fc41e26e7997 | 1 + .../efac7390c6e3a653d3ce93c3d6902f2f1c281ce0 | 1 + .../f0f0dace93d51cd8e045aeacca89424fc836eebc | Bin 0 -> 34 bytes .../f3341b8cc55c0bb6e2d0a1f7f06d68e4f04057f5 | 2 + .../f59ff56e341b94f2bddfd718b48ae9ab1692d720 | 2 + .../f5a1824b9fd9f124df8097017607bcfa00eccfce | 2 + .../f5b92b69853a5d123bffdc6b0ab093f767ec30ad | Bin 0 -> 59 bytes .../f6aea4c380e41ddef2489ee581ab35e17fa3e8dd | 2 + .../f7b7254a3af7c41cb86e4b23bb93c5a6d55e2583 | 1 + .../f7bdc1b174f53a49c6ef8f8cdb9b8e74e0a5d4ab | 3 + .../f98c78c028baf22f39c77faf6e70edb86ac1d927 | 1 + .../fb440171bca6ff922727e9ff2a4ac40d8d7905ff | 1 + .../fc76cc4030b422e4cb5c145c3e8ed122e242acf0 | 1 + .../fcab3b80624b431e464dc12d3b6da1cf538bd15e | 2 + .../fdb3a9b59798d7e851d9074db69422b1d2df38dd | 1 + .../fe5de5f387e31b029d589d9b1777fd0d6b3e47b3 | 3 + .../ff52d938aaa10c08b2eb0830fc0066c3b57e040f | Bin 0 -> 36 bytes test/core/nanopb/fuzzer_response.c | 49 + test/core/nanopb/fuzzer_serverlist.c | 49 + .../fuzzer/runners/nanopb_fuzzer_response_test.sh | 38 + .../runners/nanopb_fuzzer_serverlist_test.sh | 38 + tools/run_tests/sources_and_headers.json | 66 + tools/run_tests/tests.json | 7304 ++++++++++++++++++++ 341 files changed, 8130 insertions(+), 8 deletions(-) create mode 100644 test/core/nanopb/corpus_response/0c35544f40d428d103e9c5b969ad9cd16767b110 create mode 100644 test/core/nanopb/corpus_response/0c60ee9ed55c9af6190b132ef6636c1d2abe4540 create mode 100644 test/core/nanopb/corpus_response/0ecb3e69889c036a86d21eb942077dc9abd649be create mode 100644 test/core/nanopb/corpus_response/1324c95dafe597fe05f9babe92fe6fbf181c1897 create mode 100644 test/core/nanopb/corpus_response/14eb42f7423081b455820daa2c02b358315dc0fa create mode 100644 test/core/nanopb/corpus_response/23121c5f633db5d7c1a9f2225240754246fee513 create mode 100644 test/core/nanopb/corpus_response/235548307ee9f2b0855fded42a871990d9ade956 create mode 100644 test/core/nanopb/corpus_response/28ed3a797da3c48c309a4ef792147f3c56cfec40 create mode 100644 test/core/nanopb/corpus_response/2bf123dbfa1d37a04493b5662a4b3b9c147485fc create mode 100644 test/core/nanopb/corpus_response/2d4c0908ecc0310ea234d10b6bdb4f4ca3c41dd1 create mode 100644 test/core/nanopb/corpus_response/304e8cdc9122b709ec2c063a5c8c38489a788033 create mode 100644 test/core/nanopb/corpus_response/324d4a2aed8bc1840fee212fd38dadec80a72ea2 create mode 100644 test/core/nanopb/corpus_response/33353a0b011901a13d010c6b165074ccdaa717ac create mode 100644 test/core/nanopb/corpus_response/37dfead09389fcd9b9d24ef817a0fed13d8ff2b0 create mode 100644 test/core/nanopb/corpus_response/47879cc364be304754f6af15563ad6f9a538da41 create mode 100644 test/core/nanopb/corpus_response/49a5cef4c730ecab22712b156ddba5106f165afd create mode 100644 test/core/nanopb/corpus_response/4bbbbb794a098deeacff73b774c30f12c54ceacb create mode 100644 test/core/nanopb/corpus_response/4c498ce69c8476f745693deb23272930e05cad60 create mode 100644 test/core/nanopb/corpus_response/4fb5e3085c32e9bccac9e18343cca07017d037de create mode 100644 test/core/nanopb/corpus_response/4fe5e46c1299e7f3e8a41dde3ae1bf1b60b4a43c create mode 100644 test/core/nanopb/corpus_response/670cc6bae958cb4f15e7297fe63959ac5799aa42 create mode 100644 test/core/nanopb/corpus_response/675f3263af7d1bbb084872f2b23f6d363227e85d create mode 100644 test/core/nanopb/corpus_response/67fe0d2acc727c8a39a707b92c6cebda9bd20986 create mode 100644 test/core/nanopb/corpus_response/6d15065785eb8f4b5f17357a520cb4815a2cb355 create mode 100644 test/core/nanopb/corpus_response/73285d7a70d73b517648067520d921e4477dbbfa create mode 100644 test/core/nanopb/corpus_response/747d1ed8bee4c6f0438beaf88ae76d8ef9f63da2 create mode 100644 test/core/nanopb/corpus_response/763878a34b3adeb99a03b54d09768a4451617016 create mode 100644 test/core/nanopb/corpus_response/7b4b0c2555178333ba15203a930c88ef7e7500e7 create mode 100644 test/core/nanopb/corpus_response/7b8a91aa46e370eb61307b4998889dc89775462f create mode 100644 test/core/nanopb/corpus_response/7cd11836c64f98742fa7beccec5c981ef4dd62ae create mode 100644 test/core/nanopb/corpus_response/7d8f4f045e70e8a2cb45dc3c001504f5c2614b16 create mode 100644 test/core/nanopb/corpus_response/7e9848558fb004e14795b3ebd3e1488dcde1db8c create mode 100644 test/core/nanopb/corpus_response/89734c37ee267e69a6950c6d60ee541c1be5ccff create mode 100644 test/core/nanopb/corpus_response/9034aaf45143996a2b14465c352ab0c6fa26b221 create mode 100644 test/core/nanopb/corpus_response/91e3b6a3484ab4b95cdeecc5aefe1291824060e8 create mode 100644 test/core/nanopb/corpus_response/95cd94c858e5e97f7df4a5eb7552e5e0d5ce1ec4 create mode 100644 test/core/nanopb/corpus_response/971f42d5a4d9816145ebc9dd28ba33ed3f5860b0 create mode 100644 test/core/nanopb/corpus_response/9db3a1854de87fd643b910aeab50553afc73e667 create mode 100644 test/core/nanopb/corpus_response/a147873135c6c52d4da03c260a0165bc0ab1b979 create mode 100644 test/core/nanopb/corpus_response/a710eead945dabbbffa213a980c75f9463a27398 create mode 100644 test/core/nanopb/corpus_response/a72406e3ca06d941fe8e168bbf67da88a81c947b create mode 100644 test/core/nanopb/corpus_response/a8a62a7ebb7d68b211ae319e082575935c07d188 create mode 100644 test/core/nanopb/corpus_response/a8abd012eb59b862bf9bc1ea443d2f35a1a2e222 create mode 100644 test/core/nanopb/corpus_response/aab56035a3533b5d83a32a439f179eb678250113 create mode 100644 test/core/nanopb/corpus_response/ac174acef2c5da26fadc7270bab9c8c4e938c463 create mode 100644 test/core/nanopb/corpus_response/acbbd60eeb76e41ce254d0fef353b92abe69c831 create mode 100644 test/core/nanopb/corpus_response/c1eed32e1e353737987da851ad760312ea8e557c create mode 100644 test/core/nanopb/corpus_response/c4214ace2c4bab24bb356f71aedca08544baad70 create mode 100644 test/core/nanopb/corpus_response/c4f87a6290aee1acfc1f26083974ce94621fca64 create mode 100644 test/core/nanopb/corpus_response/d285d78d3ba966b4b199453d38ead1aa36a7484f create mode 100644 test/core/nanopb/corpus_response/df5200f371cff3cae0e1595cd86d641725f5d1ba create mode 100644 test/core/nanopb/corpus_response/dfc66cb172919102f3ba14f6816228aa46f78154 create mode 100644 test/core/nanopb/corpus_response/e53e789a4c175c6a2c468472f1047d0fe8db1177 create mode 100644 test/core/nanopb/corpus_response/e67fe6794e755ea801272980f2c272edb027f6dc create mode 100644 test/core/nanopb/corpus_response/ead61e86fedf118df8e44ed70ce002be651cf291 create mode 100644 test/core/nanopb/corpus_response/eced8b29efbdc82eb8a1d0865c5f382f0ff78446 create mode 100644 test/core/nanopb/corpus_response/f58a9135d07ea9a5e3e710f6b3bf6d48d5942dfd create mode 100644 test/core/nanopb/corpus_response/f8c2c4ddd2f474b4839f13a9be862c00ab0ece77 create mode 100644 test/core/nanopb/corpus_response/faa1781e1444bba5b8c677bc5e2a38d023a1ec65 create mode 100644 test/core/nanopb/corpus_response/fccda587af845f0685275960649d8f4a45272a95 create mode 100644 test/core/nanopb/corpus_serverlist/000def12957806bb0d40005cb651d35b4cde7b4e create mode 100644 test/core/nanopb/corpus_serverlist/0068af2acc3020f344ee84b2c8adfb90492354c3 create mode 100644 test/core/nanopb/corpus_serverlist/009132022c3a1660b701728ac92e26baf82e8eac create mode 100644 test/core/nanopb/corpus_serverlist/00bf0233aa1155b34a3081e4a2b7a1c9cdf8ea1e create mode 100644 test/core/nanopb/corpus_serverlist/013197cfb12b59755b807501c6d6615859f9cd3f create mode 100644 test/core/nanopb/corpus_serverlist/018a4332eb19f2398162317cb6ad2e8cf700dfd6 create mode 100644 test/core/nanopb/corpus_serverlist/0273d3496bf5f4594e59083ac319f8f863a15be0 create mode 100644 test/core/nanopb/corpus_serverlist/0355002521e74dcdb3a0c633338bd02ab1d85312 create mode 100644 test/core/nanopb/corpus_serverlist/053d8d6ceeba9453c97d0ee5374db863e6f77ad4 create mode 100644 test/core/nanopb/corpus_serverlist/0628c29e3ae264f8fa08652435bb3e61afe60883 create mode 100644 test/core/nanopb/corpus_serverlist/065e91578e5359b70a668164310af6f0dd40e922 create mode 100644 test/core/nanopb/corpus_serverlist/06b4b617d5937da8a7b58aed5341dc5ef6d1bcd7 create mode 100644 test/core/nanopb/corpus_serverlist/07216a4f5934890b89d845f6256546c2681350ce create mode 100644 test/core/nanopb/corpus_serverlist/08584e8308b7f52f0fe380358800d7f585cba89c create mode 100644 test/core/nanopb/corpus_serverlist/085a37568e99ec5855bd96affd259921515479e8 create mode 100644 test/core/nanopb/corpus_serverlist/0903d1e9297179c18de6a3707b16f27d0d54ed67 create mode 100644 test/core/nanopb/corpus_serverlist/0aa20a75bff4e8af10330c66d288e900146f1a39 create mode 100644 test/core/nanopb/corpus_serverlist/0ae76e2b24ca999bd5e09e517aa4d88f5b5f58a4 create mode 100644 test/core/nanopb/corpus_serverlist/0c3025fdfb008a6563ea2a2bb6cbc79b8ccbf8f3 create mode 100644 test/core/nanopb/corpus_serverlist/0d219165cd317142afa36b8b5476cc022c95c4e6 create mode 100644 test/core/nanopb/corpus_serverlist/0e053123dd6256de5aff55b0731f913de250c18e create mode 100644 test/core/nanopb/corpus_serverlist/0e065f98325849ac05eed515865b33dba0264cd4 create mode 100644 test/core/nanopb/corpus_serverlist/0e4ff715d491c9f0b471c400b71804739b6d400a create mode 100644 test/core/nanopb/corpus_serverlist/0ec94942046cd7e00bc058204c1d046075ca9531 create mode 100644 test/core/nanopb/corpus_serverlist/0f0e8da530eb8c924cee6985d9c3dfd93274ef8c create mode 100644 test/core/nanopb/corpus_serverlist/0ff365225c981d74b89499d1e708684ed4d0b570 create mode 100644 test/core/nanopb/corpus_serverlist/113b1efff1677c1b9a24f89aec0c3ecc228ddf62 create mode 100644 test/core/nanopb/corpus_serverlist/11697d621eab6743ba22715722d5b23830b79075 create mode 100644 test/core/nanopb/corpus_serverlist/12463318b795c756f389bc0fb1cca9645eafef28 create mode 100644 test/core/nanopb/corpus_serverlist/12784250cf16ec999529f601ae5c5798e853d34a create mode 100644 test/core/nanopb/corpus_serverlist/13122d08c1cee0dae6434605917d4cc6d8ea8cc5 create mode 100644 test/core/nanopb/corpus_serverlist/148a1118649dd8aa9b4ed778efdf7c1611aa5d27 create mode 100644 test/core/nanopb/corpus_serverlist/15dea2bb5fb36a3dd5172796da66a821a32918e7 create mode 100644 test/core/nanopb/corpus_serverlist/16488fe15a7e33cb41f2b7c159c99154464b3fd3 create mode 100644 test/core/nanopb/corpus_serverlist/1870a48a3c9c1dd9027cbd85beb503b43cff6e89 create mode 100644 test/core/nanopb/corpus_serverlist/1900b6a9123667a79020319aa7fd54d230bc7073 create mode 100644 test/core/nanopb/corpus_serverlist/1a000f1cbccd2ab6f7e623e015ed2e84284c9dbf create mode 100644 test/core/nanopb/corpus_serverlist/1c1d403f6175d52ac4430d1ef2401b549761707e create mode 100644 test/core/nanopb/corpus_serverlist/1c2ae0e1915e18dffc2215e9121f1afe0e4335c4 create mode 100644 test/core/nanopb/corpus_serverlist/1c5d2eef52426db9d0842f3d57b27a219434c512 create mode 100644 test/core/nanopb/corpus_serverlist/1d0676867c1ebce84531035fa7eb86ed00762df5 create mode 100644 test/core/nanopb/corpus_serverlist/1d92b263fa70450b0d0aeb81bf5d2f69eefbbd99 create mode 100644 test/core/nanopb/corpus_serverlist/1e843ed4864d6a808b671dd6769ae191ac8a13ad create mode 100644 test/core/nanopb/corpus_serverlist/1eb06a34ee568d584c4b33472788889bc68af3f5 create mode 100644 test/core/nanopb/corpus_serverlist/2169c2b4d560d74a5487df68b56f3af1d648f544 create mode 100644 test/core/nanopb/corpus_serverlist/21f8f7583e58c1c81a3ac8237b5fa58071edf8a4 create mode 100644 test/core/nanopb/corpus_serverlist/231e348407fdcb14412c691b0b20982940160ccd create mode 100644 test/core/nanopb/corpus_serverlist/27b8f060e3296eaef77dcdd4c2cd11d5650604ac create mode 100644 test/core/nanopb/corpus_serverlist/28ed3a797da3c48c309a4ef792147f3c56cfec40 create mode 100644 test/core/nanopb/corpus_serverlist/291fcc6e043942638fa3c865c0a1be5e4dcc0e70 create mode 100644 test/core/nanopb/corpus_serverlist/2a7f6c1f8fdc090b24ceb90ab4f3a7b331c06c86 create mode 100644 test/core/nanopb/corpus_serverlist/2b85f180fe56f84925b274819ce10a8972a594e7 create mode 100644 test/core/nanopb/corpus_serverlist/2dea73d7d10ba0dcfd103f7542bdf7458e772b2b create mode 100644 test/core/nanopb/corpus_serverlist/2e9c19f98ef88b83ec2dea8b1b7f92b8337f757b create mode 100644 test/core/nanopb/corpus_serverlist/2fbd59ffb74aba392b86f4fe2ff8067b6d45cce8 create mode 100644 test/core/nanopb/corpus_serverlist/31059c32ea28d37b7442f51b20e966665662783c create mode 100644 test/core/nanopb/corpus_serverlist/31f78e35feb36037864df5f8f47136f8e6e4768a create mode 100644 test/core/nanopb/corpus_serverlist/326d322d1aa31696a14518830e544770f12146ee create mode 100644 test/core/nanopb/corpus_serverlist/337df26552e0884ff133cc1be8e72020be38f457 create mode 100644 test/core/nanopb/corpus_serverlist/33a2a0aa86956097e034b5ee16aeceacee7efc34 create mode 100644 test/core/nanopb/corpus_serverlist/33d175d1ecb3a85be7dd93d24efc3ddda0a85ad6 create mode 100644 test/core/nanopb/corpus_serverlist/3718a1b790db16bcfc4ec30691fab24ea7bb0b74 create mode 100644 test/core/nanopb/corpus_serverlist/37aa3946054035b712102a62b71c94747dfd1491 create mode 100644 test/core/nanopb/corpus_serverlist/37b697adc0708ad12e4ed7355f3f8fdf1b7919ca create mode 100644 test/core/nanopb/corpus_serverlist/37bf4642c5e5a806e2042cdf5ead9bf3c97b9ac1 create mode 100644 test/core/nanopb/corpus_serverlist/37d94ca6a20303389b35404f3dfd20aaa9ff0851 create mode 100644 test/core/nanopb/corpus_serverlist/39278604f6a1102366464bbe769ae846e542bc56 create mode 100644 test/core/nanopb/corpus_serverlist/396b57d9a11a1b135e36ad266e155cc0c3b77d21 create mode 100644 test/core/nanopb/corpus_serverlist/39a49db120a807fe4e80c502254a5009625c7599 create mode 100644 test/core/nanopb/corpus_serverlist/39f04d1c6d4beefa3e3d6eae3a5317d969787055 create mode 100644 test/core/nanopb/corpus_serverlist/3b199b80209fa0b8ffedba4381019f8729cc09d6 create mode 100644 test/core/nanopb/corpus_serverlist/3ccf7ffb96c3e4789409db33cc12bfd8ddc24c1a create mode 100644 test/core/nanopb/corpus_serverlist/3d04382d1fe11ff3b717100aece7f9eff2d04b9b create mode 100644 test/core/nanopb/corpus_serverlist/3d4eb9f836bb40cf4c734073bcba8b73e4cc93ae create mode 100644 test/core/nanopb/corpus_serverlist/41dc8c55e41d32c30865f9761931ddd4c5b740f8 create mode 100644 test/core/nanopb/corpus_serverlist/41ef7b74d212f8f7f6681edcffd0db719030d31d create mode 100644 test/core/nanopb/corpus_serverlist/431187b5926fa7d0823305a9f87635616ea3ef27 create mode 100644 test/core/nanopb/corpus_serverlist/44c6da04b8378986721f7225e70a1514695c176c create mode 100644 test/core/nanopb/corpus_serverlist/450161236e37a1dfc0da6398c4876df82ff640ac create mode 100644 test/core/nanopb/corpus_serverlist/45257a176ca6a05ec65a6df430bbb6b85d0a676f create mode 100644 test/core/nanopb/corpus_serverlist/46d1c2f2edcc9cdc0d1698fa0c8853cb19a6e7d9 create mode 100644 test/core/nanopb/corpus_serverlist/4764bd4297bf0c405348d2bb87b8fbc02beadcb8 create mode 100644 test/core/nanopb/corpus_serverlist/48199bfd0e2c160f56d03e881bb5dfe276eec462 create mode 100644 test/core/nanopb/corpus_serverlist/48e865c56e8db13640d6ecbfc0f2486eb77e07d1 create mode 100644 test/core/nanopb/corpus_serverlist/499b003b8b98edd9dbe2668c8c6af948769d7e87 create mode 100644 test/core/nanopb/corpus_serverlist/4a55591c4b390c5a36cecc6f1b6f5105300b546b create mode 100644 test/core/nanopb/corpus_serverlist/4d33f97ec69c64e14dcf205be36a6319ddb8a20d create mode 100644 test/core/nanopb/corpus_serverlist/4dbfb08904739928e19c2f459040b35ac410f699 create mode 100644 test/core/nanopb/corpus_serverlist/501bd6fe1de2719cf8d2c517a071e5d883fbe766 create mode 100644 test/core/nanopb/corpus_serverlist/5208871ea8948223b64b304336cea41ac3240244 create mode 100644 test/core/nanopb/corpus_serverlist/5348c71be34967458403bd4b58bb2a8a744d35ee create mode 100644 test/core/nanopb/corpus_serverlist/54362c2f6965268d0835a992c3ba656171b8f044 create mode 100644 test/core/nanopb/corpus_serverlist/54411aa13f6d9118028171935322bbbc74c15329 create mode 100644 test/core/nanopb/corpus_serverlist/54c50af22d147f192918499b4b3819eb389468a4 create mode 100644 test/core/nanopb/corpus_serverlist/55441aac903d96b36bf8a11bc804234bcf0c04da create mode 100644 test/core/nanopb/corpus_serverlist/56e1a7c279482a57fcbca43468df96a791ee22b4 create mode 100644 test/core/nanopb/corpus_serverlist/57cbea7c563d5c4b6b290271b0009c3f348d92da create mode 100644 test/core/nanopb/corpus_serverlist/57e11c7a62f0fc807d7b51bb1ef0f0e22f43795b create mode 100644 test/core/nanopb/corpus_serverlist/585183c1a240df6926689fe1bd8cb434664db4d8 create mode 100644 test/core/nanopb/corpus_serverlist/5b2ee8ca40508bf108a729dcb228191670ec34d6 create mode 100644 test/core/nanopb/corpus_serverlist/5b47eabaf74479348fd0318f174d649dbe96e7d2 create mode 100644 test/core/nanopb/corpus_serverlist/5ba93c9db0cff93f52b521d7420e43f6eda2784f create mode 100644 test/core/nanopb/corpus_serverlist/5cc827e33932ccf8c72c6a839074e856d93463d8 create mode 100644 test/core/nanopb/corpus_serverlist/5cc89bbf687f94ff87241a8f935905e1c441de33 create mode 100644 test/core/nanopb/corpus_serverlist/5ec6596f12462fe9f36924c262f97408b54bbba8 create mode 100644 test/core/nanopb/corpus_serverlist/5f8f3af69295223fb04c37d28035bb75b4cbd705 create mode 100644 test/core/nanopb/corpus_serverlist/5fd76d48b9fefecbdabd4511decc161b25db79dd create mode 100644 test/core/nanopb/corpus_serverlist/614cf839ccac2d896d61a0ba0ab1f42b2fabafea create mode 100644 test/core/nanopb/corpus_serverlist/618305cc2d3d3814d78b77ffbf421b769bd862cf create mode 100644 test/core/nanopb/corpus_serverlist/61dfcd913c4f0a8d005bd089c34e95d8dbbf1897 create mode 100644 test/core/nanopb/corpus_serverlist/65a89e10aab00039680e1f7d014737b634c74d8d create mode 100644 test/core/nanopb/corpus_serverlist/66a273dbf5e37410efd45518a42b06a65cffe1f0 create mode 100644 test/core/nanopb/corpus_serverlist/673ff0de0702e8098892060a5365c175d8ef18fc create mode 100644 test/core/nanopb/corpus_serverlist/68465c782c37bfdd98ac493b0458444bb94336e5 create mode 100644 test/core/nanopb/corpus_serverlist/688451dee13d0be420598c6e205a3bc419173e18 create mode 100644 test/core/nanopb/corpus_serverlist/68a1d9150e1380c219e0a1deb3993f321e000ecd create mode 100644 test/core/nanopb/corpus_serverlist/69f49bf7ae8886f5b4c6296fdb1c570256919604 create mode 100644 test/core/nanopb/corpus_serverlist/6a425f414cd69ffffdbaa34d03eb43841b432e11 create mode 100644 test/core/nanopb/corpus_serverlist/6ca9e6e85f9b007a0920b0112decbd1403d506da create mode 100644 test/core/nanopb/corpus_serverlist/6cd62e3d67b4154639adbe753115bfdd770edddb create mode 100644 test/core/nanopb/corpus_serverlist/6d4f2de4cc427417d6335ff5396ea2588509bb5b create mode 100644 test/core/nanopb/corpus_serverlist/6ea84030dd0b5b03e4720c244ea8b4ec65e1f236 create mode 100644 test/core/nanopb/corpus_serverlist/710c1fc8cf7dc1386312c34de5057933fcf868b3 create mode 100644 test/core/nanopb/corpus_serverlist/720e81dcaf83f867288a90293c5de3b088d5c556 create mode 100644 test/core/nanopb/corpus_serverlist/72cdc8f78ab5237f96ed354264c726ac79ec429c create mode 100644 test/core/nanopb/corpus_serverlist/73535a4f7af7e4c6aa23556cacd63f6929ac33fe create mode 100644 test/core/nanopb/corpus_serverlist/73d7b933a5673a4d6f5905006ef6266dda1e4fba create mode 100644 test/core/nanopb/corpus_serverlist/753aea13c82d1f8841c2bd4309b1b55d0ae2ba8d create mode 100644 test/core/nanopb/corpus_serverlist/754428e00e8a1d0471e00bd9e8f060ab88ab640e create mode 100644 test/core/nanopb/corpus_serverlist/761c29151b23b4d14ce6261626641df1182f7a96 create mode 100644 test/core/nanopb/corpus_serverlist/7658451dd805f277a5b1c3d4065d752d2d8de5f4 create mode 100644 test/core/nanopb/corpus_serverlist/767e91cedcd9bc1bdac882acc34a53cc23cf4d02 create mode 100644 test/core/nanopb/corpus_serverlist/77d3754bdd4ea358369c936ed36b974b4181f6ab create mode 100644 test/core/nanopb/corpus_serverlist/7a95295bebe6237f65deb15ffeccab22716d574d create mode 100644 test/core/nanopb/corpus_serverlist/7ad88b82e87fbfb3d4bddaa2f6e201a151e3a007 create mode 100644 test/core/nanopb/corpus_serverlist/7b1010cc012e34af1d03e8845868ff0e1db3a601 create mode 100644 test/core/nanopb/corpus_serverlist/7d3ddbd11e82807321c9a53835ea897cf43aa7f2 create mode 100644 test/core/nanopb/corpus_serverlist/7da9c5ab5f049da297b0f4c1322edd696202d02a create mode 100644 test/core/nanopb/corpus_serverlist/7e265a019c02e5d089152849ac00bb005fa644f5 create mode 100644 test/core/nanopb/corpus_serverlist/7f33bff4f740eb898b908374b0c1badd47566947 create mode 100644 test/core/nanopb/corpus_serverlist/81f13b9b65891f2bfce77cb183a06045c461fee6 create mode 100644 test/core/nanopb/corpus_serverlist/846a14a480ffa1ad0f6333f3ecf2be3057ce6aed create mode 100644 test/core/nanopb/corpus_serverlist/87373a7f89feba2d50591b433f69877044155af2 create mode 100644 test/core/nanopb/corpus_serverlist/8833ba4c780c94fc6c3c466f849c0387acefdb20 create mode 100644 test/core/nanopb/corpus_serverlist/8c23a5ecd20db4da2c061f3463254e9de104c8b9 create mode 100644 test/core/nanopb/corpus_serverlist/8d883f1577ca8c334b7c6d75ccb71209d71ced13 create mode 100644 test/core/nanopb/corpus_serverlist/8dc80bd5f5d1fea64412203e304432edcf5f52c4 create mode 100644 test/core/nanopb/corpus_serverlist/8fc9a9ea6ad7d6d51e770076eaddacad9f970c6f create mode 100644 test/core/nanopb/corpus_serverlist/8fd167de17534776ef57aba2f27675789a11b8db create mode 100644 test/core/nanopb/corpus_serverlist/9117d3e51560813b3ce4615dced18fa0e4d0a25a create mode 100644 test/core/nanopb/corpus_serverlist/921c68eaa8776f7544e195ae52224355d08a2d4d create mode 100644 test/core/nanopb/corpus_serverlist/9293945411fca2dc81fc34b36b575a384e6d489e create mode 100644 test/core/nanopb/corpus_serverlist/933287d66c3ff3f0a21f2c583c763f2f65872ef8 create mode 100644 test/core/nanopb/corpus_serverlist/933d1d91283403f0a56571f533f482e9744eb735 create mode 100644 test/core/nanopb/corpus_serverlist/93855fc41b3e3004ca6ba85f34b985042d4c9869 create mode 100644 test/core/nanopb/corpus_serverlist/9544f445c39470f05785b52cfc31bb73bda22659 create mode 100644 test/core/nanopb/corpus_serverlist/97757217fde05ff4fc15c864bf29e9f560fd1c62 create mode 100644 test/core/nanopb/corpus_serverlist/9877c0f2d40dd43878bb0209bbc4b5fa93bec55a create mode 100644 test/core/nanopb/corpus_serverlist/98bc5065f79dd9d20cdac14ba28f0cf39908cb5f create mode 100644 test/core/nanopb/corpus_serverlist/992860817f7fb0e49423607355dab973aa7ab815 create mode 100644 test/core/nanopb/corpus_serverlist/995ee3d74bc6042fd6a8908c9df5a4cb530378d8 create mode 100644 test/core/nanopb/corpus_serverlist/9a38c24a6e87e99a72a3a4f007b117ec191a1705 create mode 100644 test/core/nanopb/corpus_serverlist/9aa97a0ffcdc37a8ef487355fb7271eb6891deaa create mode 100644 test/core/nanopb/corpus_serverlist/9b9fddc17ed7bc05a81c18f01e800a4e9efd0c8d create mode 100644 test/core/nanopb/corpus_serverlist/a0d4cb9a5a30bb01e8e4f68d636fb173632ed29d create mode 100644 test/core/nanopb/corpus_serverlist/a1e070288ec564d10a8c59779aa07fa771fa1d4f create mode 100644 test/core/nanopb/corpus_serverlist/a23d10723415d20f4ef1ed9b14d9dc24494856a0 create mode 100644 test/core/nanopb/corpus_serverlist/a245750cfe4212dca7bfde918de85f64eb053232 create mode 100644 test/core/nanopb/corpus_serverlist/a24bbe3600f4dfd61bb8415c6a291e0521e4f267 create mode 100644 test/core/nanopb/corpus_serverlist/a25104d039a549c8d457ecea3b55369ed312f086 create mode 100644 test/core/nanopb/corpus_serverlist/a33c4fcabe6aebe012cd01c8cb851a9ab0a12098 create mode 100644 test/core/nanopb/corpus_serverlist/a393e1727b0decca9f193179765c3a83d7096437 create mode 100644 test/core/nanopb/corpus_serverlist/a5507f06be4735a3a9e416ea986d52c1a6a20909 create mode 100644 test/core/nanopb/corpus_serverlist/a5adf028c902d17dd6a7ddeadabbed2b36420313 create mode 100644 test/core/nanopb/corpus_serverlist/a6aa1237a282ee3a93f2544bb6bb7704e565209e create mode 100644 test/core/nanopb/corpus_serverlist/a871185cabce7b96c9e2f6ffb40d9901c774b335 create mode 100644 test/core/nanopb/corpus_serverlist/a89d0e67bf53e22533a635f103d1fd400969ad56 create mode 100644 test/core/nanopb/corpus_serverlist/a8d1b4e5672a501d7a6cd14b2929297f3a82e035 create mode 100644 test/core/nanopb/corpus_serverlist/aa614cc8d05a3a58c30a890c10b9a0c1d609b228 create mode 100644 test/core/nanopb/corpus_serverlist/aa65320376f63805cc82b247612b2e05b87bdbee create mode 100644 test/core/nanopb/corpus_serverlist/abd3f6e2cc8887942de20e1c257427b825aed0ad create mode 100644 test/core/nanopb/corpus_serverlist/ad0653a3a63675a7ce797e69b4673866b88ace33 create mode 100644 test/core/nanopb/corpus_serverlist/ae2ce27806f67312e0d0e29a492db9ab9cb9bf4e create mode 100644 test/core/nanopb/corpus_serverlist/ae4c0e671bd004165a1e7877d9c67249a165d2df create mode 100644 test/core/nanopb/corpus_serverlist/af75c24dff7e22948ed141c763a1309e6f540bcc create mode 100644 test/core/nanopb/corpus_serverlist/b0f228c6d0cbbc9f10117f344d5aae6f001d00fa create mode 100644 test/core/nanopb/corpus_serverlist/b2c6eab05580b85cda591093d3f05c44bf453fce create mode 100644 test/core/nanopb/corpus_serverlist/b35281c0aae174d1ddc8999d97b9713f8004f285 create mode 100644 test/core/nanopb/corpus_serverlist/b484ae40795cf9730ba94d5a4ca40aa47b88eacb create mode 100644 test/core/nanopb/corpus_serverlist/b49c2fed1417a981ba29b32be73ee1700bea7ec9 create mode 100644 test/core/nanopb/corpus_serverlist/b68542373c05c0ed25231d09955b2c699d37c45b create mode 100644 test/core/nanopb/corpus_serverlist/b6d42cbe913f7275b574a71f0768781bdb6f45b7 create mode 100644 test/core/nanopb/corpus_serverlist/b80b6c2cae83c2097c7e4c1fb181d47cb8fd0519 create mode 100644 test/core/nanopb/corpus_serverlist/b90ab62d8591182fd90cd21cdb893178d97f7e0e create mode 100644 test/core/nanopb/corpus_serverlist/ba45c93ee6b8b286798d8791ec049207c448f7cd create mode 100644 test/core/nanopb/corpus_serverlist/ba67e81ef0f9a14bf5a1ca228bff87c681e83a44 create mode 100644 test/core/nanopb/corpus_serverlist/bbd1f06ddee4fbbd0e5c9c915889862e5df34f9c create mode 100644 test/core/nanopb/corpus_serverlist/bd982feb5dd4362e6bd9746ed216c25ce2749df4 create mode 100644 test/core/nanopb/corpus_serverlist/be77053335e6496288fcf8b6c4d0b4abf86493ff create mode 100644 test/core/nanopb/corpus_serverlist/bfb53203499969fac4f4be48e1bcd9235c2fa101 create mode 100644 test/core/nanopb/corpus_serverlist/c143576bdb5b34ad89fa3319507ae382a721f587 create mode 100644 test/core/nanopb/corpus_serverlist/c1ac502a15c53a90a1934f4a31d30f93db36dc8a create mode 100644 test/core/nanopb/corpus_serverlist/c1b29883768551fa5aadc38ba6eaad8007b9b85b create mode 100644 test/core/nanopb/corpus_serverlist/c2331fe0660ab5e411f6d38968c706aed390d8f6 create mode 100644 test/core/nanopb/corpus_serverlist/c32647119c244cc018bb1863853d5c7bd37090df create mode 100644 test/core/nanopb/corpus_serverlist/c4098733900c27861bbf74a71afcbbd93d62f8ee create mode 100644 test/core/nanopb/corpus_serverlist/c4f5769bf3b4f2a55c006b4cf5a3bba44b347241 create mode 100644 test/core/nanopb/corpus_serverlist/c6ea7b2d47402a458d5d03235bb042b61e05b2e8 create mode 100644 test/core/nanopb/corpus_serverlist/c7255dc48b42d44f6c0676d6009051b7e1aa885b create mode 100644 test/core/nanopb/corpus_serverlist/c7d77af55176ae0ae5e59f46e48e1e6ea108d799 create mode 100644 test/core/nanopb/corpus_serverlist/c80827341dcdf1c21b303b82ec7e6df7eaf63f3d create mode 100644 test/core/nanopb/corpus_serverlist/c9501031a75c067b6602e2831f03421b87be4496 create mode 100644 test/core/nanopb/corpus_serverlist/c98f88d962dfbc2a83e08bfbd8a87b0cc5a8b330 create mode 100644 test/core/nanopb/corpus_serverlist/ccd33fa22b2983978f9617b3cde76ea05b683c2c create mode 100644 test/core/nanopb/corpus_serverlist/cd0e7701fd79879c56f680817a0d2705751b1f44 create mode 100644 test/core/nanopb/corpus_serverlist/cd1c2b5c2684d831aab5265e9cd6f1ee045dab9b create mode 100644 test/core/nanopb/corpus_serverlist/cf98e8b01e7a759f28a9c5f59c896317d74ac47c create mode 100644 test/core/nanopb/corpus_serverlist/d1d171589e035be85dc347278f0735151a342d68 create mode 100644 test/core/nanopb/corpus_serverlist/d243143bf9b8adf6be92a157428ec6cbfd785423 create mode 100644 test/core/nanopb/corpus_serverlist/d2cd278979f2842ebd890f1d84712750273ad0fc create mode 100644 test/core/nanopb/corpus_serverlist/d2e96eb2699c7dd4a183f13d3a063a1aa9c192fd create mode 100644 test/core/nanopb/corpus_serverlist/d3178f8b0d26275667c27bb8533a61643213e4d8 create mode 100644 test/core/nanopb/corpus_serverlist/d46f536ea4b601c0ff313a5eb5b47e2b55aa9eb0 create mode 100644 test/core/nanopb/corpus_serverlist/d4be3038631eac422022ee23f43b47905a15b2b5 create mode 100644 test/core/nanopb/corpus_serverlist/d56b30a2d1b5a2a13ae00392bcb4ca72085310d9 create mode 100644 test/core/nanopb/corpus_serverlist/d67f85948143218d11e2fb7936a119741036045d create mode 100644 test/core/nanopb/corpus_serverlist/d6930ea81dfd91856a06a0c16483e47616642b4b create mode 100644 test/core/nanopb/corpus_serverlist/d737c10038a92add90e2ebea5c174ed249de8018 create mode 100644 test/core/nanopb/corpus_serverlist/d758a67f018b176dfc7d29630cf8cb587f5b2a6b create mode 100644 test/core/nanopb/corpus_serverlist/dc7139105787f3ba67d7971d80796e9cf5786a91 create mode 100644 test/core/nanopb/corpus_serverlist/dc8ec35f43e994b9c4ac61275d6b934990d42181 create mode 100644 test/core/nanopb/corpus_serverlist/dd2694fe12a018bc6af6f288b5c22a030eec8049 create mode 100644 test/core/nanopb/corpus_serverlist/de7424f44508582a953f137195533b7a0191eda7 create mode 100644 test/core/nanopb/corpus_serverlist/de91a02040d792dfcb71a4cb5aa4c1c006201273 create mode 100644 test/core/nanopb/corpus_serverlist/deb576067b11f6e2a3a39b0f2ef38ddae5c67b18 create mode 100644 test/core/nanopb/corpus_serverlist/df58248c414f342c81e056b40bee12d17a08bf61 create mode 100644 test/core/nanopb/corpus_serverlist/e076020b2826abd3a4b960fb33a35fd7d0606dd8 create mode 100644 test/core/nanopb/corpus_serverlist/e0bcf682342967c002621acd2563a2157826d156 create mode 100644 test/core/nanopb/corpus_serverlist/e1edca08a7654b42a64647abb0e773eddddb580b create mode 100644 test/core/nanopb/corpus_serverlist/e2fa528289b5971f5b40b3687a2a6f0d17348de6 create mode 100644 test/core/nanopb/corpus_serverlist/e52af0ba8750572b98f3a8968de77811ddff0893 create mode 100644 test/core/nanopb/corpus_serverlist/e5a0f40647f805b5001645ce2d94505e72fa64f3 create mode 100644 test/core/nanopb/corpus_serverlist/e69762f0c6a2750c0b03503a6aec90ffc94bcb72 create mode 100644 test/core/nanopb/corpus_serverlist/e7064f0b80f61dbc65915311032d27baa569ae2a create mode 100644 test/core/nanopb/corpus_serverlist/e863a4420854c36168d2b8dd39ce474ebe11cd26 create mode 100644 test/core/nanopb/corpus_serverlist/e8993f97bb9c83f87c64cfc429095eeaccf32953 create mode 100644 test/core/nanopb/corpus_serverlist/e9875d9a54b3ebc57df4da886cd30a39252ac666 create mode 100644 test/core/nanopb/corpus_serverlist/e98a9d92bbbac9b1e64c0641e967adebd681b2aa create mode 100644 test/core/nanopb/corpus_serverlist/eb7c31f48c77b742fa29126ac78a2c06c41208e8 create mode 100644 test/core/nanopb/corpus_serverlist/ec174492517f988010ed3ddbd003cb388f477bb6 create mode 100644 test/core/nanopb/corpus_serverlist/ec4d6a393be7ec80ccb8c531337a7fc3ef140e66 create mode 100644 test/core/nanopb/corpus_serverlist/ecd40909ab5e2c61841d9fb95b8aacc87651100c create mode 100644 test/core/nanopb/corpus_serverlist/ed17c8ddb6cc8a0b653dc87aca999d31e80c781a create mode 100644 test/core/nanopb/corpus_serverlist/ee0b476126bb1c2249b299323718ecef1250645e create mode 100644 test/core/nanopb/corpus_serverlist/ee1fb6a0b4139c07f1cf6bce850eaac9a2db29ba create mode 100644 test/core/nanopb/corpus_serverlist/eeac145c017ed35305f0ae69f820fc41e26e7997 create mode 100644 test/core/nanopb/corpus_serverlist/efac7390c6e3a653d3ce93c3d6902f2f1c281ce0 create mode 100644 test/core/nanopb/corpus_serverlist/f0f0dace93d51cd8e045aeacca89424fc836eebc create mode 100644 test/core/nanopb/corpus_serverlist/f3341b8cc55c0bb6e2d0a1f7f06d68e4f04057f5 create mode 100644 test/core/nanopb/corpus_serverlist/f59ff56e341b94f2bddfd718b48ae9ab1692d720 create mode 100644 test/core/nanopb/corpus_serverlist/f5a1824b9fd9f124df8097017607bcfa00eccfce create mode 100644 test/core/nanopb/corpus_serverlist/f5b92b69853a5d123bffdc6b0ab093f767ec30ad create mode 100644 test/core/nanopb/corpus_serverlist/f6aea4c380e41ddef2489ee581ab35e17fa3e8dd create mode 100644 test/core/nanopb/corpus_serverlist/f7b7254a3af7c41cb86e4b23bb93c5a6d55e2583 create mode 100644 test/core/nanopb/corpus_serverlist/f7bdc1b174f53a49c6ef8f8cdb9b8e74e0a5d4ab create mode 100644 test/core/nanopb/corpus_serverlist/f98c78c028baf22f39c77faf6e70edb86ac1d927 create mode 100644 test/core/nanopb/corpus_serverlist/fb440171bca6ff922727e9ff2a4ac40d8d7905ff create mode 100644 test/core/nanopb/corpus_serverlist/fc76cc4030b422e4cb5c145c3e8ed122e242acf0 create mode 100644 test/core/nanopb/corpus_serverlist/fcab3b80624b431e464dc12d3b6da1cf538bd15e create mode 100644 test/core/nanopb/corpus_serverlist/fdb3a9b59798d7e851d9074db69422b1d2df38dd create mode 100644 test/core/nanopb/corpus_serverlist/fe5de5f387e31b029d589d9b1777fd0d6b3e47b3 create mode 100644 test/core/nanopb/corpus_serverlist/ff52d938aaa10c08b2eb0830fc0066c3b57e040f create mode 100644 test/core/nanopb/fuzzer_response.c create mode 100644 test/core/nanopb/fuzzer_serverlist.c create mode 100644 tools/fuzzer/runners/nanopb_fuzzer_response_test.sh create mode 100644 tools/fuzzer/runners/nanopb_fuzzer_serverlist_test.sh (limited to 'src') diff --git a/Makefile b/Makefile index 4bb7dc8a16..273171ad5e 100644 --- a/Makefile +++ b/Makefile @@ -961,6 +961,8 @@ message_compress_test: $(BINDIR)/$(CONFIG)/message_compress_test mlog_test: $(BINDIR)/$(CONFIG)/mlog_test multiple_server_queues_test: $(BINDIR)/$(CONFIG)/multiple_server_queues_test murmur_hash_test: $(BINDIR)/$(CONFIG)/murmur_hash_test +nanopb_fuzzer_response_test: $(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test +nanopb_fuzzer_serverlist_test: $(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test no_server_test: $(BINDIR)/$(CONFIG)/no_server_test resolve_address_test: $(BINDIR)/$(CONFIG)/resolve_address_test secure_channel_create_test: $(BINDIR)/$(CONFIG)/secure_channel_create_test @@ -1113,6 +1115,8 @@ h2_uds_nosec_test: $(BINDIR)/$(CONFIG)/h2_uds_nosec_test hpack_parser_fuzzer_test_one_entry: $(BINDIR)/$(CONFIG)/hpack_parser_fuzzer_test_one_entry http_fuzzer_test_one_entry: $(BINDIR)/$(CONFIG)/http_fuzzer_test_one_entry json_fuzzer_test_one_entry: $(BINDIR)/$(CONFIG)/json_fuzzer_test_one_entry +nanopb_fuzzer_response_test_one_entry: $(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test_one_entry +nanopb_fuzzer_serverlist_test_one_entry: $(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test_one_entry uri_fuzzer_test_one_entry: $(BINDIR)/$(CONFIG)/uri_fuzzer_test_one_entry run_dep_checks: @@ -1335,6 +1339,8 @@ buildtests_c: privatelibs_c \ $(BINDIR)/$(CONFIG)/hpack_parser_fuzzer_test_one_entry \ $(BINDIR)/$(CONFIG)/http_fuzzer_test_one_entry \ $(BINDIR)/$(CONFIG)/json_fuzzer_test_one_entry \ + $(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test_one_entry \ + $(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test_one_entry \ $(BINDIR)/$(CONFIG)/uri_fuzzer_test_one_entry \ @@ -8659,6 +8665,70 @@ endif endif +NANOPB_FUZZER_RESPONSE_TEST_SRC = \ + test/core/nanopb/fuzzer_response.c \ + +NANOPB_FUZZER_RESPONSE_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(NANOPB_FUZZER_RESPONSE_TEST_SRC)))) +ifeq ($(NO_SECURE),true) + +# You can't build secure targets if you don't have OpenSSL. + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test: openssl_dep_error + +else + + + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test: $(NANOPB_FUZZER_RESPONSE_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + $(E) "[LD] Linking $@" + $(Q) mkdir -p `dirname $@` + $(Q) $(LDXX) $(LDFLAGS) $(NANOPB_FUZZER_RESPONSE_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -lFuzzer -o $(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test + +endif + +$(OBJDIR)/$(CONFIG)/test/core/nanopb/fuzzer_response.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + +deps_nanopb_fuzzer_response_test: $(NANOPB_FUZZER_RESPONSE_TEST_OBJS:.o=.dep) + +ifneq ($(NO_SECURE),true) +ifneq ($(NO_DEPS),true) +-include $(NANOPB_FUZZER_RESPONSE_TEST_OBJS:.o=.dep) +endif +endif + + +NANOPB_FUZZER_SERVERLIST_TEST_SRC = \ + test/core/nanopb/fuzzer_serverlist.c \ + +NANOPB_FUZZER_SERVERLIST_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(NANOPB_FUZZER_SERVERLIST_TEST_SRC)))) +ifeq ($(NO_SECURE),true) + +# You can't build secure targets if you don't have OpenSSL. + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test: openssl_dep_error + +else + + + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test: $(NANOPB_FUZZER_SERVERLIST_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + $(E) "[LD] Linking $@" + $(Q) mkdir -p `dirname $@` + $(Q) $(LDXX) $(LDFLAGS) $(NANOPB_FUZZER_SERVERLIST_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -lFuzzer -o $(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test + +endif + +$(OBJDIR)/$(CONFIG)/test/core/nanopb/fuzzer_serverlist.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + +deps_nanopb_fuzzer_serverlist_test: $(NANOPB_FUZZER_SERVERLIST_TEST_OBJS:.o=.dep) + +ifneq ($(NO_SECURE),true) +ifneq ($(NO_DEPS),true) +-include $(NANOPB_FUZZER_SERVERLIST_TEST_OBJS:.o=.dep) +endif +endif + + NO_SERVER_TEST_SRC = \ test/core/end2end/no_server_test.c \ @@ -13668,6 +13738,70 @@ endif endif +NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_SRC = \ + test/core/nanopb/fuzzer_response.c \ + +NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_SRC)))) +ifeq ($(NO_SECURE),true) + +# You can't build secure targets if you don't have OpenSSL. + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test_one_entry: openssl_dep_error + +else + + + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test_one_entry: $(NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_OBJS) $(LIBDIR)/$(CONFIG)/libone_input_fuzzer.a $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + $(E) "[LD] Linking $@" + $(Q) mkdir -p `dirname $@` + $(Q) $(LD) $(LDFLAGS) $(NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_OBJS) $(LIBDIR)/$(CONFIG)/libone_input_fuzzer.a $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -o $(BINDIR)/$(CONFIG)/nanopb_fuzzer_response_test_one_entry + +endif + +$(OBJDIR)/$(CONFIG)/test/core/nanopb/fuzzer_response.o: $(LIBDIR)/$(CONFIG)/libone_input_fuzzer.a $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + +deps_nanopb_fuzzer_response_test_one_entry: $(NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_OBJS:.o=.dep) + +ifneq ($(NO_SECURE),true) +ifneq ($(NO_DEPS),true) +-include $(NANOPB_FUZZER_RESPONSE_TEST_ONE_ENTRY_OBJS:.o=.dep) +endif +endif + + +NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_SRC = \ + test/core/nanopb/fuzzer_serverlist.c \ + +NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_SRC)))) +ifeq ($(NO_SECURE),true) + +# You can't build secure targets if you don't have OpenSSL. + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test_one_entry: openssl_dep_error + +else + + + +$(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test_one_entry: $(NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_OBJS) $(LIBDIR)/$(CONFIG)/libone_input_fuzzer.a $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + $(E) "[LD] Linking $@" + $(Q) mkdir -p `dirname $@` + $(Q) $(LD) $(LDFLAGS) $(NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_OBJS) $(LIBDIR)/$(CONFIG)/libone_input_fuzzer.a $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -o $(BINDIR)/$(CONFIG)/nanopb_fuzzer_serverlist_test_one_entry + +endif + +$(OBJDIR)/$(CONFIG)/test/core/nanopb/fuzzer_serverlist.o: $(LIBDIR)/$(CONFIG)/libone_input_fuzzer.a $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a + +deps_nanopb_fuzzer_serverlist_test_one_entry: $(NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_OBJS:.o=.dep) + +ifneq ($(NO_SECURE),true) +ifneq ($(NO_DEPS),true) +-include $(NANOPB_FUZZER_SERVERLIST_TEST_ONE_ENTRY_OBJS:.o=.dep) +endif +endif + + URI_FUZZER_TEST_ONE_ENTRY_SRC = \ test/core/client_config/uri_fuzzer_test.c \ diff --git a/build.yaml b/build.yaml index 0a71cf715d..5cbc466354 100644 --- a/build.yaml +++ b/build.yaml @@ -1895,6 +1895,30 @@ targets: deps: - gpr_test_util - gpr +- name: nanopb_fuzzer_response_test + build: fuzzer + language: c + src: + - test/core/nanopb/fuzzer_response.c + deps: + - grpc_test_util + - grpc + - gpr_test_util + - gpr + corpus_dirs: + - test/core/nanopb/corpus_response +- name: nanopb_fuzzer_serverlist_test + build: fuzzer + language: c + src: + - test/core/nanopb/fuzzer_serverlist.c + deps: + - grpc_test_util + - grpc + - gpr_test_util + - gpr + corpus_dirs: + - test/core/nanopb/corpus_serverlist - name: no_server_test cpu_cost: 0.1 build: test diff --git a/src/core/ext/lb_policy/grpclb/load_balancer_api.c b/src/core/ext/lb_policy/grpclb/load_balancer_api.c index d8af644870..459d6d9954 100644 --- a/src/core/ext/lb_policy/grpclb/load_balancer_api.c +++ b/src/core/ext/lb_policy/grpclb/load_balancer_api.c @@ -110,13 +110,15 @@ grpc_grpclb_response *grpc_grpclb_response_parse(gpr_slice encoded_response) { grpc_grpclb_response *res = gpr_malloc(sizeof(grpc_grpclb_response)); memset(res, 0, sizeof(*res)); status = pb_decode(&stream, grpc_lb_v0_LoadBalanceResponse_fields, res); - GPR_ASSERT(status == true); + if (!status) { + grpc_grpclb_response_destroy(res); + return NULL; + } return res; } grpc_grpclb_serverlist *grpc_grpclb_response_parse_serverlist( gpr_slice encoded_response) { - grpc_grpclb_serverlist *sl = gpr_malloc(sizeof(grpc_grpclb_serverlist)); bool status; decode_serverlist_arg arg; pb_istream_t stream = @@ -131,15 +133,20 @@ grpc_grpclb_serverlist *grpc_grpclb_response_parse_serverlist( res->server_list.servers.arg = &arg; arg.first_pass = 1; status = pb_decode(&stream, grpc_lb_v0_LoadBalanceResponse_fields, res); - GPR_ASSERT(status == true); - GPR_ASSERT(arg.num_servers > 0); + if (!status) { + grpc_grpclb_response_destroy(res); + return NULL; + } arg.first_pass = 0; status = pb_decode(&stream_at_start, grpc_lb_v0_LoadBalanceResponse_fields, res); - GPR_ASSERT(status == true); - GPR_ASSERT(arg.servers != NULL); + if (!status) { + grpc_grpclb_response_destroy(res); + return NULL; + } + grpc_grpclb_serverlist *sl = gpr_malloc(sizeof(grpc_grpclb_serverlist)); sl->num_servers = arg.num_servers; sl->servers = arg.servers; if (res->server_list.has_expiration_interval) { @@ -150,8 +157,10 @@ grpc_grpclb_serverlist *grpc_grpclb_response_parse_serverlist( } void grpc_grpclb_destroy_serverlist(grpc_grpclb_serverlist *serverlist) { - size_t i; - for (i = 0; i < serverlist->num_servers; i++) { + if (serverlist == NULL) { + return; + } + for (size_t i = 0; i < serverlist->num_servers; i++) { gpr_free(serverlist->servers[i]); } gpr_free(serverlist->servers); diff --git a/test/core/nanopb/corpus_response/0c35544f40d428d103e9c5b969ad9cd16767b110 b/test/core/nanopb/corpus_response/0c35544f40d428d103e9c5b969ad9cd16767b110 new file mode 100644 index 0000000000..2b5fc999d8 Binary files /dev/null and b/test/core/nanopb/corpus_response/0c35544f40d428d103e9c5b969ad9cd16767b110 differ diff --git a/test/core/nanopb/corpus_response/0c60ee9ed55c9af6190b132ef6636c1d2abe4540 b/test/core/nanopb/corpus_response/0c60ee9ed55c9af6190b132ef6636c1d2abe4540 new file mode 100644 index 0000000000..85366bee0a --- /dev/null +++ b/test/core/nanopb/corpus_response/0c60ee9ed55c9af6190b132ef6636c1d2abe4540 @@ -0,0 +1 @@ + ½“½“2ƒ;΃;Î)±%Ì))±%Ì):: \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/0ecb3e69889c036a86d21eb942077dc9abd649be b/test/core/nanopb/corpus_response/0ecb3e69889c036a86d21eb942077dc9abd649be new file mode 100644 index 0000000000..74921b2170 Binary files /dev/null and b/test/core/nanopb/corpus_response/0ecb3e69889c036a86d21eb942077dc9abd649be differ diff --git a/test/core/nanopb/corpus_response/1324c95dafe597fe05f9babe92fe6fbf181c1897 b/test/core/nanopb/corpus_response/1324c95dafe597fe05f9babe92fe6fbf181c1897 new file mode 100644 index 0000000000..4b7de2e473 --- /dev/null +++ b/test/core/nanopb/corpus_response/1324c95dafe597fe05f9babe92fe6fbf181c1897 @@ -0,0 +1 @@ +(z%;:8!(¼;ªo!>::†©;=È( );;!ÞØ*:):B(r''' *þEàh;**!!Ý**** \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/14eb42f7423081b455820daa2c02b358315dc0fa b/test/core/nanopb/corpus_response/14eb42f7423081b455820daa2c02b358315dc0fa new file mode 100644 index 0000000000..5a077927d9 --- /dev/null +++ b/test/core/nanopb/corpus_response/14eb42f7423081b455820daa2c02b358315dc0fa @@ -0,0 +1 @@ +(z%;:8!(¼;ª!>::†©;=È( );;!ÞØ*:):B(r''' *þEàh;**!!Ý**** \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/23121c5f633db5d7c1a9f2225240754246fee513 b/test/core/nanopb/corpus_response/23121c5f633db5d7c1a9f2225240754246fee513 new file mode 100644 index 0000000000..e9db64ba0b Binary files /dev/null and b/test/core/nanopb/corpus_response/23121c5f633db5d7c1a9f2225240754246fee513 differ diff --git a/test/core/nanopb/corpus_response/235548307ee9f2b0855fded42a871990d9ade956 b/test/core/nanopb/corpus_response/235548307ee9f2b0855fded42a871990d9ade956 new file mode 100644 index 0000000000..da1306ddd6 Binary files /dev/null and b/test/core/nanopb/corpus_response/235548307ee9f2b0855fded42a871990d9ade956 differ diff --git a/test/core/nanopb/corpus_response/28ed3a797da3c48c309a4ef792147f3c56cfec40 b/test/core/nanopb/corpus_response/28ed3a797da3c48c309a4ef792147f3c56cfec40 new file mode 100644 index 0000000000..f46d387bf9 --- /dev/null +++ b/test/core/nanopb/corpus_response/28ed3a797da3c48c309a4ef792147f3c56cfec40 @@ -0,0 +1 @@ +( \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/2bf123dbfa1d37a04493b5662a4b3b9c147485fc b/test/core/nanopb/corpus_response/2bf123dbfa1d37a04493b5662a4b3b9c147485fc new file mode 100644 index 0000000000..7ea0b41123 Binary files /dev/null and b/test/core/nanopb/corpus_response/2bf123dbfa1d37a04493b5662a4b3b9c147485fc differ diff --git a/test/core/nanopb/corpus_response/2d4c0908ecc0310ea234d10b6bdb4f4ca3c41dd1 b/test/core/nanopb/corpus_response/2d4c0908ecc0310ea234d10b6bdb4f4ca3c41dd1 new file mode 100644 index 0000000000..cd74051c52 --- /dev/null +++ b/test/core/nanopb/corpus_response/2d4c0908ecc0310ea234d10b6bdb4f4ca3c41dd1 @@ -0,0 +1 @@ +):):\bJ' \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/304e8cdc9122b709ec2c063a5c8c38489a788033 b/test/core/nanopb/corpus_response/304e8cdc9122b709ec2c063a5c8c38489a788033 new file mode 100644 index 0000000000..a7571c0e84 Binary files /dev/null and b/test/core/nanopb/corpus_response/304e8cdc9122b709ec2c063a5c8c38489a788033 differ diff --git a/test/core/nanopb/corpus_response/324d4a2aed8bc1840fee212fd38dadec80a72ea2 b/test/core/nanopb/corpus_response/324d4a2aed8bc1840fee212fd38dadec80a72ea2 new file mode 100644 index 0000000000..9ca38b3256 Binary files /dev/null and b/test/core/nanopb/corpus_response/324d4a2aed8bc1840fee212fd38dadec80a72ea2 differ diff --git a/test/core/nanopb/corpus_response/33353a0b011901a13d010c6b165074ccdaa717ac b/test/core/nanopb/corpus_response/33353a0b011901a13d010c6b165074ccdaa717ac new file mode 100644 index 0000000000..9320a7a95d --- /dev/null +++ b/test/core/nanopb/corpus_response/33353a0b011901a13d010c6b165074ccdaa717ac @@ -0,0 +1 @@ +ž½“ƒÎ)±Ì)::\!;):bJ):'\éb* \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/37dfead09389fcd9b9d24ef817a0fed13d8ff2b0 b/test/core/nanopb/corpus_response/37dfead09389fcd9b9d24ef817a0fed13d8ff2b0 new file mode 100644 index 0000000000..725e601a5b Binary files /dev/null and b/test/core/nanopb/corpus_response/37dfead09389fcd9b9d24ef817a0fed13d8ff2b0 differ diff --git a/test/core/nanopb/corpus_response/47879cc364be304754f6af15563ad6f9a538da41 b/test/core/nanopb/corpus_response/47879cc364be304754f6af15563ad6f9a538da41 new file mode 100644 index 0000000000..b42661c56c Binary files /dev/null and b/test/core/nanopb/corpus_response/47879cc364be304754f6af15563ad6f9a538da41 differ diff --git a/test/core/nanopb/corpus_response/49a5cef4c730ecab22712b156ddba5106f165afd b/test/core/nanopb/corpus_response/49a5cef4c730ecab22712b156ddba5106f165afd new file mode 100644 index 0000000000..4a551cf6de --- /dev/null +++ b/test/core/nanopb/corpus_response/49a5cef4c730ecab22712b156ddba5106f165afd @@ -0,0 +1 @@ +(z!;:8!(¼;ªo!>::†©;=È( );ö;!ÞØ*:):B(r''' *þEàh;**!!Ý**** \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/4bbbbb794a098deeacff73b774c30f12c54ceacb b/test/core/nanopb/corpus_response/4bbbbb794a098deeacff73b774c30f12c54ceacb new file mode 100644 index 0000000000..d99c09f882 --- /dev/null +++ b/test/core/nanopb/corpus_response/4bbbbb794a098deeacff73b774c30f12c54ceacb @@ -0,0 +1 @@ +(z%;28!(¼;ª!*>::†(z%;28!(¼;ª!>::†ùâåò© \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/4c498ce69c8476f745693deb23272930e05cad60 b/test/core/nanopb/corpus_response/4c498ce69c8476f745693deb23272930e05cad60 new file mode 100644 index 0000000000..86181941cb Binary files /dev/null and b/test/core/nanopb/corpus_response/4c498ce69c8476f745693deb23272930e05cad60 differ diff --git a/test/core/nanopb/corpus_response/4fb5e3085c32e9bccac9e18343cca07017d037de b/test/core/nanopb/corpus_response/4fb5e3085c32e9bccac9e18343cca07017d037de new file mode 100644 index 0000000000..59a8026f2a Binary files /dev/null and b/test/core/nanopb/corpus_response/4fb5e3085c32e9bccac9e18343cca07017d037de differ diff --git a/test/core/nanopb/corpus_response/4fe5e46c1299e7f3e8a41dde3ae1bf1b60b4a43c b/test/core/nanopb/corpus_response/4fe5e46c1299e7f3e8a41dde3ae1bf1b60b4a43c new file mode 100644 index 0000000000..3d44fadc61 --- /dev/null +++ b/test/core/nanopb/corpus_response/4fe5e46c1299e7f3e8a41dde3ae1bf1b60b4a43c @@ -0,0 +1 @@ +a¶(6)!á•( !!)b:'Ü:*¤();Ì0();)Ï(|)ÿ!V)'*¡!t::†©;=È( );ö;!ÞØ*:):B(r''' *Eàhþ;**!!Ý**** \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/acbbd60eeb76e41ce254d0fef353b92abe69c831 b/test/core/nanopb/corpus_response/acbbd60eeb76e41ce254d0fef353b92abe69c831 new file mode 100644 index 0000000000..da47491fb1 --- /dev/null +++ b/test/core/nanopb/corpus_response/acbbd60eeb76e41ce254d0fef353b92abe69c831 @@ -0,0 +1,2 @@ +½ƒ;Î)±}!;*;*°'';y©É:p +'!(S‘ð?±(¬;I:;:*:w!)èŽwÄÂ)>Å?)N!õ;)— +' \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/c1eed32e1e353737987da851ad760312ea8e557c b/test/core/nanopb/corpus_response/c1eed32e1e353737987da851ad760312ea8e557c new file mode 100644 index 0000000000..8f8d149245 --- /dev/null +++ b/test/core/nanopb/corpus_response/c1eed32e1e353737987da851ad760312ea8e557c @@ -0,0 +1 @@ +½)ƒ;Î)±}):):\!;):bJ):'\b* \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/c4214ace2c4bab24bb356f71aedca08544baad70 b/test/core/nanopb/corpus_response/c4214ace2c4bab24bb356f71aedca08544baad70 new file mode 100644 index 0000000000..ae25d72c91 --- /dev/null +++ b/test/core/nanopb/corpus_response/c4214ace2c4bab24bb356f71aedca08544baad70 @@ -0,0 +1 @@ +):\bJ'!:׸¶…''*Ž;» *j:M[(…¤!yæ“:)T²P'^)(0©!e&–°ˆ(*W;Ânc''(!$) \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/c4f87a6290aee1acfc1f26083974ce94621fca64 b/test/core/nanopb/corpus_response/c4f87a6290aee1acfc1f26083974ce94621fca64 new file mode 100644 index 0000000000..a4ceb359eb --- /dev/null +++ b/test/core/nanopb/corpus_response/c4f87a6290aee1acfc1f26083974ce94621fca64 @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/d285d78d3ba966b4b199453d38ead1aa36a7484f b/test/core/nanopb/corpus_response/d285d78d3ba966b4b199453d38ead1aa36a7484f new file mode 100644 index 0000000000..91b1d68f72 Binary files /dev/null and b/test/core/nanopb/corpus_response/d285d78d3ba966b4b199453d38ead1aa36a7484f differ diff --git a/test/core/nanopb/corpus_response/df5200f371cff3cae0e1595cd86d641725f5d1ba b/test/core/nanopb/corpus_response/df5200f371cff3cae0e1595cd86d641725f5d1ba new file mode 100644 index 0000000000..bfd9f8b3cd --- /dev/null +++ b/test/core/nanopb/corpus_response/df5200f371cff3cae0e1595cd86d641725f5d1ba @@ -0,0 +1 @@ +((³34('‰Äúx¡'¦/8(ô](:'çxR$;§'*”!(Ú(!k:(³;;*(/'-½':*:mç4'å%·Â \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/dfc66cb172919102f3ba14f6816228aa46f78154 b/test/core/nanopb/corpus_response/dfc66cb172919102f3ba14f6816228aa46f78154 new file mode 100644 index 0000000000..13f69eb579 --- /dev/null +++ b/test/core/nanopb/corpus_response/dfc66cb172919102f3ba14f6816228aa46f78154 @@ -0,0 +1 @@ +(z%;28!(¼;ª!>::†©;=( ;;)!ÈÞØm!''÷:)ˆ*:') \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/e53e789a4c175c6a2c468472f1047d0fe8db1177 b/test/core/nanopb/corpus_response/e53e789a4c175c6a2c468472f1047d0fe8db1177 new file mode 100644 index 0000000000..a6991c85bc Binary files /dev/null and b/test/core/nanopb/corpus_response/e53e789a4c175c6a2c468472f1047d0fe8db1177 differ diff --git a/test/core/nanopb/corpus_response/e67fe6794e755ea801272980f2c272edb027f6dc b/test/core/nanopb/corpus_response/e67fe6794e755ea801272980f2c272edb027f6dc new file mode 100644 index 0000000000..1b1486731a --- /dev/null +++ b/test/core/nanopb/corpus_response/e67fe6794e755ea801272980f2c272edb027f6dc @@ -0,0 +1 @@ +½“ƒ;Î)±Ì):;:\!;):bJ):'\b* \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/ead61e86fedf118df8e44ed70ce002be651cf291 b/test/core/nanopb/corpus_response/ead61e86fedf118df8e44ed70ce002be651cf291 new file mode 100644 index 0000000000..a4c11a7fb6 Binary files /dev/null and b/test/core/nanopb/corpus_response/ead61e86fedf118df8e44ed70ce002be651cf291 differ diff --git a/test/core/nanopb/corpus_response/eced8b29efbdc82eb8a1d0865c5f382f0ff78446 b/test/core/nanopb/corpus_response/eced8b29efbdc82eb8a1d0865c5f382f0ff78446 new file mode 100644 index 0000000000..a0f0de07ef --- /dev/null +++ b/test/core/nanopb/corpus_response/eced8b29efbdc82eb8a1d0865c5f382f0ff78446 @@ -0,0 +1 @@ +(z%;28!(¼;ª!*>::†(z%;28!(¼;ª!>::†©©Ï \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/f58a9135d07ea9a5e3e710f6b3bf6d48d5942dfd b/test/core/nanopb/corpus_response/f58a9135d07ea9a5e3e710f6b3bf6d48d5942dfd new file mode 100644 index 0000000000..17dfae3c71 Binary files /dev/null and b/test/core/nanopb/corpus_response/f58a9135d07ea9a5e3e710f6b3bf6d48d5942dfd differ diff --git a/test/core/nanopb/corpus_response/f8c2c4ddd2f474b4839f13a9be862c00ab0ece77 b/test/core/nanopb/corpus_response/f8c2c4ddd2f474b4839f13a9be862c00ab0ece77 new file mode 100644 index 0000000000..a94e0c85ac Binary files /dev/null and b/test/core/nanopb/corpus_response/f8c2c4ddd2f474b4839f13a9be862c00ab0ece77 differ diff --git a/test/core/nanopb/corpus_response/faa1781e1444bba5b8c677bc5e2a38d023a1ec65 b/test/core/nanopb/corpus_response/faa1781e1444bba5b8c677bc5e2a38d023a1ec65 new file mode 100644 index 0000000000..013d565bb4 --- /dev/null +++ b/test/core/nanopb/corpus_response/faa1781e1444bba5b8c677bc5e2a38d023a1ec65 @@ -0,0 +1 @@ +‚ \ No newline at end of file diff --git a/test/core/nanopb/corpus_response/fccda587af845f0685275960649d8f4a45272a95 b/test/core/nanopb/corpus_response/fccda587af845f0685275960649d8f4a45272a95 new file mode 100644 index 0000000000..cfdf87919b --- /dev/null +++ b/test/core/nanopb/corpus_response/fccda587af845f0685275960649d8f4a45272a95 @@ -0,0 +1 @@ +½™'Ì)%±'ƒ™Þ½)ƒ;Î)±}9:):\!;):bJ)):'\:b* \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/000def12957806bb0d40005cb651d35b4cde7b4e b/test/core/nanopb/corpus_serverlist/000def12957806bb0d40005cb651d35b4cde7b4e new file mode 100644 index 0000000000..314425728d --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/000def12957806bb0d40005cb651d35b4cde7b4e @@ -0,0 +1,3 @@ + É=Éÿ + '! +É)='! 'ïï ' ½=ï!)**Í \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/0068af2acc3020f344ee84b2c8adfb90492354c3 b/test/core/nanopb/corpus_serverlist/0068af2acc3020f344ee84b2c8adfb90492354c3 new file mode 100644 index 0000000000..d2ae3657ad --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/0068af2acc3020f344ee84b2c8adfb90492354c3 @@ -0,0 +1 @@ +Á²²Wo:'ì*'!@*(Á*!)(@)ÁP²²²²(!( \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/009132022c3a1660b701728ac92e26baf82e8eac b/test/core/nanopb/corpus_serverlist/009132022c3a1660b701728ac92e26baf82e8eac new file mode 100644 index 0000000000..1b9e2f9ee6 Binary files /dev/null and b/test/core/nanopb/corpus_serverlist/009132022c3a1660b701728ac92e26baf82e8eac differ diff --git a/test/core/nanopb/corpus_serverlist/00bf0233aa1155b34a3081e4a2b7a1c9cdf8ea1e b/test/core/nanopb/corpus_serverlist/00bf0233aa1155b34a3081e4a2b7a1c9cdf8ea1e new file mode 100644 index 0000000000..3fc89e839a --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/00bf0233aa1155b34a3081e4a2b7a1c9cdf8ea1e @@ -0,0 +1,2 @@ +Ų;Ų +UõUú‰Ù( Ų;²UUú‰*Ų;²UÅÙ(Ž²'Ö!…z%)#­€ \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/013197cfb12b59755b807501c6d6615859f9cd3f b/test/core/nanopb/corpus_serverlist/013197cfb12b59755b807501c6d6615859f9cd3f new file mode 100644 index 0000000000..ae044dc77f --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/013197cfb12b59755b807501c6d6615859f9cd3f @@ -0,0 +1 @@ +)Û)¦­'U!a Øç•ÏøÉ=*×Éÿ \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/018a4332eb19f2398162317cb6ad2e8cf700dfd6 b/test/core/nanopb/corpus_serverlist/018a4332eb19f2398162317cb6ad2e8cf700dfd6 new file mode 100644 index 0000000000..2519ccb195 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/018a4332eb19f2398162317cb6ad2e8cf700dfd6 @@ -0,0 +1 @@ +)B!B!à@)ò);'Ç“¢ƒ§'à@*::sED'tÂ'–!();!)*!­) \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/0273d3496bf5f4594e59083ac319f8f863a15be0 b/test/core/nanopb/corpus_serverlist/0273d3496bf5f4594e59083ac319f8f863a15be0 new file mode 100644 index 0000000000..609e652597 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/0273d3496bf5f4594e59083ac319f8f863a15be0 @@ -0,0 +1 @@ +Á²•Wo:'ì*#!@ :*)Á²²Wo:'Wo*'!@*()*()@)(!:)Áü²²²(!' \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/0355002521e74dcdb3a0c633338bd02ab1d85312 b/test/core/nanopb/corpus_serverlist/0355002521e74dcdb3a0c633338bd02ab1d85312 new file mode 100644 index 0000000000..6e2df12eb6 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/0355002521e74dcdb3a0c633338bd02ab1d85312 @@ -0,0 +1,3 @@ +!¼;@oCÙ'–((!*Ú*'‚'*') +!((š;!x!(*:)ÞNË):y +œ“)I;ô):()”o:;©ä(*(; \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/053d8d6ceeba9453c97d0ee5374db863e6f77ad4 b/test/core/nanopb/corpus_serverlist/053d8d6ceeba9453c97d0ee5374db863e6f77ad4 new file mode 100644 index 0000000000..268720a2e7 Binary files /dev/null and b/test/core/nanopb/corpus_serverlist/053d8d6ceeba9453c97d0ee5374db863e6f77ad4 differ diff --git a/test/core/nanopb/corpus_serverlist/0628c29e3ae264f8fa08652435bb3e61afe60883 b/test/core/nanopb/corpus_serverlist/0628c29e3ae264f8fa08652435bb3e61afe60883 new file mode 100644 index 0000000000..235fa37d29 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/0628c29e3ae264f8fa08652435bb3e61afe60883 @@ -0,0 +1 @@ +2;ò•:.<ý:* ::ƒž*Š):’ªÜ:2;ò•:ô(ã**.<ý:* ::ƒž*Š)!'dv!*!”¾(;'**:W \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/065e91578e5359b70a668164310af6f0dd40e922 b/test/core/nanopb/corpus_serverlist/065e91578e5359b70a668164310af6f0dd40e922 new file mode 100644 index 0000000000..25d794756f --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/065e91578e5359b70a668164310af6f0dd40e922 @@ -0,0 +1,2 @@ + +Á²²ò \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/06b4b617d5937da8a7b58aed5341dc5ef6d1bcd7 b/test/core/nanopb/corpus_serverlist/06b4b617d5937da8a7b58aed5341dc5ef6d1bcd7 new file mode 100644 index 0000000000..78bdaad21d --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/06b4b617d5937da8a7b58aed5341dc5ef6d1bcd7 @@ -0,0 +1 @@ +!¼;)@oCÙ diff --git a/test/core/nanopb/corpus_serverlist/07216a4f5934890b89d845f6256546c2681350ce b/test/core/nanopb/corpus_serverlist/07216a4f5934890b89d845f6256546c2681350ce new file mode 100644 index 0000000000..e48a1b5254 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/07216a4f5934890b89d845f6256546c2681350ce @@ -0,0 +1,3 @@ +)­'Û¦)U!a Øç•ÏøÉÿ×' É=Éÿ + !'!É +)='! 'ïï  É=ÿ '):(: \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/08584e8308b7f52f0fe380358800d7f585cba89c b/test/core/nanopb/corpus_serverlist/08584e8308b7f52f0fe380358800d7f585cba89c new file mode 100644 index 0000000000..20fafeee24 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/08584e8308b7f52f0fe380358800d7f585cba89c @@ -0,0 +1 @@ +Øì÷(!½Æ)!5Sã::`…¶(p½!'e€*'U)))(:)婤;*:!p(È':Ö¶;óÑ))e);À'!;:µ \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/085a37568e99ec5855bd96affd259921515479e8 b/test/core/nanopb/corpus_serverlist/085a37568e99ec5855bd96affd259921515479e8 new file mode 100644 index 0000000000..b441046fb8 --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/085a37568e99ec5855bd96affd259921515479e8 @@ -0,0 +1,2 @@ +Á²•W!o:'ì*#! Á::()*@:)Á|²²²Á;9!' +²Áƒ'’² \ No newline at end of file diff --git a/test/core/nanopb/corpus_serverlist/0903d1e9297179c18de6a3707b16f27d0d54ed67 b/test/core/nanopb/corpus_serverlist/0903d1e9297179c18de6a3707b16f27d0d54ed67 new file mode 100644 index 0000000000..ccb513ddec --- /dev/null +++ b/test/core/nanopb/corpus_serverlist/0903d1e9297179c18de6a3707b16f27d0d54ed67 @@ -0,0 +1 @@ +(Õ';¤**´'Xò;)() +#include + +#include + +#include "src/core/ext/lb_policy/grpclb/load_balancer_api.h" + +int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { + gpr_slice slice = gpr_slice_from_copied_buffer((const char *)data, size); + grpc_grpclb_response *response; + if ((response = grpc_grpclb_response_parse(slice))) { + grpc_grpclb_response_destroy(response); + } + gpr_slice_unref(slice); + return 0; +} diff --git a/test/core/nanopb/fuzzer_serverlist.c b/test/core/nanopb/fuzzer_serverlist.c new file mode 100644 index 0000000000..d4ec74f0e7 --- /dev/null +++ b/test/core/nanopb/fuzzer_serverlist.c @@ -0,0 +1,49 @@ +/* + * + * Copyright 2016, Google Inc. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include +#include + +#include + +#include "src/core/ext/lb_policy/grpclb/load_balancer_api.h" + +int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { + gpr_slice slice = gpr_slice_from_copied_buffer((const char *)data, size); + grpc_grpclb_serverlist *serverlist; + if ((serverlist = grpc_grpclb_response_parse_serverlist(slice))) { + grpc_grpclb_destroy_serverlist(serverlist); + } + gpr_slice_unref(slice); + return 0; +} diff --git a/tools/fuzzer/runners/nanopb_fuzzer_response_test.sh b/tools/fuzzer/runners/nanopb_fuzzer_response_test.sh new file mode 100644 index 0000000000..aaa7ceefc6 --- /dev/null +++ b/tools/fuzzer/runners/nanopb_fuzzer_response_test.sh @@ -0,0 +1,38 @@ +#!/bin/bash +# Copyright 2016, Google Inc. +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are +# met: +# +# * Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# * Redistributions in binary form must reproduce the above +# copyright notice, this list of conditions and the following disclaimer +# in the documentation and/or other materials provided with the +# distribution. +# * Neither the name of Google Inc. nor the names of its +# contributors may be used to endorse or promote products derived from +# this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# + +flags="-max_total_time=3600 -jobs=3 -workers=3" +if [ "$config" == "asan-trace-cmp" ] +then + flags="-use_traces=1 $flags" +fi + +bins/$config/nanopb_fuzzer_response_test $flags fuzzer_output test/core/nanopb/corpus_response diff --git a/tools/fuzzer/runners/nanopb_fuzzer_serverlist_test.sh b/tools/fuzzer/runners/nanopb_fuzzer_serverlist_test.sh new file mode 100644 index 0000000000..621a4e8b67 --- /dev/null +++ b/tools/fuzzer/runners/nanopb_fuzzer_serverlist_test.sh @@ -0,0 +1,38 @@ +#!/bin/bash +# Copyright 2016, Google Inc. +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are +# met: +# +# * Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# * Redistributions in binary form must reproduce the above +# copyright notice, this list of conditions and the following disclaimer +# in the documentation and/or other materials provided with the +# distribution. +# * Neither the name of Google Inc. nor the names of its +# contributors may be used to endorse or promote products derived from +# this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# + +flags="-max_total_time=3600 -jobs=3 -workers=3" +if [ "$config" == "asan-trace-cmp" ] +then + flags="-use_traces=1 $flags" +fi + +bins/$config/nanopb_fuzzer_serverlist_test $flags fuzzer_output test/core/nanopb/corpus_serverlist diff --git a/tools/run_tests/sources_and_headers.json b/tools/run_tests/sources_and_headers.json index bc1e34b744..4a873b4464 100644 --- a/tools/run_tests/sources_and_headers.json +++ b/tools/run_tests/sources_and_headers.json @@ -1294,6 +1294,38 @@ "third_party": false, "type": "target" }, + { + "deps": [ + "gpr", + "gpr_test_util", + "grpc", + "grpc_test_util" + ], + "headers": [], + "language": "c", + "name": "nanopb_fuzzer_response_test", + "src": [ + "test/core/nanopb/fuzzer_response.c" + ], + "third_party": false, + "type": "target" + }, + { + "deps": [ + "gpr", + "gpr_test_util", + "grpc", + "grpc_test_util" + ], + "headers": [], + "language": "c", + "name": "nanopb_fuzzer_serverlist_test", + "src": [ + "test/core/nanopb/fuzzer_serverlist.c" + ], + "third_party": false, + "type": "target" + }, { "deps": [ "gpr", @@ -3787,6 +3819,40 @@ "third_party": false, "type": "target" }, + { + "deps": [ + "gpr", + "gpr_test_util", + "grpc", + "grpc_test_util", + "one_input_fuzzer" + ], + "headers": [], + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "src": [ + "test/core/nanopb/fuzzer_response.c" + ], + "third_party": false, + "type": "target" + }, + { + "deps": [ + "gpr", + "gpr_test_util", + "grpc", + "grpc_test_util", + "one_input_fuzzer" + ], + "headers": [], + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "src": [ + "test/core/nanopb/fuzzer_serverlist.c" + ], + "third_party": false, + "type": "target" + }, { "deps": [ "gpr", diff --git a/tools/run_tests/tests.json b/tools/run_tests/tests.json index 795b13d5ce..3be1a1594a 100644 --- a/tools/run_tests/tests.json +++ b/tools/run_tests/tests.json @@ -37791,6 +37791,7310 @@ "posix" ] }, + { + "args": [ + "test/core/nanopb/corpus_response/0c35544f40d428d103e9c5b969ad9cd16767b110" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/0c60ee9ed55c9af6190b132ef6636c1d2abe4540" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/0ecb3e69889c036a86d21eb942077dc9abd649be" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/1324c95dafe597fe05f9babe92fe6fbf181c1897" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/14eb42f7423081b455820daa2c02b358315dc0fa" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/23121c5f633db5d7c1a9f2225240754246fee513" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/235548307ee9f2b0855fded42a871990d9ade956" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/28ed3a797da3c48c309a4ef792147f3c56cfec40" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/2bf123dbfa1d37a04493b5662a4b3b9c147485fc" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/2d4c0908ecc0310ea234d10b6bdb4f4ca3c41dd1" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/304e8cdc9122b709ec2c063a5c8c38489a788033" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/324d4a2aed8bc1840fee212fd38dadec80a72ea2" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/33353a0b011901a13d010c6b165074ccdaa717ac" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/37dfead09389fcd9b9d24ef817a0fed13d8ff2b0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/47879cc364be304754f6af15563ad6f9a538da41" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/49a5cef4c730ecab22712b156ddba5106f165afd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/4bbbbb794a098deeacff73b774c30f12c54ceacb" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/4c498ce69c8476f745693deb23272930e05cad60" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/4fb5e3085c32e9bccac9e18343cca07017d037de" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/4fe5e46c1299e7f3e8a41dde3ae1bf1b60b4a43c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/670cc6bae958cb4f15e7297fe63959ac5799aa42" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/675f3263af7d1bbb084872f2b23f6d363227e85d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/67fe0d2acc727c8a39a707b92c6cebda9bd20986" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/6d15065785eb8f4b5f17357a520cb4815a2cb355" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/73285d7a70d73b517648067520d921e4477dbbfa" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/747d1ed8bee4c6f0438beaf88ae76d8ef9f63da2" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/763878a34b3adeb99a03b54d09768a4451617016" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/7b4b0c2555178333ba15203a930c88ef7e7500e7" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/7b8a91aa46e370eb61307b4998889dc89775462f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/7cd11836c64f98742fa7beccec5c981ef4dd62ae" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/7d8f4f045e70e8a2cb45dc3c001504f5c2614b16" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/7e9848558fb004e14795b3ebd3e1488dcde1db8c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/89734c37ee267e69a6950c6d60ee541c1be5ccff" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/9034aaf45143996a2b14465c352ab0c6fa26b221" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/91e3b6a3484ab4b95cdeecc5aefe1291824060e8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/95cd94c858e5e97f7df4a5eb7552e5e0d5ce1ec4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/971f42d5a4d9816145ebc9dd28ba33ed3f5860b0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/9db3a1854de87fd643b910aeab50553afc73e667" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/a147873135c6c52d4da03c260a0165bc0ab1b979" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/a710eead945dabbbffa213a980c75f9463a27398" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/a72406e3ca06d941fe8e168bbf67da88a81c947b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/a8a62a7ebb7d68b211ae319e082575935c07d188" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/a8abd012eb59b862bf9bc1ea443d2f35a1a2e222" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/aab56035a3533b5d83a32a439f179eb678250113" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/ac174acef2c5da26fadc7270bab9c8c4e938c463" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/acbbd60eeb76e41ce254d0fef353b92abe69c831" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/c1eed32e1e353737987da851ad760312ea8e557c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/c4214ace2c4bab24bb356f71aedca08544baad70" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/c4f87a6290aee1acfc1f26083974ce94621fca64" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/d285d78d3ba966b4b199453d38ead1aa36a7484f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/df5200f371cff3cae0e1595cd86d641725f5d1ba" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/dfc66cb172919102f3ba14f6816228aa46f78154" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/e53e789a4c175c6a2c468472f1047d0fe8db1177" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/e67fe6794e755ea801272980f2c272edb027f6dc" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/ead61e86fedf118df8e44ed70ce002be651cf291" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/eced8b29efbdc82eb8a1d0865c5f382f0ff78446" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/f58a9135d07ea9a5e3e710f6b3bf6d48d5942dfd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/f8c2c4ddd2f474b4839f13a9be862c00ab0ece77" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/faa1781e1444bba5b8c677bc5e2a38d023a1ec65" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_response/fccda587af845f0685275960649d8f4a45272a95" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_response_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/000def12957806bb0d40005cb651d35b4cde7b4e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0068af2acc3020f344ee84b2c8adfb90492354c3" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/009132022c3a1660b701728ac92e26baf82e8eac" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/00bf0233aa1155b34a3081e4a2b7a1c9cdf8ea1e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/013197cfb12b59755b807501c6d6615859f9cd3f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/018a4332eb19f2398162317cb6ad2e8cf700dfd6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0273d3496bf5f4594e59083ac319f8f863a15be0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0355002521e74dcdb3a0c633338bd02ab1d85312" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/053d8d6ceeba9453c97d0ee5374db863e6f77ad4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0628c29e3ae264f8fa08652435bb3e61afe60883" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/065e91578e5359b70a668164310af6f0dd40e922" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/06b4b617d5937da8a7b58aed5341dc5ef6d1bcd7" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/07216a4f5934890b89d845f6256546c2681350ce" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/08584e8308b7f52f0fe380358800d7f585cba89c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/085a37568e99ec5855bd96affd259921515479e8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0903d1e9297179c18de6a3707b16f27d0d54ed67" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0aa20a75bff4e8af10330c66d288e900146f1a39" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0ae76e2b24ca999bd5e09e517aa4d88f5b5f58a4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0c3025fdfb008a6563ea2a2bb6cbc79b8ccbf8f3" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0d219165cd317142afa36b8b5476cc022c95c4e6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0e053123dd6256de5aff55b0731f913de250c18e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0e065f98325849ac05eed515865b33dba0264cd4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0e4ff715d491c9f0b471c400b71804739b6d400a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0ec94942046cd7e00bc058204c1d046075ca9531" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0f0e8da530eb8c924cee6985d9c3dfd93274ef8c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/0ff365225c981d74b89499d1e708684ed4d0b570" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/113b1efff1677c1b9a24f89aec0c3ecc228ddf62" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/11697d621eab6743ba22715722d5b23830b79075" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/12463318b795c756f389bc0fb1cca9645eafef28" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/12784250cf16ec999529f601ae5c5798e853d34a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/13122d08c1cee0dae6434605917d4cc6d8ea8cc5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/148a1118649dd8aa9b4ed778efdf7c1611aa5d27" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/15dea2bb5fb36a3dd5172796da66a821a32918e7" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/16488fe15a7e33cb41f2b7c159c99154464b3fd3" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1870a48a3c9c1dd9027cbd85beb503b43cff6e89" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1900b6a9123667a79020319aa7fd54d230bc7073" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1a000f1cbccd2ab6f7e623e015ed2e84284c9dbf" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1c1d403f6175d52ac4430d1ef2401b549761707e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1c2ae0e1915e18dffc2215e9121f1afe0e4335c4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1c5d2eef52426db9d0842f3d57b27a219434c512" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1d0676867c1ebce84531035fa7eb86ed00762df5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1d92b263fa70450b0d0aeb81bf5d2f69eefbbd99" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1e843ed4864d6a808b671dd6769ae191ac8a13ad" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/1eb06a34ee568d584c4b33472788889bc68af3f5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/2169c2b4d560d74a5487df68b56f3af1d648f544" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/21f8f7583e58c1c81a3ac8237b5fa58071edf8a4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/231e348407fdcb14412c691b0b20982940160ccd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/27b8f060e3296eaef77dcdd4c2cd11d5650604ac" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/28ed3a797da3c48c309a4ef792147f3c56cfec40" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/291fcc6e043942638fa3c865c0a1be5e4dcc0e70" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/2a7f6c1f8fdc090b24ceb90ab4f3a7b331c06c86" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/2b85f180fe56f84925b274819ce10a8972a594e7" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/2dea73d7d10ba0dcfd103f7542bdf7458e772b2b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/2e9c19f98ef88b83ec2dea8b1b7f92b8337f757b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/2fbd59ffb74aba392b86f4fe2ff8067b6d45cce8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/31059c32ea28d37b7442f51b20e966665662783c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/31f78e35feb36037864df5f8f47136f8e6e4768a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/326d322d1aa31696a14518830e544770f12146ee" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/337df26552e0884ff133cc1be8e72020be38f457" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/33a2a0aa86956097e034b5ee16aeceacee7efc34" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/33d175d1ecb3a85be7dd93d24efc3ddda0a85ad6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/3718a1b790db16bcfc4ec30691fab24ea7bb0b74" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/37aa3946054035b712102a62b71c94747dfd1491" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/37b697adc0708ad12e4ed7355f3f8fdf1b7919ca" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/37bf4642c5e5a806e2042cdf5ead9bf3c97b9ac1" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/37d94ca6a20303389b35404f3dfd20aaa9ff0851" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/39278604f6a1102366464bbe769ae846e542bc56" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/396b57d9a11a1b135e36ad266e155cc0c3b77d21" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/39a49db120a807fe4e80c502254a5009625c7599" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/39f04d1c6d4beefa3e3d6eae3a5317d969787055" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/3b199b80209fa0b8ffedba4381019f8729cc09d6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/3ccf7ffb96c3e4789409db33cc12bfd8ddc24c1a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/3d04382d1fe11ff3b717100aece7f9eff2d04b9b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/3d4eb9f836bb40cf4c734073bcba8b73e4cc93ae" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/41dc8c55e41d32c30865f9761931ddd4c5b740f8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/41ef7b74d212f8f7f6681edcffd0db719030d31d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/431187b5926fa7d0823305a9f87635616ea3ef27" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/44c6da04b8378986721f7225e70a1514695c176c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/450161236e37a1dfc0da6398c4876df82ff640ac" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/45257a176ca6a05ec65a6df430bbb6b85d0a676f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/46d1c2f2edcc9cdc0d1698fa0c8853cb19a6e7d9" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/4764bd4297bf0c405348d2bb87b8fbc02beadcb8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/48199bfd0e2c160f56d03e881bb5dfe276eec462" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/48e865c56e8db13640d6ecbfc0f2486eb77e07d1" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/499b003b8b98edd9dbe2668c8c6af948769d7e87" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/4a55591c4b390c5a36cecc6f1b6f5105300b546b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/4d33f97ec69c64e14dcf205be36a6319ddb8a20d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/4dbfb08904739928e19c2f459040b35ac410f699" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/501bd6fe1de2719cf8d2c517a071e5d883fbe766" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5208871ea8948223b64b304336cea41ac3240244" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5348c71be34967458403bd4b58bb2a8a744d35ee" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/54362c2f6965268d0835a992c3ba656171b8f044" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/54411aa13f6d9118028171935322bbbc74c15329" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/54c50af22d147f192918499b4b3819eb389468a4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/55441aac903d96b36bf8a11bc804234bcf0c04da" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/56e1a7c279482a57fcbca43468df96a791ee22b4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/57cbea7c563d5c4b6b290271b0009c3f348d92da" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/57e11c7a62f0fc807d7b51bb1ef0f0e22f43795b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/585183c1a240df6926689fe1bd8cb434664db4d8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5b2ee8ca40508bf108a729dcb228191670ec34d6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5b47eabaf74479348fd0318f174d649dbe96e7d2" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5ba93c9db0cff93f52b521d7420e43f6eda2784f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5cc827e33932ccf8c72c6a839074e856d93463d8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5cc89bbf687f94ff87241a8f935905e1c441de33" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5ec6596f12462fe9f36924c262f97408b54bbba8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5f8f3af69295223fb04c37d28035bb75b4cbd705" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/5fd76d48b9fefecbdabd4511decc161b25db79dd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/614cf839ccac2d896d61a0ba0ab1f42b2fabafea" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/618305cc2d3d3814d78b77ffbf421b769bd862cf" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/61dfcd913c4f0a8d005bd089c34e95d8dbbf1897" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/65a89e10aab00039680e1f7d014737b634c74d8d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/66a273dbf5e37410efd45518a42b06a65cffe1f0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/673ff0de0702e8098892060a5365c175d8ef18fc" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/68465c782c37bfdd98ac493b0458444bb94336e5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/688451dee13d0be420598c6e205a3bc419173e18" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/68a1d9150e1380c219e0a1deb3993f321e000ecd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/69f49bf7ae8886f5b4c6296fdb1c570256919604" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/6a425f414cd69ffffdbaa34d03eb43841b432e11" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/6ca9e6e85f9b007a0920b0112decbd1403d506da" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/6cd62e3d67b4154639adbe753115bfdd770edddb" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/6d4f2de4cc427417d6335ff5396ea2588509bb5b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/6ea84030dd0b5b03e4720c244ea8b4ec65e1f236" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/710c1fc8cf7dc1386312c34de5057933fcf868b3" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/720e81dcaf83f867288a90293c5de3b088d5c556" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/72cdc8f78ab5237f96ed354264c726ac79ec429c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/73535a4f7af7e4c6aa23556cacd63f6929ac33fe" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/73d7b933a5673a4d6f5905006ef6266dda1e4fba" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/753aea13c82d1f8841c2bd4309b1b55d0ae2ba8d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/754428e00e8a1d0471e00bd9e8f060ab88ab640e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/761c29151b23b4d14ce6261626641df1182f7a96" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7658451dd805f277a5b1c3d4065d752d2d8de5f4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/767e91cedcd9bc1bdac882acc34a53cc23cf4d02" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/77d3754bdd4ea358369c936ed36b974b4181f6ab" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7a95295bebe6237f65deb15ffeccab22716d574d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7ad88b82e87fbfb3d4bddaa2f6e201a151e3a007" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7b1010cc012e34af1d03e8845868ff0e1db3a601" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7d3ddbd11e82807321c9a53835ea897cf43aa7f2" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7da9c5ab5f049da297b0f4c1322edd696202d02a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7e265a019c02e5d089152849ac00bb005fa644f5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/7f33bff4f740eb898b908374b0c1badd47566947" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/81f13b9b65891f2bfce77cb183a06045c461fee6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/846a14a480ffa1ad0f6333f3ecf2be3057ce6aed" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/87373a7f89feba2d50591b433f69877044155af2" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/8833ba4c780c94fc6c3c466f849c0387acefdb20" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/8c23a5ecd20db4da2c061f3463254e9de104c8b9" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/8d883f1577ca8c334b7c6d75ccb71209d71ced13" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/8dc80bd5f5d1fea64412203e304432edcf5f52c4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/8fc9a9ea6ad7d6d51e770076eaddacad9f970c6f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/8fd167de17534776ef57aba2f27675789a11b8db" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9117d3e51560813b3ce4615dced18fa0e4d0a25a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/921c68eaa8776f7544e195ae52224355d08a2d4d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9293945411fca2dc81fc34b36b575a384e6d489e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/933287d66c3ff3f0a21f2c583c763f2f65872ef8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/933d1d91283403f0a56571f533f482e9744eb735" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/93855fc41b3e3004ca6ba85f34b985042d4c9869" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9544f445c39470f05785b52cfc31bb73bda22659" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/97757217fde05ff4fc15c864bf29e9f560fd1c62" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9877c0f2d40dd43878bb0209bbc4b5fa93bec55a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/98bc5065f79dd9d20cdac14ba28f0cf39908cb5f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/992860817f7fb0e49423607355dab973aa7ab815" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/995ee3d74bc6042fd6a8908c9df5a4cb530378d8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9a38c24a6e87e99a72a3a4f007b117ec191a1705" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9aa97a0ffcdc37a8ef487355fb7271eb6891deaa" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/9b9fddc17ed7bc05a81c18f01e800a4e9efd0c8d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a0d4cb9a5a30bb01e8e4f68d636fb173632ed29d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a1e070288ec564d10a8c59779aa07fa771fa1d4f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a23d10723415d20f4ef1ed9b14d9dc24494856a0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a245750cfe4212dca7bfde918de85f64eb053232" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a24bbe3600f4dfd61bb8415c6a291e0521e4f267" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a25104d039a549c8d457ecea3b55369ed312f086" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a33c4fcabe6aebe012cd01c8cb851a9ab0a12098" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a393e1727b0decca9f193179765c3a83d7096437" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a5507f06be4735a3a9e416ea986d52c1a6a20909" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a5adf028c902d17dd6a7ddeadabbed2b36420313" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a6aa1237a282ee3a93f2544bb6bb7704e565209e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a871185cabce7b96c9e2f6ffb40d9901c774b335" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a89d0e67bf53e22533a635f103d1fd400969ad56" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/a8d1b4e5672a501d7a6cd14b2929297f3a82e035" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/aa614cc8d05a3a58c30a890c10b9a0c1d609b228" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/aa65320376f63805cc82b247612b2e05b87bdbee" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/abd3f6e2cc8887942de20e1c257427b825aed0ad" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ad0653a3a63675a7ce797e69b4673866b88ace33" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ae2ce27806f67312e0d0e29a492db9ab9cb9bf4e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ae4c0e671bd004165a1e7877d9c67249a165d2df" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/af75c24dff7e22948ed141c763a1309e6f540bcc" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b0f228c6d0cbbc9f10117f344d5aae6f001d00fa" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b2c6eab05580b85cda591093d3f05c44bf453fce" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b35281c0aae174d1ddc8999d97b9713f8004f285" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b484ae40795cf9730ba94d5a4ca40aa47b88eacb" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b49c2fed1417a981ba29b32be73ee1700bea7ec9" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b68542373c05c0ed25231d09955b2c699d37c45b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b6d42cbe913f7275b574a71f0768781bdb6f45b7" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b80b6c2cae83c2097c7e4c1fb181d47cb8fd0519" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/b90ab62d8591182fd90cd21cdb893178d97f7e0e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ba45c93ee6b8b286798d8791ec049207c448f7cd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ba67e81ef0f9a14bf5a1ca228bff87c681e83a44" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/bbd1f06ddee4fbbd0e5c9c915889862e5df34f9c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/bd982feb5dd4362e6bd9746ed216c25ce2749df4" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/be77053335e6496288fcf8b6c4d0b4abf86493ff" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/bfb53203499969fac4f4be48e1bcd9235c2fa101" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c143576bdb5b34ad89fa3319507ae382a721f587" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c1ac502a15c53a90a1934f4a31d30f93db36dc8a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c1b29883768551fa5aadc38ba6eaad8007b9b85b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c2331fe0660ab5e411f6d38968c706aed390d8f6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c32647119c244cc018bb1863853d5c7bd37090df" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c4098733900c27861bbf74a71afcbbd93d62f8ee" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c4f5769bf3b4f2a55c006b4cf5a3bba44b347241" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c6ea7b2d47402a458d5d03235bb042b61e05b2e8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c7255dc48b42d44f6c0676d6009051b7e1aa885b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c7d77af55176ae0ae5e59f46e48e1e6ea108d799" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c80827341dcdf1c21b303b82ec7e6df7eaf63f3d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c9501031a75c067b6602e2831f03421b87be4496" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/c98f88d962dfbc2a83e08bfbd8a87b0cc5a8b330" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ccd33fa22b2983978f9617b3cde76ea05b683c2c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/cd0e7701fd79879c56f680817a0d2705751b1f44" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/cd1c2b5c2684d831aab5265e9cd6f1ee045dab9b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/cf98e8b01e7a759f28a9c5f59c896317d74ac47c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d1d171589e035be85dc347278f0735151a342d68" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d243143bf9b8adf6be92a157428ec6cbfd785423" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d2cd278979f2842ebd890f1d84712750273ad0fc" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d2e96eb2699c7dd4a183f13d3a063a1aa9c192fd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d3178f8b0d26275667c27bb8533a61643213e4d8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d46f536ea4b601c0ff313a5eb5b47e2b55aa9eb0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d4be3038631eac422022ee23f43b47905a15b2b5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d56b30a2d1b5a2a13ae00392bcb4ca72085310d9" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d67f85948143218d11e2fb7936a119741036045d" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d6930ea81dfd91856a06a0c16483e47616642b4b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d737c10038a92add90e2ebea5c174ed249de8018" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/d758a67f018b176dfc7d29630cf8cb587f5b2a6b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/dc7139105787f3ba67d7971d80796e9cf5786a91" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/dc8ec35f43e994b9c4ac61275d6b934990d42181" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/dd2694fe12a018bc6af6f288b5c22a030eec8049" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/de7424f44508582a953f137195533b7a0191eda7" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/de91a02040d792dfcb71a4cb5aa4c1c006201273" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/deb576067b11f6e2a3a39b0f2ef38ddae5c67b18" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/df58248c414f342c81e056b40bee12d17a08bf61" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e076020b2826abd3a4b960fb33a35fd7d0606dd8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e0bcf682342967c002621acd2563a2157826d156" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e1edca08a7654b42a64647abb0e773eddddb580b" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e2fa528289b5971f5b40b3687a2a6f0d17348de6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e52af0ba8750572b98f3a8968de77811ddff0893" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e5a0f40647f805b5001645ce2d94505e72fa64f3" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e69762f0c6a2750c0b03503a6aec90ffc94bcb72" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e7064f0b80f61dbc65915311032d27baa569ae2a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e863a4420854c36168d2b8dd39ce474ebe11cd26" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e8993f97bb9c83f87c64cfc429095eeaccf32953" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e9875d9a54b3ebc57df4da886cd30a39252ac666" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/e98a9d92bbbac9b1e64c0641e967adebd681b2aa" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/eb7c31f48c77b742fa29126ac78a2c06c41208e8" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ec174492517f988010ed3ddbd003cb388f477bb6" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ec4d6a393be7ec80ccb8c531337a7fc3ef140e66" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ecd40909ab5e2c61841d9fb95b8aacc87651100c" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ed17c8ddb6cc8a0b653dc87aca999d31e80c781a" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ee0b476126bb1c2249b299323718ecef1250645e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ee1fb6a0b4139c07f1cf6bce850eaac9a2db29ba" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/eeac145c017ed35305f0ae69f820fc41e26e7997" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/efac7390c6e3a653d3ce93c3d6902f2f1c281ce0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f0f0dace93d51cd8e045aeacca89424fc836eebc" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f3341b8cc55c0bb6e2d0a1f7f06d68e4f04057f5" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f59ff56e341b94f2bddfd718b48ae9ab1692d720" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f5a1824b9fd9f124df8097017607bcfa00eccfce" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f5b92b69853a5d123bffdc6b0ab093f767ec30ad" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f6aea4c380e41ddef2489ee581ab35e17fa3e8dd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f7b7254a3af7c41cb86e4b23bb93c5a6d55e2583" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f7bdc1b174f53a49c6ef8f8cdb9b8e74e0a5d4ab" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/f98c78c028baf22f39c77faf6e70edb86ac1d927" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/fb440171bca6ff922727e9ff2a4ac40d8d7905ff" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/fc76cc4030b422e4cb5c145c3e8ed122e242acf0" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/fcab3b80624b431e464dc12d3b6da1cf538bd15e" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/fdb3a9b59798d7e851d9074db69422b1d2df38dd" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/fe5de5f387e31b029d589d9b1777fd0d6b3e47b3" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, + { + "args": [ + "test/core/nanopb/corpus_serverlist/ff52d938aaa10c08b2eb0830fc0066c3b57e040f" + ], + "ci_platforms": [ + "linux", + "mac", + "windows", + "posix" + ], + "cpu_cost": 0.1, + "exclude_configs": [], + "flaky": false, + "language": "c", + "name": "nanopb_fuzzer_serverlist_test_one_entry", + "platforms": [ + "linux", + "mac", + "windows", + "posix" + ] + }, { "args": [ "test/core/client_config/uri_corpus/042dc4512fa3d391c5170cf3aa61e6a638f84342" -- cgit v1.2.3