pull/5304/head
Craig Tiller 9 years ago
parent 7a1aab6c2a
commit d78d16499e
  1. 9
      src/core/surface/channel_stack_type.h
  2. 6
      src/core/surface/init.c
  3. 7
      test/core/end2end/fixtures/h2_sockpair+trace.c
  4. 5
      test/core/end2end/fixtures/h2_sockpair.c
  5. 5
      test/core/end2end/fixtures/h2_sockpair_1byte.c

@ -39,13 +39,16 @@
typedef enum {
// normal top-half client channel with load-balancing, connection management
GRPC_CLIENT_CHANNEL,
// abbreviated top-half client channel bound to one subchannel - for internal load balancing implementation
// abbreviated top-half client channel bound to one subchannel - for internal
// load balancing implementation
GRPC_CLIENT_UCHANNEL,
// bottom-half of a client channel: everything that happens post-load balancing (bound to a specific transport)
// bottom-half of a client channel: everything that happens post-load
// balancing (bound to a specific transport)
GRPC_CLIENT_SUBCHANNEL,
// a permanently broken client channel
GRPC_CLIENT_LAME_CHANNEL,
// a directly connected client channel (without load-balancing, directly talks to a transport)
// a directly connected client channel (without load-balancing, directly talks
// to a transport)
GRPC_CLIENT_DIRECT_CHANNEL,
// server side channel
GRPC_SERVER_CHANNEL,

@ -109,7 +109,8 @@ static bool maybe_add_http_filter(grpc_channel_stack_builder *builder,
static void register_builtin_channel_init() {
grpc_channel_init_register_stage(GRPC_CLIENT_CHANNEL, INT_MAX, prepend_filter,
(void *)&grpc_compress_filter);
grpc_channel_init_register_stage(GRPC_CLIENT_DIRECT_CHANNEL, INT_MAX, prepend_filter,
grpc_channel_init_register_stage(GRPC_CLIENT_DIRECT_CHANNEL, INT_MAX,
prepend_filter,
(void *)&grpc_compress_filter);
grpc_channel_init_register_stage(GRPC_CLIENT_UCHANNEL, INT_MAX,
prepend_filter,
@ -182,7 +183,8 @@ void grpc_init(void) {
grpc_register_tracer("http", &grpc_http_trace);
grpc_register_tracer("flowctl", &grpc_flowctl_trace);
grpc_register_tracer("connectivity_state", &grpc_connectivity_state_trace);
grpc_register_tracer("channel_stack_builder", &grpc_trace_channel_stack_builder);
grpc_register_tracer("channel_stack_builder",
&grpc_trace_channel_stack_builder);
grpc_security_pre_init();
grpc_iomgr_init();
grpc_executor_init();

@ -60,7 +60,7 @@
static void server_setup_transport(void *ts, grpc_transport *transport) {
grpc_end2end_test_fixture *f = ts;
grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT;
grpc_server_setup_transport(&exec_ctx, f->server, transport,
grpc_server_setup_transport(&exec_ctx, f->server, transport,
grpc_server_get_channel_args(f->server));
grpc_exec_ctx_finish(&exec_ctx);
}
@ -74,8 +74,9 @@ static void client_setup_transport(grpc_exec_ctx *exec_ctx, void *ts,
grpc_transport *transport) {
sp_client_setup *cs = ts;
cs->f->client = grpc_channel_create(
exec_ctx, "socketpair-target", cs->client_args, GRPC_CLIENT_DIRECT_CHANNEL, transport);
cs->f->client =
grpc_channel_create(exec_ctx, "socketpair-target", cs->client_args,
GRPC_CLIENT_DIRECT_CHANNEL, transport);
}
static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(

@ -73,8 +73,9 @@ static void client_setup_transport(grpc_exec_ctx *exec_ctx, void *ts,
grpc_transport *transport) {
sp_client_setup *cs = ts;
cs->f->client = grpc_channel_create(
exec_ctx, "socketpair-target", cs->client_args, GRPC_CLIENT_DIRECT_CHANNEL, transport);
cs->f->client =
grpc_channel_create(exec_ctx, "socketpair-target", cs->client_args,
GRPC_CLIENT_DIRECT_CHANNEL, transport);
}
static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(

@ -73,8 +73,9 @@ static void client_setup_transport(grpc_exec_ctx *exec_ctx, void *ts,
grpc_transport *transport) {
sp_client_setup *cs = ts;
cs->f->client = grpc_channel_create(
exec_ctx, "socketpair-target", cs->client_args, GRPC_CLIENT_DIRECT_CHANNEL, transport);
cs->f->client =
grpc_channel_create(exec_ctx, "socketpair-target", cs->client_args,
GRPC_CLIENT_DIRECT_CHANNEL, transport);
}
static grpc_end2end_test_fixture chttp2_create_fixture_socketpair(

Loading…
Cancel
Save