From 686acb9b51aa50a8e20aade2ac6c98546f0e2226 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Wed, 19 Oct 2016 15:26:13 -0700 Subject: Fix test --- test/core/end2end/tests/resource_quota_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/core/end2end') diff --git a/test/core/end2end/tests/resource_quota_server.c b/test/core/end2end/tests/resource_quota_server.c index 81850aea58..02fef94f67 100644 --- a/test/core/end2end/tests/resource_quota_server.c +++ b/test/core/end2end/tests/resource_quota_server.c @@ -53,7 +53,7 @@ static grpc_end2end_test_fixture begin_test(grpc_end2end_test_config config, gpr_log(GPR_INFO, "%s/%s", test_name, config.name); f = config.create_fixture(client_args, server_args); config.init_server(&f, server_args); - config.init_client(&f, client_args); + config.init_client(&f, client_args, NULL); return f; } -- cgit v1.2.3 From 6360af642843deb56e60b90f44d6d88aede4d789 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 20 Jan 2017 15:30:12 -0800 Subject: Fix ping test --- test/core/end2end/tests/ping.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'test/core/end2end') diff --git a/test/core/end2end/tests/ping.c b/test/core/end2end/tests/ping.c index 5e5169dedc..0d404229a5 100644 --- a/test/core/end2end/tests/ping.c +++ b/test/core/end2end/tests/ping.c @@ -48,7 +48,12 @@ static void test_ping(grpc_end2end_test_config config) { grpc_connectivity_state state = GRPC_CHANNEL_IDLE; int i; - config.init_client(&f, NULL); + grpc_arg a = {.type = GRPC_ARG_INTEGER, + .key = GRPC_ARG_HTTP2_MIN_TIME_BETWEEN_PINGS_MS, + .value.integer = 0}; + grpc_channel_args client_args = {.num_args = 1, .args = &a}; + + config.init_client(&f, &client_args); config.init_server(&f, NULL); grpc_channel_ping(f.client, f.cq, tag(0), NULL); -- cgit v1.2.3 From fa0579511b21cb7e75b01469678f154f4e1c4033 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 30 Jan 2017 10:16:02 -0800 Subject: Fix bugs --- src/core/ext/transport/chttp2/transport/chttp2_transport.c | 2 ++ src/core/ext/transport/chttp2/transport/frame_ping.c | 3 ++- src/core/ext/transport/chttp2/transport/writing.c | 4 +--- test/core/end2end/tests/ping.c | 12 ++++++++---- 4 files changed, 13 insertions(+), 8 deletions(-) (limited to 'test/core/end2end') diff --git a/src/core/ext/transport/chttp2/transport/chttp2_transport.c b/src/core/ext/transport/chttp2/transport/chttp2_transport.c index de67794f5b..d7cc7314c3 100644 --- a/src/core/ext/transport/chttp2/transport/chttp2_transport.c +++ b/src/core/ext/transport/chttp2/transport/chttp2_transport.c @@ -406,6 +406,8 @@ static void init_transport(grpc_exec_ctx *exec_ctx, grpc_chttp2_transport *t, } } + t->ping_state.pings_before_data_required = t->ping_policy.max_pings_without_data; + grpc_chttp2_initiate_write(exec_ctx, t, false, "init"); post_benign_reclaimer(exec_ctx, t); } diff --git a/src/core/ext/transport/chttp2/transport/frame_ping.c b/src/core/ext/transport/chttp2/transport/frame_ping.c index 7cf36cb94a..f487533c41 100644 --- a/src/core/ext/transport/chttp2/transport/frame_ping.c +++ b/src/core/ext/transport/chttp2/transport/frame_ping.c @@ -103,7 +103,8 @@ grpc_error *grpc_chttp2_ping_parser_parse(grpc_exec_ctx *exec_ctx, void *parser, } else { if (t->ping_ack_count == t->ping_ack_capacity) { t->ping_ack_capacity = GPR_MAX(t->ping_ack_capacity * 3 / 2, 3); - t->ping_acks = gpr_realloc(t->ping_acks, t->ping_ack_capacity * sizeof(*t->ping_acks)); + t->ping_acks = gpr_realloc( + t->ping_acks, t->ping_ack_capacity * sizeof(*t->ping_acks)); } t->ping_acks[t->ping_ack_count++] = p->opaque_8bytes; grpc_chttp2_initiate_write(exec_ctx, t, false, "ping response"); diff --git a/src/core/ext/transport/chttp2/transport/writing.c b/src/core/ext/transport/chttp2/transport/writing.c index 3cb4841336..05e6f59947 100644 --- a/src/core/ext/transport/chttp2/transport/writing.c +++ b/src/core/ext/transport/chttp2/transport/writing.c @@ -335,9 +335,7 @@ bool grpc_chttp2_begin_write(grpc_exec_ctx *exec_ctx, } t->ping_ack_count = 0; - if (t->outbuf.count > 0) { - maybe_initiate_ping(exec_ctx, t, GRPC_CHTTP2_PING_ON_NEXT_WRITE); - } + maybe_initiate_ping(exec_ctx, t, GRPC_CHTTP2_PING_ON_NEXT_WRITE); GPR_TIMER_END("grpc_chttp2_begin_write", 0); diff --git a/test/core/end2end/tests/ping.c b/test/core/end2end/tests/ping.c index 0d404229a5..8c89f6c220 100644 --- a/test/core/end2end/tests/ping.c +++ b/test/core/end2end/tests/ping.c @@ -37,6 +37,7 @@ #include #include #include +#include #include "test/core/end2end/cq_verifier.h" @@ -48,10 +49,13 @@ static void test_ping(grpc_end2end_test_config config) { grpc_connectivity_state state = GRPC_CHANNEL_IDLE; int i; - grpc_arg a = {.type = GRPC_ARG_INTEGER, - .key = GRPC_ARG_HTTP2_MIN_TIME_BETWEEN_PINGS_MS, - .value.integer = 0}; - grpc_channel_args client_args = {.num_args = 1, .args = &a}; + grpc_arg a[] = {{.type = GRPC_ARG_INTEGER, + .key = GRPC_ARG_HTTP2_MIN_TIME_BETWEEN_PINGS_MS, + .value.integer = 0}, + {.type = GRPC_ARG_INTEGER, + .key = GRPC_ARG_HTTP2_MAX_PINGS_WITHOUT_DATA, + .value.integer = 20}}; + grpc_channel_args client_args = {.num_args = GPR_ARRAY_SIZE(a), .args = a}; config.init_client(&f, &client_args); config.init_server(&f, NULL); -- cgit v1.2.3 From 1a5ead340558e8491c0a1fec74129413cfe5888a Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Mon, 30 Jan 2017 14:27:21 -0800 Subject: Accept and count deadline exceeded --- src/core/ext/transport/chttp2/transport/chttp2_transport.c | 3 ++- test/core/end2end/tests/resource_quota_server.c | 13 +++++++++---- 2 files changed, 11 insertions(+), 5 deletions(-) (limited to 'test/core/end2end') diff --git a/src/core/ext/transport/chttp2/transport/chttp2_transport.c b/src/core/ext/transport/chttp2/transport/chttp2_transport.c index d7cc7314c3..692eb3f902 100644 --- a/src/core/ext/transport/chttp2/transport/chttp2_transport.c +++ b/src/core/ext/transport/chttp2/transport/chttp2_transport.c @@ -406,7 +406,8 @@ static void init_transport(grpc_exec_ctx *exec_ctx, grpc_chttp2_transport *t, } } - t->ping_state.pings_before_data_required = t->ping_policy.max_pings_without_data; + t->ping_state.pings_before_data_required = + t->ping_policy.max_pings_without_data; grpc_chttp2_initiate_write(exec_ctx, t, false, "init"); post_benign_reclaimer(exec_ctx, t); diff --git a/test/core/end2end/tests/resource_quota_server.c b/test/core/end2end/tests/resource_quota_server.c index 1000b63add..2886d1ca3d 100644 --- a/test/core/end2end/tests/resource_quota_server.c +++ b/test/core/end2end/tests/resource_quota_server.c @@ -160,6 +160,7 @@ void resource_quota_server(grpc_end2end_test_config config) { int pending_server_end_calls = 0; int cancelled_calls_on_client = 0; int cancelled_calls_on_server = 0; + int deadline_exceeded = 0; grpc_byte_buffer *request_payload = grpc_raw_byte_buffer_create(&request_payload_slice, 1); @@ -247,6 +248,9 @@ void resource_quota_server(grpc_end2end_test_config config) { case GRPC_STATUS_RESOURCE_EXHAUSTED: cancelled_calls_on_client++; break; + case GRPC_STATUS_DEADLINE_EXCEEDED: + deadline_exceeded++; + break; case GRPC_STATUS_OK: break; default: @@ -343,10 +347,11 @@ void resource_quota_server(grpc_end2end_test_config config) { } } - gpr_log( - GPR_INFO, - "Done. %d total calls: %d cancelled at server, %d cancelled at client.", - NUM_CALLS, cancelled_calls_on_server, cancelled_calls_on_client); + gpr_log(GPR_INFO, + "Done. %d total calls: %d cancelled at server, %d cancelled at " + "client, %d timed out.", + NUM_CALLS, cancelled_calls_on_server, cancelled_calls_on_client, + deadline_exceeded); /* The call may be cancelled after the server has sent its status but before * the client has received it. This means that we should see strictly more -- cgit v1.2.3 From eb46816470b3a3c54fc979fe916f80cf43d38ac8 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Thu, 2 Feb 2017 08:37:22 -0800 Subject: Fix potential use-after-free --- test/core/end2end/tests/resource_quota_server.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test/core/end2end') diff --git a/test/core/end2end/tests/resource_quota_server.c b/test/core/end2end/tests/resource_quota_server.c index 4dd3204e45..3aeb9b27f3 100644 --- a/test/core/end2end/tests/resource_quota_server.c +++ b/test/core/end2end/tests/resource_quota_server.c @@ -362,6 +362,9 @@ void resource_quota_server(grpc_end2end_test_config config) { grpc_slice_unref(request_payload_slice); grpc_resource_quota_unref(resource_quota); + end_test(&f); + config.tear_down_data(&f); + free(client_calls); free(server_calls); free(initial_metadata_recv); @@ -372,9 +375,6 @@ void resource_quota_server(grpc_end2end_test_config config) { free(details); free(request_payload_recv); free(was_cancelled); - - end_test(&f); - config.tear_down_data(&f); } void resource_quota_server_pre_init(void) {} -- cgit v1.2.3 From 8b1d59cafac9b2dd30cd080450ee68e85a039dc4 Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Tue, 27 Dec 2016 15:15:30 -0800 Subject: Add some debug utilities This PR adds a set of debug helpers that are intended for calling only from gdb. They cross abstraction boundaries and allow quickly accessing one thing from another thing. I expect to grow this library significantly over time to aid debugging tricky problems. --- CMakeLists.txt | 239 +++++ Makefile | 231 +++++ build.yaml | 11 + src/core/ext/client_channel/client_channel.c | 6 + src/core/ext/client_channel/client_channel.h | 4 + src/core/ext/debug/debugger_macros.c | 71 ++ src/core/ext/debug/debugger_macros.h | 39 + src/core/lib/channel/connected_channel.c | 6 +- src/core/lib/channel/connected_channel.h | 5 + templates/test/core/end2end/end2end_defs.include | 3 + test/core/end2end/end2end_nosec_tests.c | 3 + test/core/end2end/end2end_tests.c | 3 + tools/buildgen/plugins/expand_filegroups.py | 2 +- tools/run_tests/generated/sources_and_headers.json | 24 +- .../vcxproj/grpc_test_util/grpc_test_util.vcxproj | 124 +++ .../grpc_test_util/grpc_test_util.vcxproj.filters | 264 +++++ .../grpc_test_util_unsecure.vcxproj | 493 +++++++++ .../grpc_test_util_unsecure.vcxproj.filters | 1064 ++++++++++++++++++++ 18 files changed, 2587 insertions(+), 5 deletions(-) create mode 100644 src/core/ext/debug/debugger_macros.c create mode 100644 src/core/ext/debug/debugger_macros.h (limited to 'test/core/end2end') diff --git a/CMakeLists.txt b/CMakeLists.txt index 1adf092f9b..3ae2197b16 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1370,6 +1370,7 @@ add_library(grpc_test_util test/core/util/port_uv.c test/core/util/port_windows.c test/core/util/slice_splitter.c + src/core/ext/debug/debugger_macros.c src/core/lib/channel/channel_args.c src/core/lib/channel/channel_stack.c src/core/lib/channel/channel_stack_builder.c @@ -1487,6 +1488,48 @@ add_library(grpc_test_util src/core/lib/transport/timeout_encoding.c src/core/lib/transport/transport.c src/core/lib/transport/transport_op_string.c + src/core/ext/client_channel/channel_connectivity.c + src/core/ext/client_channel/client_channel.c + src/core/ext/client_channel/client_channel_factory.c + src/core/ext/client_channel/client_channel_plugin.c + src/core/ext/client_channel/connector.c + src/core/ext/client_channel/default_initial_connect_string.c + src/core/ext/client_channel/http_connect_handshaker.c + src/core/ext/client_channel/http_proxy.c + src/core/ext/client_channel/initial_connect_string.c + src/core/ext/client_channel/lb_policy.c + src/core/ext/client_channel/lb_policy_factory.c + src/core/ext/client_channel/lb_policy_registry.c + src/core/ext/client_channel/parse_address.c + src/core/ext/client_channel/proxy_mapper.c + src/core/ext/client_channel/proxy_mapper_registry.c + src/core/ext/client_channel/resolver.c + src/core/ext/client_channel/resolver_factory.c + src/core/ext/client_channel/resolver_registry.c + src/core/ext/client_channel/subchannel.c + src/core/ext/client_channel/subchannel_index.c + src/core/ext/client_channel/uri_parser.c + src/core/ext/transport/chttp2/transport/bin_decoder.c + src/core/ext/transport/chttp2/transport/bin_encoder.c + src/core/ext/transport/chttp2/transport/chttp2_plugin.c + src/core/ext/transport/chttp2/transport/chttp2_transport.c + src/core/ext/transport/chttp2/transport/frame_data.c + src/core/ext/transport/chttp2/transport/frame_goaway.c + src/core/ext/transport/chttp2/transport/frame_ping.c + src/core/ext/transport/chttp2/transport/frame_rst_stream.c + src/core/ext/transport/chttp2/transport/frame_settings.c + src/core/ext/transport/chttp2/transport/frame_window_update.c + src/core/ext/transport/chttp2/transport/hpack_encoder.c + src/core/ext/transport/chttp2/transport/hpack_parser.c + src/core/ext/transport/chttp2/transport/hpack_table.c + src/core/ext/transport/chttp2/transport/huffsyms.c + src/core/ext/transport/chttp2/transport/incoming_metadata.c + src/core/ext/transport/chttp2/transport/parsing.c + src/core/ext/transport/chttp2/transport/stream_lists.c + src/core/ext/transport/chttp2/transport/stream_map.c + src/core/ext/transport/chttp2/transport/varint.c + src/core/ext/transport/chttp2/transport/writing.c + src/core/ext/transport/chttp2/alpn/alpn.c ) @@ -1564,6 +1607,166 @@ add_library(grpc_test_util_unsecure test/core/util/port_uv.c test/core/util/port_windows.c test/core/util/slice_splitter.c + src/core/ext/debug/debugger_macros.c + src/core/lib/channel/channel_args.c + src/core/lib/channel/channel_stack.c + src/core/lib/channel/channel_stack_builder.c + src/core/lib/channel/compress_filter.c + src/core/lib/channel/connected_channel.c + src/core/lib/channel/deadline_filter.c + src/core/lib/channel/handshaker.c + src/core/lib/channel/handshaker_factory.c + src/core/lib/channel/handshaker_registry.c + src/core/lib/channel/http_client_filter.c + src/core/lib/channel/http_server_filter.c + src/core/lib/channel/message_size_filter.c + src/core/lib/compression/compression.c + src/core/lib/compression/message_compress.c + src/core/lib/debug/trace.c + src/core/lib/http/format_request.c + src/core/lib/http/httpcli.c + src/core/lib/http/parser.c + src/core/lib/iomgr/closure.c + src/core/lib/iomgr/combiner.c + src/core/lib/iomgr/endpoint.c + src/core/lib/iomgr/endpoint_pair_posix.c + src/core/lib/iomgr/endpoint_pair_uv.c + src/core/lib/iomgr/endpoint_pair_windows.c + src/core/lib/iomgr/error.c + src/core/lib/iomgr/ev_epoll_linux.c + src/core/lib/iomgr/ev_poll_posix.c + src/core/lib/iomgr/ev_posix.c + src/core/lib/iomgr/exec_ctx.c + src/core/lib/iomgr/executor.c + src/core/lib/iomgr/iocp_windows.c + src/core/lib/iomgr/iomgr.c + src/core/lib/iomgr/iomgr_posix.c + src/core/lib/iomgr/iomgr_uv.c + src/core/lib/iomgr/iomgr_windows.c + src/core/lib/iomgr/load_file.c + src/core/lib/iomgr/network_status_tracker.c + src/core/lib/iomgr/polling_entity.c + src/core/lib/iomgr/pollset_set_uv.c + src/core/lib/iomgr/pollset_set_windows.c + src/core/lib/iomgr/pollset_uv.c + src/core/lib/iomgr/pollset_windows.c + src/core/lib/iomgr/resolve_address_posix.c + src/core/lib/iomgr/resolve_address_uv.c + src/core/lib/iomgr/resolve_address_windows.c + src/core/lib/iomgr/resource_quota.c + src/core/lib/iomgr/sockaddr_utils.c + src/core/lib/iomgr/socket_mutator.c + src/core/lib/iomgr/socket_utils_common_posix.c + src/core/lib/iomgr/socket_utils_linux.c + src/core/lib/iomgr/socket_utils_posix.c + src/core/lib/iomgr/socket_utils_uv.c + src/core/lib/iomgr/socket_utils_windows.c + src/core/lib/iomgr/socket_windows.c + src/core/lib/iomgr/tcp_client_posix.c + src/core/lib/iomgr/tcp_client_uv.c + src/core/lib/iomgr/tcp_client_windows.c + src/core/lib/iomgr/tcp_posix.c + src/core/lib/iomgr/tcp_server_posix.c + src/core/lib/iomgr/tcp_server_uv.c + src/core/lib/iomgr/tcp_server_windows.c + src/core/lib/iomgr/tcp_uv.c + src/core/lib/iomgr/tcp_windows.c + src/core/lib/iomgr/time_averaged_stats.c + src/core/lib/iomgr/timer_generic.c + src/core/lib/iomgr/timer_heap.c + src/core/lib/iomgr/timer_uv.c + src/core/lib/iomgr/udp_server.c + src/core/lib/iomgr/unix_sockets_posix.c + src/core/lib/iomgr/unix_sockets_posix_noop.c + src/core/lib/iomgr/wakeup_fd_cv.c + src/core/lib/iomgr/wakeup_fd_eventfd.c + src/core/lib/iomgr/wakeup_fd_nospecial.c + src/core/lib/iomgr/wakeup_fd_pipe.c + src/core/lib/iomgr/wakeup_fd_posix.c + src/core/lib/iomgr/workqueue_uv.c + src/core/lib/iomgr/workqueue_windows.c + src/core/lib/json/json.c + src/core/lib/json/json_reader.c + src/core/lib/json/json_string.c + src/core/lib/json/json_writer.c + src/core/lib/slice/percent_encoding.c + src/core/lib/slice/slice.c + src/core/lib/slice/slice_buffer.c + src/core/lib/slice/slice_hash_table.c + src/core/lib/slice/slice_intern.c + src/core/lib/slice/slice_string_helpers.c + src/core/lib/surface/alarm.c + src/core/lib/surface/api_trace.c + src/core/lib/surface/byte_buffer.c + src/core/lib/surface/byte_buffer_reader.c + src/core/lib/surface/call.c + src/core/lib/surface/call_details.c + src/core/lib/surface/call_log_batch.c + src/core/lib/surface/channel.c + src/core/lib/surface/channel_init.c + src/core/lib/surface/channel_ping.c + src/core/lib/surface/channel_stack_type.c + src/core/lib/surface/completion_queue.c + src/core/lib/surface/event_string.c + src/core/lib/surface/lame_client.c + src/core/lib/surface/metadata_array.c + src/core/lib/surface/server.c + src/core/lib/surface/validate_metadata.c + src/core/lib/surface/version.c + src/core/lib/transport/byte_stream.c + src/core/lib/transport/connectivity_state.c + src/core/lib/transport/error_utils.c + src/core/lib/transport/metadata.c + src/core/lib/transport/metadata_batch.c + src/core/lib/transport/pid_controller.c + src/core/lib/transport/service_config.c + src/core/lib/transport/static_metadata.c + src/core/lib/transport/status_conversion.c + src/core/lib/transport/timeout_encoding.c + src/core/lib/transport/transport.c + src/core/lib/transport/transport_op_string.c + src/core/ext/client_channel/channel_connectivity.c + src/core/ext/client_channel/client_channel.c + src/core/ext/client_channel/client_channel_factory.c + src/core/ext/client_channel/client_channel_plugin.c + src/core/ext/client_channel/connector.c + src/core/ext/client_channel/default_initial_connect_string.c + src/core/ext/client_channel/http_connect_handshaker.c + src/core/ext/client_channel/http_proxy.c + src/core/ext/client_channel/initial_connect_string.c + src/core/ext/client_channel/lb_policy.c + src/core/ext/client_channel/lb_policy_factory.c + src/core/ext/client_channel/lb_policy_registry.c + src/core/ext/client_channel/parse_address.c + src/core/ext/client_channel/proxy_mapper.c + src/core/ext/client_channel/proxy_mapper_registry.c + src/core/ext/client_channel/resolver.c + src/core/ext/client_channel/resolver_factory.c + src/core/ext/client_channel/resolver_registry.c + src/core/ext/client_channel/subchannel.c + src/core/ext/client_channel/subchannel_index.c + src/core/ext/client_channel/uri_parser.c + src/core/ext/transport/chttp2/transport/bin_decoder.c + src/core/ext/transport/chttp2/transport/bin_encoder.c + src/core/ext/transport/chttp2/transport/chttp2_plugin.c + src/core/ext/transport/chttp2/transport/chttp2_transport.c + src/core/ext/transport/chttp2/transport/frame_data.c + src/core/ext/transport/chttp2/transport/frame_goaway.c + src/core/ext/transport/chttp2/transport/frame_ping.c + src/core/ext/transport/chttp2/transport/frame_rst_stream.c + src/core/ext/transport/chttp2/transport/frame_settings.c + src/core/ext/transport/chttp2/transport/frame_window_update.c + src/core/ext/transport/chttp2/transport/hpack_encoder.c + src/core/ext/transport/chttp2/transport/hpack_parser.c + src/core/ext/transport/chttp2/transport/hpack_table.c + src/core/ext/transport/chttp2/transport/huffsyms.c + src/core/ext/transport/chttp2/transport/incoming_metadata.c + src/core/ext/transport/chttp2/transport/parsing.c + src/core/ext/transport/chttp2/transport/stream_lists.c + src/core/ext/transport/chttp2/transport/stream_map.c + src/core/ext/transport/chttp2/transport/varint.c + src/core/ext/transport/chttp2/transport/writing.c + src/core/ext/transport/chttp2/alpn/alpn.c ) @@ -1586,6 +1789,42 @@ target_link_libraries(grpc_test_util_unsecure grpc ) +foreach(_hdr + include/grpc/byte_buffer.h + include/grpc/byte_buffer_reader.h + include/grpc/compression.h + include/grpc/grpc.h + include/grpc/grpc_posix.h + include/grpc/grpc_security_constants.h + include/grpc/slice.h + include/grpc/slice_buffer.h + include/grpc/status.h + include/grpc/impl/codegen/byte_buffer_reader.h + include/grpc/impl/codegen/compression_types.h + include/grpc/impl/codegen/connectivity_state.h + include/grpc/impl/codegen/exec_ctx_fwd.h + include/grpc/impl/codegen/grpc_types.h + include/grpc/impl/codegen/propagation_bits.h + include/grpc/impl/codegen/status.h + include/grpc/impl/codegen/atm.h + include/grpc/impl/codegen/atm_gcc_atomic.h + include/grpc/impl/codegen/atm_gcc_sync.h + include/grpc/impl/codegen/atm_windows.h + include/grpc/impl/codegen/gpr_slice.h + include/grpc/impl/codegen/gpr_types.h + include/grpc/impl/codegen/port_platform.h + include/grpc/impl/codegen/slice.h + include/grpc/impl/codegen/sync.h + include/grpc/impl/codegen/sync_generic.h + include/grpc/impl/codegen/sync_posix.h + include/grpc/impl/codegen/sync_windows.h +) + string(REPLACE "include/" "" _path ${_hdr}) + get_filename_component(_path ${_path} PATH) + install(FILES ${_hdr} + DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/${_path}" + ) +endforeach() endif (gRPC_BUILD_TESTS) diff --git a/Makefile b/Makefile index 66b5db7f03..c575624a74 100644 --- a/Makefile +++ b/Makefile @@ -3230,6 +3230,7 @@ LIBGRPC_TEST_UTIL_SRC = \ test/core/util/port_uv.c \ test/core/util/port_windows.c \ test/core/util/slice_splitter.c \ + src/core/ext/debug/debugger_macros.c \ src/core/lib/channel/channel_args.c \ src/core/lib/channel/channel_stack.c \ src/core/lib/channel/channel_stack_builder.c \ @@ -3347,6 +3348,48 @@ LIBGRPC_TEST_UTIL_SRC = \ src/core/lib/transport/timeout_encoding.c \ src/core/lib/transport/transport.c \ src/core/lib/transport/transport_op_string.c \ + src/core/ext/client_channel/channel_connectivity.c \ + src/core/ext/client_channel/client_channel.c \ + src/core/ext/client_channel/client_channel_factory.c \ + src/core/ext/client_channel/client_channel_plugin.c \ + src/core/ext/client_channel/connector.c \ + src/core/ext/client_channel/default_initial_connect_string.c \ + src/core/ext/client_channel/http_connect_handshaker.c \ + src/core/ext/client_channel/http_proxy.c \ + src/core/ext/client_channel/initial_connect_string.c \ + src/core/ext/client_channel/lb_policy.c \ + src/core/ext/client_channel/lb_policy_factory.c \ + src/core/ext/client_channel/lb_policy_registry.c \ + src/core/ext/client_channel/parse_address.c \ + src/core/ext/client_channel/proxy_mapper.c \ + src/core/ext/client_channel/proxy_mapper_registry.c \ + src/core/ext/client_channel/resolver.c \ + src/core/ext/client_channel/resolver_factory.c \ + src/core/ext/client_channel/resolver_registry.c \ + src/core/ext/client_channel/subchannel.c \ + src/core/ext/client_channel/subchannel_index.c \ + src/core/ext/client_channel/uri_parser.c \ + src/core/ext/transport/chttp2/transport/bin_decoder.c \ + src/core/ext/transport/chttp2/transport/bin_encoder.c \ + src/core/ext/transport/chttp2/transport/chttp2_plugin.c \ + src/core/ext/transport/chttp2/transport/chttp2_transport.c \ + src/core/ext/transport/chttp2/transport/frame_data.c \ + src/core/ext/transport/chttp2/transport/frame_goaway.c \ + src/core/ext/transport/chttp2/transport/frame_ping.c \ + src/core/ext/transport/chttp2/transport/frame_rst_stream.c \ + src/core/ext/transport/chttp2/transport/frame_settings.c \ + src/core/ext/transport/chttp2/transport/frame_window_update.c \ + src/core/ext/transport/chttp2/transport/hpack_encoder.c \ + src/core/ext/transport/chttp2/transport/hpack_parser.c \ + src/core/ext/transport/chttp2/transport/hpack_table.c \ + src/core/ext/transport/chttp2/transport/huffsyms.c \ + src/core/ext/transport/chttp2/transport/incoming_metadata.c \ + src/core/ext/transport/chttp2/transport/parsing.c \ + src/core/ext/transport/chttp2/transport/stream_lists.c \ + src/core/ext/transport/chttp2/transport/stream_map.c \ + src/core/ext/transport/chttp2/transport/varint.c \ + src/core/ext/transport/chttp2/transport/writing.c \ + src/core/ext/transport/chttp2/alpn/alpn.c \ PUBLIC_HEADERS_C += \ include/grpc/byte_buffer.h \ @@ -3428,8 +3471,196 @@ LIBGRPC_TEST_UTIL_UNSECURE_SRC = \ test/core/util/port_uv.c \ test/core/util/port_windows.c \ test/core/util/slice_splitter.c \ + src/core/ext/debug/debugger_macros.c \ + src/core/lib/channel/channel_args.c \ + src/core/lib/channel/channel_stack.c \ + src/core/lib/channel/channel_stack_builder.c \ + src/core/lib/channel/compress_filter.c \ + src/core/lib/channel/connected_channel.c \ + src/core/lib/channel/deadline_filter.c \ + src/core/lib/channel/handshaker.c \ + src/core/lib/channel/handshaker_factory.c \ + src/core/lib/channel/handshaker_registry.c \ + src/core/lib/channel/http_client_filter.c \ + src/core/lib/channel/http_server_filter.c \ + src/core/lib/channel/message_size_filter.c \ + src/core/lib/compression/compression.c \ + src/core/lib/compression/message_compress.c \ + src/core/lib/debug/trace.c \ + src/core/lib/http/format_request.c \ + src/core/lib/http/httpcli.c \ + src/core/lib/http/parser.c \ + src/core/lib/iomgr/closure.c \ + src/core/lib/iomgr/combiner.c \ + src/core/lib/iomgr/endpoint.c \ + src/core/lib/iomgr/endpoint_pair_posix.c \ + src/core/lib/iomgr/endpoint_pair_uv.c \ + src/core/lib/iomgr/endpoint_pair_windows.c \ + src/core/lib/iomgr/error.c \ + src/core/lib/iomgr/ev_epoll_linux.c \ + src/core/lib/iomgr/ev_poll_posix.c \ + src/core/lib/iomgr/ev_posix.c \ + src/core/lib/iomgr/exec_ctx.c \ + src/core/lib/iomgr/executor.c \ + src/core/lib/iomgr/iocp_windows.c \ + src/core/lib/iomgr/iomgr.c \ + src/core/lib/iomgr/iomgr_posix.c \ + src/core/lib/iomgr/iomgr_uv.c \ + src/core/lib/iomgr/iomgr_windows.c \ + src/core/lib/iomgr/load_file.c \ + src/core/lib/iomgr/network_status_tracker.c \ + src/core/lib/iomgr/polling_entity.c \ + src/core/lib/iomgr/pollset_set_uv.c \ + src/core/lib/iomgr/pollset_set_windows.c \ + src/core/lib/iomgr/pollset_uv.c \ + src/core/lib/iomgr/pollset_windows.c \ + src/core/lib/iomgr/resolve_address_posix.c \ + src/core/lib/iomgr/resolve_address_uv.c \ + src/core/lib/iomgr/resolve_address_windows.c \ + src/core/lib/iomgr/resource_quota.c \ + src/core/lib/iomgr/sockaddr_utils.c \ + src/core/lib/iomgr/socket_mutator.c \ + src/core/lib/iomgr/socket_utils_common_posix.c \ + src/core/lib/iomgr/socket_utils_linux.c \ + src/core/lib/iomgr/socket_utils_posix.c \ + src/core/lib/iomgr/socket_utils_uv.c \ + src/core/lib/iomgr/socket_utils_windows.c \ + src/core/lib/iomgr/socket_windows.c \ + src/core/lib/iomgr/tcp_client_posix.c \ + src/core/lib/iomgr/tcp_client_uv.c \ + src/core/lib/iomgr/tcp_client_windows.c \ + src/core/lib/iomgr/tcp_posix.c \ + src/core/lib/iomgr/tcp_server_posix.c \ + src/core/lib/iomgr/tcp_server_uv.c \ + src/core/lib/iomgr/tcp_server_windows.c \ + src/core/lib/iomgr/tcp_uv.c \ + src/core/lib/iomgr/tcp_windows.c \ + src/core/lib/iomgr/time_averaged_stats.c \ + src/core/lib/iomgr/timer_generic.c \ + src/core/lib/iomgr/timer_heap.c \ + src/core/lib/iomgr/timer_uv.c \ + src/core/lib/iomgr/udp_server.c \ + src/core/lib/iomgr/unix_sockets_posix.c \ + src/core/lib/iomgr/unix_sockets_posix_noop.c \ + src/core/lib/iomgr/wakeup_fd_cv.c \ + src/core/lib/iomgr/wakeup_fd_eventfd.c \ + src/core/lib/iomgr/wakeup_fd_nospecial.c \ + src/core/lib/iomgr/wakeup_fd_pipe.c \ + src/core/lib/iomgr/wakeup_fd_posix.c \ + src/core/lib/iomgr/workqueue_uv.c \ + src/core/lib/iomgr/workqueue_windows.c \ + src/core/lib/json/json.c \ + src/core/lib/json/json_reader.c \ + src/core/lib/json/json_string.c \ + src/core/lib/json/json_writer.c \ + src/core/lib/slice/percent_encoding.c \ + src/core/lib/slice/slice.c \ + src/core/lib/slice/slice_buffer.c \ + src/core/lib/slice/slice_hash_table.c \ + src/core/lib/slice/slice_intern.c \ + src/core/lib/slice/slice_string_helpers.c \ + src/core/lib/surface/alarm.c \ + src/core/lib/surface/api_trace.c \ + src/core/lib/surface/byte_buffer.c \ + src/core/lib/surface/byte_buffer_reader.c \ + src/core/lib/surface/call.c \ + src/core/lib/surface/call_details.c \ + src/core/lib/surface/call_log_batch.c \ + src/core/lib/surface/channel.c \ + src/core/lib/surface/channel_init.c \ + src/core/lib/surface/channel_ping.c \ + src/core/lib/surface/channel_stack_type.c \ + src/core/lib/surface/completion_queue.c \ + src/core/lib/surface/event_string.c \ + src/core/lib/surface/lame_client.c \ + src/core/lib/surface/metadata_array.c \ + src/core/lib/surface/server.c \ + src/core/lib/surface/validate_metadata.c \ + src/core/lib/surface/version.c \ + src/core/lib/transport/byte_stream.c \ + src/core/lib/transport/connectivity_state.c \ + src/core/lib/transport/error_utils.c \ + src/core/lib/transport/metadata.c \ + src/core/lib/transport/metadata_batch.c \ + src/core/lib/transport/pid_controller.c \ + src/core/lib/transport/service_config.c \ + src/core/lib/transport/static_metadata.c \ + src/core/lib/transport/status_conversion.c \ + src/core/lib/transport/timeout_encoding.c \ + src/core/lib/transport/transport.c \ + src/core/lib/transport/transport_op_string.c \ + src/core/ext/client_channel/channel_connectivity.c \ + src/core/ext/client_channel/client_channel.c \ + src/core/ext/client_channel/client_channel_factory.c \ + src/core/ext/client_channel/client_channel_plugin.c \ + src/core/ext/client_channel/connector.c \ + src/core/ext/client_channel/default_initial_connect_string.c \ + src/core/ext/client_channel/http_connect_handshaker.c \ + src/core/ext/client_channel/http_proxy.c \ + src/core/ext/client_channel/initial_connect_string.c \ + src/core/ext/client_channel/lb_policy.c \ + src/core/ext/client_channel/lb_policy_factory.c \ + src/core/ext/client_channel/lb_policy_registry.c \ + src/core/ext/client_channel/parse_address.c \ + src/core/ext/client_channel/proxy_mapper.c \ + src/core/ext/client_channel/proxy_mapper_registry.c \ + src/core/ext/client_channel/resolver.c \ + src/core/ext/client_channel/resolver_factory.c \ + src/core/ext/client_channel/resolver_registry.c \ + src/core/ext/client_channel/subchannel.c \ + src/core/ext/client_channel/subchannel_index.c \ + src/core/ext/client_channel/uri_parser.c \ + src/core/ext/transport/chttp2/transport/bin_decoder.c \ + src/core/ext/transport/chttp2/transport/bin_encoder.c \ + src/core/ext/transport/chttp2/transport/chttp2_plugin.c \ + src/core/ext/transport/chttp2/transport/chttp2_transport.c \ + src/core/ext/transport/chttp2/transport/frame_data.c \ + src/core/ext/transport/chttp2/transport/frame_goaway.c \ + src/core/ext/transport/chttp2/transport/frame_ping.c \ + src/core/ext/transport/chttp2/transport/frame_rst_stream.c \ + src/core/ext/transport/chttp2/transport/frame_settings.c \ + src/core/ext/transport/chttp2/transport/frame_window_update.c \ + src/core/ext/transport/chttp2/transport/hpack_encoder.c \ + src/core/ext/transport/chttp2/transport/hpack_parser.c \ + src/core/ext/transport/chttp2/transport/hpack_table.c \ + src/core/ext/transport/chttp2/transport/huffsyms.c \ + src/core/ext/transport/chttp2/transport/incoming_metadata.c \ + src/core/ext/transport/chttp2/transport/parsing.c \ + src/core/ext/transport/chttp2/transport/stream_lists.c \ + src/core/ext/transport/chttp2/transport/stream_map.c \ + src/core/ext/transport/chttp2/transport/varint.c \ + src/core/ext/transport/chttp2/transport/writing.c \ + src/core/ext/transport/chttp2/alpn/alpn.c \ PUBLIC_HEADERS_C += \ + include/grpc/byte_buffer.h \ + include/grpc/byte_buffer_reader.h \ + include/grpc/compression.h \ + include/grpc/grpc.h \ + include/grpc/grpc_posix.h \ + include/grpc/grpc_security_constants.h \ + include/grpc/slice.h \ + include/grpc/slice_buffer.h \ + include/grpc/status.h \ + include/grpc/impl/codegen/byte_buffer_reader.h \ + include/grpc/impl/codegen/compression_types.h \ + include/grpc/impl/codegen/connectivity_state.h \ + include/grpc/impl/codegen/exec_ctx_fwd.h \ + include/grpc/impl/codegen/grpc_types.h \ + include/grpc/impl/codegen/propagation_bits.h \ + include/grpc/impl/codegen/status.h \ + include/grpc/impl/codegen/atm.h \ + include/grpc/impl/codegen/atm_gcc_atomic.h \ + include/grpc/impl/codegen/atm_gcc_sync.h \ + include/grpc/impl/codegen/atm_windows.h \ + include/grpc/impl/codegen/gpr_slice.h \ + include/grpc/impl/codegen/gpr_types.h \ + include/grpc/impl/codegen/port_platform.h \ + include/grpc/impl/codegen/slice.h \ + include/grpc/impl/codegen/sync.h \ + include/grpc/impl/codegen/sync_generic.h \ + include/grpc/impl/codegen/sync_posix.h \ + include/grpc/impl/codegen/sync_windows.h \ LIBGRPC_TEST_UTIL_UNSECURE_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(LIBGRPC_TEST_UTIL_UNSECURE_SRC)))) diff --git a/build.yaml b/build.yaml index 06b6eb3255..63a6e94059 100644 --- a/build.yaml +++ b/build.yaml @@ -447,6 +447,15 @@ filegroups: - include/grpc/impl/codegen/status.h uses: - gpr_codegen +- name: grpc_debug_macros + headers: + - src/core/ext/debug/debugger_macros.h + src: + - src/core/ext/debug/debugger_macros.c + uses: + - grpc_base + - grpc_client_channel + - grpc_transport_chttp2 - name: grpc_lb_policy_grpclb headers: - src/core/ext/lb_policy/grpclb/grpclb.h @@ -587,6 +596,8 @@ filegroups: deps: - grpc - gpr_test_util + uses: + - grpc_debug_macros - name: grpc_transport_chttp2 headers: - src/core/ext/transport/chttp2/transport/bin_decoder.h diff --git a/src/core/ext/client_channel/client_channel.c b/src/core/ext/client_channel/client_channel.c index 07eb68a3eb..208c95b67a 100644 --- a/src/core/ext/client_channel/client_channel.c +++ b/src/core/ext/client_channel/client_channel.c @@ -644,6 +644,12 @@ typedef struct client_channel_call_data { grpc_linked_mdelem lb_token_mdelem; } call_data; +grpc_subchannel_call *grpc_client_channel_get_subchannel_call( + grpc_call_element *call_elem) { + grpc_subchannel_call *scc = GET_CALL((call_data *)call_elem->call_data); + return scc == CANCELLED_CALL ? NULL : scc; +} + static void add_waiting_locked(call_data *calld, grpc_transport_stream_op *op) { GPR_TIMER_BEGIN("add_waiting_locked", 0); if (calld->waiting_ops_count == calld->waiting_ops_capacity) { diff --git a/src/core/ext/client_channel/client_channel.h b/src/core/ext/client_channel/client_channel.h index f02587d0c1..5e6e64e58b 100644 --- a/src/core/ext/client_channel/client_channel.h +++ b/src/core/ext/client_channel/client_channel.h @@ -57,4 +57,8 @@ void grpc_client_channel_watch_connectivity_state( grpc_exec_ctx *exec_ctx, grpc_channel_element *elem, grpc_pollset *pollset, grpc_connectivity_state *state, grpc_closure *on_complete); +/* Debug helper: pull the subchannel call from a call stack element */ +grpc_subchannel_call *grpc_client_channel_get_subchannel_call( + grpc_call_element *elem); + #endif /* GRPC_CORE_EXT_CLIENT_CHANNEL_CLIENT_CHANNEL_H */ diff --git a/src/core/ext/debug/debugger_macros.c b/src/core/ext/debug/debugger_macros.c new file mode 100644 index 0000000000..de6a2f38a7 --- /dev/null +++ b/src/core/ext/debug/debugger_macros.c @@ -0,0 +1,71 @@ +/* + * + * 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. + * + */ + +/* + * A collection of 'macros' that help navigating the grpc object hierarchy + * Not intended to be robust for main-line code, often cuts across abstraction + * boundaries. + */ + +#include + +#include "src/core/ext/client_channel/client_channel.h" +#include "src/core/ext/transport/chttp2/transport/internal.h" +#include "src/core/lib/channel/connected_channel.h" +#include "src/core/lib/surface/call.h" + +void grpc_summon_debugger_macros() {} + +grpc_stream *grpc_transport_stream_from_call(grpc_call *call) { + grpc_call_stack *cs = grpc_call_get_call_stack(call); + for (;;) { + grpc_call_element *el = grpc_call_stack_element(cs, cs->count - 1); + if (el->filter == &grpc_client_channel_filter) { + grpc_subchannel_call *scc = grpc_client_channel_get_subchannel_call(el); + if (scc == NULL) { + fprintf(stderr, "No subchannel-call"); + return NULL; + } + cs = grpc_subchannel_call_get_call_stack(scc); + } else if (el->filter == &grpc_connected_filter) { + return grpc_connected_channel_get_stream(el); + } else { + fprintf(stderr, "Unrecognized filter: %s", el->filter->name); + return NULL; + } + } +} + +grpc_chttp2_stream *grpc_chttp2_stream_from_call(grpc_call *call) { + return (grpc_chttp2_stream *)grpc_transport_stream_from_call(call); +} diff --git a/src/core/ext/debug/debugger_macros.h b/src/core/ext/debug/debugger_macros.h new file mode 100644 index 0000000000..4494176560 --- /dev/null +++ b/src/core/ext/debug/debugger_macros.h @@ -0,0 +1,39 @@ +/* + * + * 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. + * + */ + +#ifndef DEBUGGER_MACROS_H +#define DEBUGGER_MACROS_H + +void grpc_summon_debugger_macros(); + +#endif diff --git a/src/core/lib/channel/connected_channel.c b/src/core/lib/channel/connected_channel.c index ccc0619e1c..068c61c92a 100644 --- a/src/core/lib/channel/connected_channel.c +++ b/src/core/lib/channel/connected_channel.c @@ -140,7 +140,7 @@ static void con_get_channel_info(grpc_exec_ctx *exec_ctx, grpc_channel_element *elem, const grpc_channel_info *channel_info) {} -static const grpc_channel_filter connected_channel_filter = { +const grpc_channel_filter grpc_connected_filter = { con_start_transport_stream_op, con_start_transport_op, sizeof(call_data), @@ -158,7 +158,7 @@ static const grpc_channel_filter connected_channel_filter = { static void bind_transport(grpc_channel_stack *channel_stack, grpc_channel_element *elem, void *t) { channel_data *cd = (channel_data *)elem->channel_data; - GPR_ASSERT(elem->filter == &connected_channel_filter); + GPR_ASSERT(elem->filter == &grpc_connected_filter); GPR_ASSERT(cd->transport == NULL); cd->transport = t; @@ -178,7 +178,7 @@ bool grpc_add_connected_filter(grpc_exec_ctx *exec_ctx, grpc_transport *t = grpc_channel_stack_builder_get_transport(builder); GPR_ASSERT(t != NULL); return grpc_channel_stack_builder_append_filter( - builder, &connected_channel_filter, bind_transport, t); + builder, &grpc_connected_filter, bind_transport, t); } grpc_stream *grpc_connected_channel_get_stream(grpc_call_element *elem) { diff --git a/src/core/lib/channel/connected_channel.h b/src/core/lib/channel/connected_channel.h index 3585c0ecbc..5c7ea9ed26 100644 --- a/src/core/lib/channel/connected_channel.h +++ b/src/core/lib/channel/connected_channel.h @@ -36,8 +36,13 @@ #include "src/core/lib/channel/channel_stack_builder.h" +extern const grpc_channel_filter grpc_connected_filter; + bool grpc_add_connected_filter(grpc_exec_ctx *exec_ctx, grpc_channel_stack_builder *builder, void *arg_must_be_null); +/* Debug helper to dig the transport stream out of a call element */ +grpc_stream *grpc_connected_channel_get_stream(grpc_call_element *elem); + #endif /* GRPC_CORE_LIB_CHANNEL_CONNECTED_CHANNEL_H */ diff --git a/templates/test/core/end2end/end2end_defs.include b/templates/test/core/end2end/end2end_defs.include index b828f84f1c..4086a30360 100644 --- a/templates/test/core/end2end/end2end_defs.include +++ b/templates/test/core/end2end/end2end_defs.include @@ -42,6 +42,8 @@ #include +#include "src/core/ext/debug/debugger_macros.h" + static bool g_pre_init_called = false; % for test in tests: @@ -52,6 +54,7 @@ extern void ${test}_pre_init(void); void grpc_end2end_tests_pre_init(void) { GPR_ASSERT(!g_pre_init_called); g_pre_init_called = true; + grpc_summon_debugger_macros(); % for test in tests: ${test}_pre_init(); % endfor diff --git a/test/core/end2end/end2end_nosec_tests.c b/test/core/end2end/end2end_nosec_tests.c index b162bf2f40..6a0032c324 100644 --- a/test/core/end2end/end2end_nosec_tests.c +++ b/test/core/end2end/end2end_nosec_tests.c @@ -41,6 +41,8 @@ #include +#include "src/core/ext/debug/debugger_macros.h" + static bool g_pre_init_called = false; extern void authority_not_supported(grpc_end2end_test_config config); @@ -143,6 +145,7 @@ extern void write_buffering_at_end_pre_init(void); void grpc_end2end_tests_pre_init(void) { GPR_ASSERT(!g_pre_init_called); g_pre_init_called = true; + grpc_summon_debugger_macros(); authority_not_supported_pre_init(); bad_hostname_pre_init(); binary_metadata_pre_init(); diff --git a/test/core/end2end/end2end_tests.c b/test/core/end2end/end2end_tests.c index 9bca0c81f6..c9641d7d13 100644 --- a/test/core/end2end/end2end_tests.c +++ b/test/core/end2end/end2end_tests.c @@ -41,6 +41,8 @@ #include +#include "src/core/ext/debug/debugger_macros.h" + static bool g_pre_init_called = false; extern void authority_not_supported(grpc_end2end_test_config config); @@ -145,6 +147,7 @@ extern void write_buffering_at_end_pre_init(void); void grpc_end2end_tests_pre_init(void) { GPR_ASSERT(!g_pre_init_called); g_pre_init_called = true; + grpc_summon_debugger_macros(); authority_not_supported_pre_init(); bad_hostname_pre_init(); binary_metadata_pre_init(); diff --git a/tools/buildgen/plugins/expand_filegroups.py b/tools/buildgen/plugins/expand_filegroups.py index 477e69c869..46739f8f10 100755 --- a/tools/buildgen/plugins/expand_filegroups.py +++ b/tools/buildgen/plugins/expand_filegroups.py @@ -85,7 +85,7 @@ def mako_plugin(dictionary): skips = 0 while todo: - assert skips != len(todo), "infinite loop in filegroup uses clauses" + assert skips != len(todo), "infinite loop in filegroup uses clauses: %r" % [t['name'] for t in todo] # take the first element of the todo list cur = todo[0] todo = todo[1:] diff --git a/tools/run_tests/generated/sources_and_headers.json b/tools/run_tests/generated/sources_and_headers.json index 900f9a6fe7..d24c37e007 100644 --- a/tools/run_tests/generated/sources_and_headers.json +++ b/tools/run_tests/generated/sources_and_headers.json @@ -7449,6 +7449,26 @@ "third_party": false, "type": "filegroup" }, + { + "deps": [ + "gpr", + "grpc_base", + "grpc_client_channel", + "grpc_transport_chttp2" + ], + "headers": [ + "src/core/ext/debug/debugger_macros.h" + ], + "is_filegroup": true, + "language": "c", + "name": "grpc_debug_macros", + "src": [ + "src/core/ext/debug/debugger_macros.c", + "src/core/ext/debug/debugger_macros.h" + ], + "third_party": false, + "type": "filegroup" + }, { "deps": [ "gpr", @@ -7643,8 +7663,10 @@ }, { "deps": [ + "gpr", "gpr_test_util", - "grpc" + "grpc", + "grpc_debug_macros" ], "headers": [ "test/core/end2end/cq_verifier.h", diff --git a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj index 7d6685d4bf..5a0e09e1bb 100644 --- a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj +++ b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj @@ -192,6 +192,7 @@ + @@ -297,6 +298,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -339,6 +377,8 @@ + + @@ -573,6 +613,90 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters index 1c21ff301c..be8024c7aa 100644 --- a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters +++ b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters @@ -61,6 +61,9 @@ test\core\util + + src\core\ext\debug + src\core\lib\channel @@ -412,6 +415,132 @@ src\core\lib\transport + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\alpn + @@ -545,6 +674,9 @@ test\core\util + + src\core\ext\debug + src\core\lib\channel @@ -860,6 +992,117 @@ src\core\lib\transport + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\alpn + @@ -881,6 +1124,27 @@ {f7bfac91-5eb2-dea7-4601-6c63edbbf997} + + {5db70e06-741d-708c-bf0a-b59f8ca1f8bd} + + + {7f75a084-6bc4-e813-f85b-120148aa35da} + + + {88f64b2c-ca67-05ef-c15b-8ab420357a2a} + + + {b5f17b17-8012-87c9-dfb2-428dd29d0b94} + + + {608f56aa-d257-f25b-14aa-1776a771defd} + + + {49d381db-172f-9765-4135-d7a10c4485bf} + + + {4395ba2e-6b6d-ea05-8a1e-915b8f0f85f6} + {f4e8c61e-1ca6-0fdd-7b5e-b7f9a30c9a21} diff --git a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj index 7f3e101e75..c9e18e94b0 100644 --- a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj +++ b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj @@ -146,6 +146,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -160,6 +190,149 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -192,6 +365,326 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters index 8be9f5b796..017e96ff62 100644 --- a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters +++ b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters @@ -46,6 +46,572 @@ test\core\util + + src\core\ext\debug + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\compression + + + src\core\lib\compression + + + src\core\lib\debug + + + src\core\lib\http + + + src\core\lib\http + + + src\core\lib\http + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\json + + + src\core\lib\json + + + src\core\lib\json + + + src\core\lib\json + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\alpn + + + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + + + include\grpc\impl\codegen + @@ -87,9 +653,507 @@ test\core\util + + src\core\ext\debug + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\channel + + + src\core\lib\compression + + + src\core\lib\compression + + + src\core\lib\debug + + + src\core\lib\http + + + src\core\lib\http + + + src\core\lib\http + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\iomgr + + + src\core\lib\json + + + src\core\lib\json + + + src\core\lib\json + + + src\core\lib\json + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\slice + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\surface + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\lib\transport + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\client_channel + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\transport + + + src\core\ext\transport\chttp2\alpn + + + {9793fab6-15ae-1f61-712d-c3d673654d72} + + + {c2447106-a6bf-6b88-9ad0-a42b7ac1573c} + + + {dba70812-267b-656c-9f8c-636338d3f5c0} + + + {b9e2ddac-f042-3042-ba4b-79ba4445e68c} + + + {65483377-42fd-137e-3847-00dfd4675db3} + + + {51a516dc-93e3-4dd5-d114-2d06f5df4ad7} + + + {a927155d-bcf6-0dd8-6d63-be48bcaf617f} + + + {ecb054bb-d7ce-b4db-7f82-ae022486c076} + + + {de5ce030-9e5d-b93a-da8f-ee5825ded59a} + + + {fb32254e-a807-768a-3686-4e87f3bf1e8e} + + + {87c61e56-5090-5e1a-22af-02e3c8bf4a2a} + + + {e50ce1d1-6b17-dad2-9ef3-46f68d4bee1b} + + + {67007111-23fe-296f-1808-91f2b96a31aa} + + + {e3d002a7-9318-1ac5-4259-e177f58ccc9a} + + + {ac14fd16-a4af-6b22-4226-2d7dabf25409} + + + {24268e45-f6c3-6024-b49a-d01bb9c12d96} + + + {0be401bd-3e26-dead-fdf4-2ce27a1ac3a3} + + + {ac2f12e3-ac77-f0a7-d15d-92899e61ed25} + + + {9015222c-df04-298f-3f2c-d19babffc180} + + + {c3ff117a-aae9-dedd-2f5a-888f0383cbb8} + + + {588ffbfc-2f94-a99f-85b0-4c47ec9f8d13} + + + {732318c6-bb34-9a99-611b-9928db3d4e2a} + + + {2c0ca4a1-38df-329d-eeba-5c5b61dc81a5} + {037c7645-1698-cf2d-4163-525240323101} -- cgit v1.2.3 From 61eb40ce56cd72b89afbfac2af400b64d627522d Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 3 Feb 2017 13:46:33 -0800 Subject: Put files in a better place --- CMakeLists.txt | 241 +---- Makefile | 233 +---- build.yaml | 13 +- src/core/ext/debug/debugger_macros.c | 71 -- src/core/ext/debug/debugger_macros.h | 39 - templates/test/core/end2end/end2end_defs.include | 2 +- test/core/end2end/end2end_nosec_tests.c | 2 +- test/core/end2end/end2end_tests.c | 2 +- test/core/util/debugger_macros.c | 71 ++ test/core/util/debugger_macros.h | 39 + tools/run_tests/generated/sources_and_headers.json | 27 +- .../vcxproj/grpc_test_util/grpc_test_util.vcxproj | 127 +-- .../grpc_test_util/grpc_test_util.vcxproj.filters | 270 +---- .../grpc_test_util_unsecure.vcxproj | 496 +-------- .../grpc_test_util_unsecure.vcxproj.filters | 1070 +------------------- 15 files changed, 141 insertions(+), 2562 deletions(-) delete mode 100644 src/core/ext/debug/debugger_macros.c delete mode 100644 src/core/ext/debug/debugger_macros.h create mode 100644 test/core/util/debugger_macros.c create mode 100644 test/core/util/debugger_macros.h (limited to 'test/core/end2end') diff --git a/CMakeLists.txt b/CMakeLists.txt index 3ae2197b16..3b320db1b3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1360,6 +1360,7 @@ add_library(grpc_test_util test/core/end2end/fixtures/http_proxy.c test/core/end2end/fixtures/proxy.c test/core/iomgr/endpoint_tests.c + test/core/util/debugger_macros.c test/core/util/grpc_profiler.c test/core/util/memory_counters.c test/core/util/mock_endpoint.c @@ -1370,7 +1371,6 @@ add_library(grpc_test_util test/core/util/port_uv.c test/core/util/port_windows.c test/core/util/slice_splitter.c - src/core/ext/debug/debugger_macros.c src/core/lib/channel/channel_args.c src/core/lib/channel/channel_stack.c src/core/lib/channel/channel_stack_builder.c @@ -1488,48 +1488,6 @@ add_library(grpc_test_util src/core/lib/transport/timeout_encoding.c src/core/lib/transport/transport.c src/core/lib/transport/transport_op_string.c - src/core/ext/client_channel/channel_connectivity.c - src/core/ext/client_channel/client_channel.c - src/core/ext/client_channel/client_channel_factory.c - src/core/ext/client_channel/client_channel_plugin.c - src/core/ext/client_channel/connector.c - src/core/ext/client_channel/default_initial_connect_string.c - src/core/ext/client_channel/http_connect_handshaker.c - src/core/ext/client_channel/http_proxy.c - src/core/ext/client_channel/initial_connect_string.c - src/core/ext/client_channel/lb_policy.c - src/core/ext/client_channel/lb_policy_factory.c - src/core/ext/client_channel/lb_policy_registry.c - src/core/ext/client_channel/parse_address.c - src/core/ext/client_channel/proxy_mapper.c - src/core/ext/client_channel/proxy_mapper_registry.c - src/core/ext/client_channel/resolver.c - src/core/ext/client_channel/resolver_factory.c - src/core/ext/client_channel/resolver_registry.c - src/core/ext/client_channel/subchannel.c - src/core/ext/client_channel/subchannel_index.c - src/core/ext/client_channel/uri_parser.c - src/core/ext/transport/chttp2/transport/bin_decoder.c - src/core/ext/transport/chttp2/transport/bin_encoder.c - src/core/ext/transport/chttp2/transport/chttp2_plugin.c - src/core/ext/transport/chttp2/transport/chttp2_transport.c - src/core/ext/transport/chttp2/transport/frame_data.c - src/core/ext/transport/chttp2/transport/frame_goaway.c - src/core/ext/transport/chttp2/transport/frame_ping.c - src/core/ext/transport/chttp2/transport/frame_rst_stream.c - src/core/ext/transport/chttp2/transport/frame_settings.c - src/core/ext/transport/chttp2/transport/frame_window_update.c - src/core/ext/transport/chttp2/transport/hpack_encoder.c - src/core/ext/transport/chttp2/transport/hpack_parser.c - src/core/ext/transport/chttp2/transport/hpack_table.c - src/core/ext/transport/chttp2/transport/huffsyms.c - src/core/ext/transport/chttp2/transport/incoming_metadata.c - src/core/ext/transport/chttp2/transport/parsing.c - src/core/ext/transport/chttp2/transport/stream_lists.c - src/core/ext/transport/chttp2/transport/stream_map.c - src/core/ext/transport/chttp2/transport/varint.c - src/core/ext/transport/chttp2/transport/writing.c - src/core/ext/transport/chttp2/alpn/alpn.c ) @@ -1597,6 +1555,7 @@ add_library(grpc_test_util_unsecure test/core/end2end/fixtures/http_proxy.c test/core/end2end/fixtures/proxy.c test/core/iomgr/endpoint_tests.c + test/core/util/debugger_macros.c test/core/util/grpc_profiler.c test/core/util/memory_counters.c test/core/util/mock_endpoint.c @@ -1607,166 +1566,6 @@ add_library(grpc_test_util_unsecure test/core/util/port_uv.c test/core/util/port_windows.c test/core/util/slice_splitter.c - src/core/ext/debug/debugger_macros.c - src/core/lib/channel/channel_args.c - src/core/lib/channel/channel_stack.c - src/core/lib/channel/channel_stack_builder.c - src/core/lib/channel/compress_filter.c - src/core/lib/channel/connected_channel.c - src/core/lib/channel/deadline_filter.c - src/core/lib/channel/handshaker.c - src/core/lib/channel/handshaker_factory.c - src/core/lib/channel/handshaker_registry.c - src/core/lib/channel/http_client_filter.c - src/core/lib/channel/http_server_filter.c - src/core/lib/channel/message_size_filter.c - src/core/lib/compression/compression.c - src/core/lib/compression/message_compress.c - src/core/lib/debug/trace.c - src/core/lib/http/format_request.c - src/core/lib/http/httpcli.c - src/core/lib/http/parser.c - src/core/lib/iomgr/closure.c - src/core/lib/iomgr/combiner.c - src/core/lib/iomgr/endpoint.c - src/core/lib/iomgr/endpoint_pair_posix.c - src/core/lib/iomgr/endpoint_pair_uv.c - src/core/lib/iomgr/endpoint_pair_windows.c - src/core/lib/iomgr/error.c - src/core/lib/iomgr/ev_epoll_linux.c - src/core/lib/iomgr/ev_poll_posix.c - src/core/lib/iomgr/ev_posix.c - src/core/lib/iomgr/exec_ctx.c - src/core/lib/iomgr/executor.c - src/core/lib/iomgr/iocp_windows.c - src/core/lib/iomgr/iomgr.c - src/core/lib/iomgr/iomgr_posix.c - src/core/lib/iomgr/iomgr_uv.c - src/core/lib/iomgr/iomgr_windows.c - src/core/lib/iomgr/load_file.c - src/core/lib/iomgr/network_status_tracker.c - src/core/lib/iomgr/polling_entity.c - src/core/lib/iomgr/pollset_set_uv.c - src/core/lib/iomgr/pollset_set_windows.c - src/core/lib/iomgr/pollset_uv.c - src/core/lib/iomgr/pollset_windows.c - src/core/lib/iomgr/resolve_address_posix.c - src/core/lib/iomgr/resolve_address_uv.c - src/core/lib/iomgr/resolve_address_windows.c - src/core/lib/iomgr/resource_quota.c - src/core/lib/iomgr/sockaddr_utils.c - src/core/lib/iomgr/socket_mutator.c - src/core/lib/iomgr/socket_utils_common_posix.c - src/core/lib/iomgr/socket_utils_linux.c - src/core/lib/iomgr/socket_utils_posix.c - src/core/lib/iomgr/socket_utils_uv.c - src/core/lib/iomgr/socket_utils_windows.c - src/core/lib/iomgr/socket_windows.c - src/core/lib/iomgr/tcp_client_posix.c - src/core/lib/iomgr/tcp_client_uv.c - src/core/lib/iomgr/tcp_client_windows.c - src/core/lib/iomgr/tcp_posix.c - src/core/lib/iomgr/tcp_server_posix.c - src/core/lib/iomgr/tcp_server_uv.c - src/core/lib/iomgr/tcp_server_windows.c - src/core/lib/iomgr/tcp_uv.c - src/core/lib/iomgr/tcp_windows.c - src/core/lib/iomgr/time_averaged_stats.c - src/core/lib/iomgr/timer_generic.c - src/core/lib/iomgr/timer_heap.c - src/core/lib/iomgr/timer_uv.c - src/core/lib/iomgr/udp_server.c - src/core/lib/iomgr/unix_sockets_posix.c - src/core/lib/iomgr/unix_sockets_posix_noop.c - src/core/lib/iomgr/wakeup_fd_cv.c - src/core/lib/iomgr/wakeup_fd_eventfd.c - src/core/lib/iomgr/wakeup_fd_nospecial.c - src/core/lib/iomgr/wakeup_fd_pipe.c - src/core/lib/iomgr/wakeup_fd_posix.c - src/core/lib/iomgr/workqueue_uv.c - src/core/lib/iomgr/workqueue_windows.c - src/core/lib/json/json.c - src/core/lib/json/json_reader.c - src/core/lib/json/json_string.c - src/core/lib/json/json_writer.c - src/core/lib/slice/percent_encoding.c - src/core/lib/slice/slice.c - src/core/lib/slice/slice_buffer.c - src/core/lib/slice/slice_hash_table.c - src/core/lib/slice/slice_intern.c - src/core/lib/slice/slice_string_helpers.c - src/core/lib/surface/alarm.c - src/core/lib/surface/api_trace.c - src/core/lib/surface/byte_buffer.c - src/core/lib/surface/byte_buffer_reader.c - src/core/lib/surface/call.c - src/core/lib/surface/call_details.c - src/core/lib/surface/call_log_batch.c - src/core/lib/surface/channel.c - src/core/lib/surface/channel_init.c - src/core/lib/surface/channel_ping.c - src/core/lib/surface/channel_stack_type.c - src/core/lib/surface/completion_queue.c - src/core/lib/surface/event_string.c - src/core/lib/surface/lame_client.c - src/core/lib/surface/metadata_array.c - src/core/lib/surface/server.c - src/core/lib/surface/validate_metadata.c - src/core/lib/surface/version.c - src/core/lib/transport/byte_stream.c - src/core/lib/transport/connectivity_state.c - src/core/lib/transport/error_utils.c - src/core/lib/transport/metadata.c - src/core/lib/transport/metadata_batch.c - src/core/lib/transport/pid_controller.c - src/core/lib/transport/service_config.c - src/core/lib/transport/static_metadata.c - src/core/lib/transport/status_conversion.c - src/core/lib/transport/timeout_encoding.c - src/core/lib/transport/transport.c - src/core/lib/transport/transport_op_string.c - src/core/ext/client_channel/channel_connectivity.c - src/core/ext/client_channel/client_channel.c - src/core/ext/client_channel/client_channel_factory.c - src/core/ext/client_channel/client_channel_plugin.c - src/core/ext/client_channel/connector.c - src/core/ext/client_channel/default_initial_connect_string.c - src/core/ext/client_channel/http_connect_handshaker.c - src/core/ext/client_channel/http_proxy.c - src/core/ext/client_channel/initial_connect_string.c - src/core/ext/client_channel/lb_policy.c - src/core/ext/client_channel/lb_policy_factory.c - src/core/ext/client_channel/lb_policy_registry.c - src/core/ext/client_channel/parse_address.c - src/core/ext/client_channel/proxy_mapper.c - src/core/ext/client_channel/proxy_mapper_registry.c - src/core/ext/client_channel/resolver.c - src/core/ext/client_channel/resolver_factory.c - src/core/ext/client_channel/resolver_registry.c - src/core/ext/client_channel/subchannel.c - src/core/ext/client_channel/subchannel_index.c - src/core/ext/client_channel/uri_parser.c - src/core/ext/transport/chttp2/transport/bin_decoder.c - src/core/ext/transport/chttp2/transport/bin_encoder.c - src/core/ext/transport/chttp2/transport/chttp2_plugin.c - src/core/ext/transport/chttp2/transport/chttp2_transport.c - src/core/ext/transport/chttp2/transport/frame_data.c - src/core/ext/transport/chttp2/transport/frame_goaway.c - src/core/ext/transport/chttp2/transport/frame_ping.c - src/core/ext/transport/chttp2/transport/frame_rst_stream.c - src/core/ext/transport/chttp2/transport/frame_settings.c - src/core/ext/transport/chttp2/transport/frame_window_update.c - src/core/ext/transport/chttp2/transport/hpack_encoder.c - src/core/ext/transport/chttp2/transport/hpack_parser.c - src/core/ext/transport/chttp2/transport/hpack_table.c - src/core/ext/transport/chttp2/transport/huffsyms.c - src/core/ext/transport/chttp2/transport/incoming_metadata.c - src/core/ext/transport/chttp2/transport/parsing.c - src/core/ext/transport/chttp2/transport/stream_lists.c - src/core/ext/transport/chttp2/transport/stream_map.c - src/core/ext/transport/chttp2/transport/varint.c - src/core/ext/transport/chttp2/transport/writing.c - src/core/ext/transport/chttp2/alpn/alpn.c ) @@ -1789,42 +1588,6 @@ target_link_libraries(grpc_test_util_unsecure grpc ) -foreach(_hdr - include/grpc/byte_buffer.h - include/grpc/byte_buffer_reader.h - include/grpc/compression.h - include/grpc/grpc.h - include/grpc/grpc_posix.h - include/grpc/grpc_security_constants.h - include/grpc/slice.h - include/grpc/slice_buffer.h - include/grpc/status.h - include/grpc/impl/codegen/byte_buffer_reader.h - include/grpc/impl/codegen/compression_types.h - include/grpc/impl/codegen/connectivity_state.h - include/grpc/impl/codegen/exec_ctx_fwd.h - include/grpc/impl/codegen/grpc_types.h - include/grpc/impl/codegen/propagation_bits.h - include/grpc/impl/codegen/status.h - include/grpc/impl/codegen/atm.h - include/grpc/impl/codegen/atm_gcc_atomic.h - include/grpc/impl/codegen/atm_gcc_sync.h - include/grpc/impl/codegen/atm_windows.h - include/grpc/impl/codegen/gpr_slice.h - include/grpc/impl/codegen/gpr_types.h - include/grpc/impl/codegen/port_platform.h - include/grpc/impl/codegen/slice.h - include/grpc/impl/codegen/sync.h - include/grpc/impl/codegen/sync_generic.h - include/grpc/impl/codegen/sync_posix.h - include/grpc/impl/codegen/sync_windows.h -) - string(REPLACE "include/" "" _path ${_hdr}) - get_filename_component(_path ${_path} PATH) - install(FILES ${_hdr} - DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/${_path}" - ) -endforeach() endif (gRPC_BUILD_TESTS) diff --git a/Makefile b/Makefile index c575624a74..0d1d64cdcd 100644 --- a/Makefile +++ b/Makefile @@ -3220,6 +3220,7 @@ LIBGRPC_TEST_UTIL_SRC = \ test/core/end2end/fixtures/http_proxy.c \ test/core/end2end/fixtures/proxy.c \ test/core/iomgr/endpoint_tests.c \ + test/core/util/debugger_macros.c \ test/core/util/grpc_profiler.c \ test/core/util/memory_counters.c \ test/core/util/mock_endpoint.c \ @@ -3230,7 +3231,6 @@ LIBGRPC_TEST_UTIL_SRC = \ test/core/util/port_uv.c \ test/core/util/port_windows.c \ test/core/util/slice_splitter.c \ - src/core/ext/debug/debugger_macros.c \ src/core/lib/channel/channel_args.c \ src/core/lib/channel/channel_stack.c \ src/core/lib/channel/channel_stack_builder.c \ @@ -3348,48 +3348,6 @@ LIBGRPC_TEST_UTIL_SRC = \ src/core/lib/transport/timeout_encoding.c \ src/core/lib/transport/transport.c \ src/core/lib/transport/transport_op_string.c \ - src/core/ext/client_channel/channel_connectivity.c \ - src/core/ext/client_channel/client_channel.c \ - src/core/ext/client_channel/client_channel_factory.c \ - src/core/ext/client_channel/client_channel_plugin.c \ - src/core/ext/client_channel/connector.c \ - src/core/ext/client_channel/default_initial_connect_string.c \ - src/core/ext/client_channel/http_connect_handshaker.c \ - src/core/ext/client_channel/http_proxy.c \ - src/core/ext/client_channel/initial_connect_string.c \ - src/core/ext/client_channel/lb_policy.c \ - src/core/ext/client_channel/lb_policy_factory.c \ - src/core/ext/client_channel/lb_policy_registry.c \ - src/core/ext/client_channel/parse_address.c \ - src/core/ext/client_channel/proxy_mapper.c \ - src/core/ext/client_channel/proxy_mapper_registry.c \ - src/core/ext/client_channel/resolver.c \ - src/core/ext/client_channel/resolver_factory.c \ - src/core/ext/client_channel/resolver_registry.c \ - src/core/ext/client_channel/subchannel.c \ - src/core/ext/client_channel/subchannel_index.c \ - src/core/ext/client_channel/uri_parser.c \ - src/core/ext/transport/chttp2/transport/bin_decoder.c \ - src/core/ext/transport/chttp2/transport/bin_encoder.c \ - src/core/ext/transport/chttp2/transport/chttp2_plugin.c \ - src/core/ext/transport/chttp2/transport/chttp2_transport.c \ - src/core/ext/transport/chttp2/transport/frame_data.c \ - src/core/ext/transport/chttp2/transport/frame_goaway.c \ - src/core/ext/transport/chttp2/transport/frame_ping.c \ - src/core/ext/transport/chttp2/transport/frame_rst_stream.c \ - src/core/ext/transport/chttp2/transport/frame_settings.c \ - src/core/ext/transport/chttp2/transport/frame_window_update.c \ - src/core/ext/transport/chttp2/transport/hpack_encoder.c \ - src/core/ext/transport/chttp2/transport/hpack_parser.c \ - src/core/ext/transport/chttp2/transport/hpack_table.c \ - src/core/ext/transport/chttp2/transport/huffsyms.c \ - src/core/ext/transport/chttp2/transport/incoming_metadata.c \ - src/core/ext/transport/chttp2/transport/parsing.c \ - src/core/ext/transport/chttp2/transport/stream_lists.c \ - src/core/ext/transport/chttp2/transport/stream_map.c \ - src/core/ext/transport/chttp2/transport/varint.c \ - src/core/ext/transport/chttp2/transport/writing.c \ - src/core/ext/transport/chttp2/alpn/alpn.c \ PUBLIC_HEADERS_C += \ include/grpc/byte_buffer.h \ @@ -3461,6 +3419,7 @@ LIBGRPC_TEST_UTIL_UNSECURE_SRC = \ test/core/end2end/fixtures/http_proxy.c \ test/core/end2end/fixtures/proxy.c \ test/core/iomgr/endpoint_tests.c \ + test/core/util/debugger_macros.c \ test/core/util/grpc_profiler.c \ test/core/util/memory_counters.c \ test/core/util/mock_endpoint.c \ @@ -3471,196 +3430,8 @@ LIBGRPC_TEST_UTIL_UNSECURE_SRC = \ test/core/util/port_uv.c \ test/core/util/port_windows.c \ test/core/util/slice_splitter.c \ - src/core/ext/debug/debugger_macros.c \ - src/core/lib/channel/channel_args.c \ - src/core/lib/channel/channel_stack.c \ - src/core/lib/channel/channel_stack_builder.c \ - src/core/lib/channel/compress_filter.c \ - src/core/lib/channel/connected_channel.c \ - src/core/lib/channel/deadline_filter.c \ - src/core/lib/channel/handshaker.c \ - src/core/lib/channel/handshaker_factory.c \ - src/core/lib/channel/handshaker_registry.c \ - src/core/lib/channel/http_client_filter.c \ - src/core/lib/channel/http_server_filter.c \ - src/core/lib/channel/message_size_filter.c \ - src/core/lib/compression/compression.c \ - src/core/lib/compression/message_compress.c \ - src/core/lib/debug/trace.c \ - src/core/lib/http/format_request.c \ - src/core/lib/http/httpcli.c \ - src/core/lib/http/parser.c \ - src/core/lib/iomgr/closure.c \ - src/core/lib/iomgr/combiner.c \ - src/core/lib/iomgr/endpoint.c \ - src/core/lib/iomgr/endpoint_pair_posix.c \ - src/core/lib/iomgr/endpoint_pair_uv.c \ - src/core/lib/iomgr/endpoint_pair_windows.c \ - src/core/lib/iomgr/error.c \ - src/core/lib/iomgr/ev_epoll_linux.c \ - src/core/lib/iomgr/ev_poll_posix.c \ - src/core/lib/iomgr/ev_posix.c \ - src/core/lib/iomgr/exec_ctx.c \ - src/core/lib/iomgr/executor.c \ - src/core/lib/iomgr/iocp_windows.c \ - src/core/lib/iomgr/iomgr.c \ - src/core/lib/iomgr/iomgr_posix.c \ - src/core/lib/iomgr/iomgr_uv.c \ - src/core/lib/iomgr/iomgr_windows.c \ - src/core/lib/iomgr/load_file.c \ - src/core/lib/iomgr/network_status_tracker.c \ - src/core/lib/iomgr/polling_entity.c \ - src/core/lib/iomgr/pollset_set_uv.c \ - src/core/lib/iomgr/pollset_set_windows.c \ - src/core/lib/iomgr/pollset_uv.c \ - src/core/lib/iomgr/pollset_windows.c \ - src/core/lib/iomgr/resolve_address_posix.c \ - src/core/lib/iomgr/resolve_address_uv.c \ - src/core/lib/iomgr/resolve_address_windows.c \ - src/core/lib/iomgr/resource_quota.c \ - src/core/lib/iomgr/sockaddr_utils.c \ - src/core/lib/iomgr/socket_mutator.c \ - src/core/lib/iomgr/socket_utils_common_posix.c \ - src/core/lib/iomgr/socket_utils_linux.c \ - src/core/lib/iomgr/socket_utils_posix.c \ - src/core/lib/iomgr/socket_utils_uv.c \ - src/core/lib/iomgr/socket_utils_windows.c \ - src/core/lib/iomgr/socket_windows.c \ - src/core/lib/iomgr/tcp_client_posix.c \ - src/core/lib/iomgr/tcp_client_uv.c \ - src/core/lib/iomgr/tcp_client_windows.c \ - src/core/lib/iomgr/tcp_posix.c \ - src/core/lib/iomgr/tcp_server_posix.c \ - src/core/lib/iomgr/tcp_server_uv.c \ - src/core/lib/iomgr/tcp_server_windows.c \ - src/core/lib/iomgr/tcp_uv.c \ - src/core/lib/iomgr/tcp_windows.c \ - src/core/lib/iomgr/time_averaged_stats.c \ - src/core/lib/iomgr/timer_generic.c \ - src/core/lib/iomgr/timer_heap.c \ - src/core/lib/iomgr/timer_uv.c \ - src/core/lib/iomgr/udp_server.c \ - src/core/lib/iomgr/unix_sockets_posix.c \ - src/core/lib/iomgr/unix_sockets_posix_noop.c \ - src/core/lib/iomgr/wakeup_fd_cv.c \ - src/core/lib/iomgr/wakeup_fd_eventfd.c \ - src/core/lib/iomgr/wakeup_fd_nospecial.c \ - src/core/lib/iomgr/wakeup_fd_pipe.c \ - src/core/lib/iomgr/wakeup_fd_posix.c \ - src/core/lib/iomgr/workqueue_uv.c \ - src/core/lib/iomgr/workqueue_windows.c \ - src/core/lib/json/json.c \ - src/core/lib/json/json_reader.c \ - src/core/lib/json/json_string.c \ - src/core/lib/json/json_writer.c \ - src/core/lib/slice/percent_encoding.c \ - src/core/lib/slice/slice.c \ - src/core/lib/slice/slice_buffer.c \ - src/core/lib/slice/slice_hash_table.c \ - src/core/lib/slice/slice_intern.c \ - src/core/lib/slice/slice_string_helpers.c \ - src/core/lib/surface/alarm.c \ - src/core/lib/surface/api_trace.c \ - src/core/lib/surface/byte_buffer.c \ - src/core/lib/surface/byte_buffer_reader.c \ - src/core/lib/surface/call.c \ - src/core/lib/surface/call_details.c \ - src/core/lib/surface/call_log_batch.c \ - src/core/lib/surface/channel.c \ - src/core/lib/surface/channel_init.c \ - src/core/lib/surface/channel_ping.c \ - src/core/lib/surface/channel_stack_type.c \ - src/core/lib/surface/completion_queue.c \ - src/core/lib/surface/event_string.c \ - src/core/lib/surface/lame_client.c \ - src/core/lib/surface/metadata_array.c \ - src/core/lib/surface/server.c \ - src/core/lib/surface/validate_metadata.c \ - src/core/lib/surface/version.c \ - src/core/lib/transport/byte_stream.c \ - src/core/lib/transport/connectivity_state.c \ - src/core/lib/transport/error_utils.c \ - src/core/lib/transport/metadata.c \ - src/core/lib/transport/metadata_batch.c \ - src/core/lib/transport/pid_controller.c \ - src/core/lib/transport/service_config.c \ - src/core/lib/transport/static_metadata.c \ - src/core/lib/transport/status_conversion.c \ - src/core/lib/transport/timeout_encoding.c \ - src/core/lib/transport/transport.c \ - src/core/lib/transport/transport_op_string.c \ - src/core/ext/client_channel/channel_connectivity.c \ - src/core/ext/client_channel/client_channel.c \ - src/core/ext/client_channel/client_channel_factory.c \ - src/core/ext/client_channel/client_channel_plugin.c \ - src/core/ext/client_channel/connector.c \ - src/core/ext/client_channel/default_initial_connect_string.c \ - src/core/ext/client_channel/http_connect_handshaker.c \ - src/core/ext/client_channel/http_proxy.c \ - src/core/ext/client_channel/initial_connect_string.c \ - src/core/ext/client_channel/lb_policy.c \ - src/core/ext/client_channel/lb_policy_factory.c \ - src/core/ext/client_channel/lb_policy_registry.c \ - src/core/ext/client_channel/parse_address.c \ - src/core/ext/client_channel/proxy_mapper.c \ - src/core/ext/client_channel/proxy_mapper_registry.c \ - src/core/ext/client_channel/resolver.c \ - src/core/ext/client_channel/resolver_factory.c \ - src/core/ext/client_channel/resolver_registry.c \ - src/core/ext/client_channel/subchannel.c \ - src/core/ext/client_channel/subchannel_index.c \ - src/core/ext/client_channel/uri_parser.c \ - src/core/ext/transport/chttp2/transport/bin_decoder.c \ - src/core/ext/transport/chttp2/transport/bin_encoder.c \ - src/core/ext/transport/chttp2/transport/chttp2_plugin.c \ - src/core/ext/transport/chttp2/transport/chttp2_transport.c \ - src/core/ext/transport/chttp2/transport/frame_data.c \ - src/core/ext/transport/chttp2/transport/frame_goaway.c \ - src/core/ext/transport/chttp2/transport/frame_ping.c \ - src/core/ext/transport/chttp2/transport/frame_rst_stream.c \ - src/core/ext/transport/chttp2/transport/frame_settings.c \ - src/core/ext/transport/chttp2/transport/frame_window_update.c \ - src/core/ext/transport/chttp2/transport/hpack_encoder.c \ - src/core/ext/transport/chttp2/transport/hpack_parser.c \ - src/core/ext/transport/chttp2/transport/hpack_table.c \ - src/core/ext/transport/chttp2/transport/huffsyms.c \ - src/core/ext/transport/chttp2/transport/incoming_metadata.c \ - src/core/ext/transport/chttp2/transport/parsing.c \ - src/core/ext/transport/chttp2/transport/stream_lists.c \ - src/core/ext/transport/chttp2/transport/stream_map.c \ - src/core/ext/transport/chttp2/transport/varint.c \ - src/core/ext/transport/chttp2/transport/writing.c \ - src/core/ext/transport/chttp2/alpn/alpn.c \ PUBLIC_HEADERS_C += \ - include/grpc/byte_buffer.h \ - include/grpc/byte_buffer_reader.h \ - include/grpc/compression.h \ - include/grpc/grpc.h \ - include/grpc/grpc_posix.h \ - include/grpc/grpc_security_constants.h \ - include/grpc/slice.h \ - include/grpc/slice_buffer.h \ - include/grpc/status.h \ - include/grpc/impl/codegen/byte_buffer_reader.h \ - include/grpc/impl/codegen/compression_types.h \ - include/grpc/impl/codegen/connectivity_state.h \ - include/grpc/impl/codegen/exec_ctx_fwd.h \ - include/grpc/impl/codegen/grpc_types.h \ - include/grpc/impl/codegen/propagation_bits.h \ - include/grpc/impl/codegen/status.h \ - include/grpc/impl/codegen/atm.h \ - include/grpc/impl/codegen/atm_gcc_atomic.h \ - include/grpc/impl/codegen/atm_gcc_sync.h \ - include/grpc/impl/codegen/atm_windows.h \ - include/grpc/impl/codegen/gpr_slice.h \ - include/grpc/impl/codegen/gpr_types.h \ - include/grpc/impl/codegen/port_platform.h \ - include/grpc/impl/codegen/slice.h \ - include/grpc/impl/codegen/sync.h \ - include/grpc/impl/codegen/sync_generic.h \ - include/grpc/impl/codegen/sync_posix.h \ - include/grpc/impl/codegen/sync_windows.h \ LIBGRPC_TEST_UTIL_UNSECURE_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(LIBGRPC_TEST_UTIL_UNSECURE_SRC)))) diff --git a/build.yaml b/build.yaml index 63a6e94059..3cec9c5bd2 100644 --- a/build.yaml +++ b/build.yaml @@ -447,15 +447,6 @@ filegroups: - include/grpc/impl/codegen/status.h uses: - gpr_codegen -- name: grpc_debug_macros - headers: - - src/core/ext/debug/debugger_macros.h - src: - - src/core/ext/debug/debugger_macros.c - uses: - - grpc_base - - grpc_client_channel - - grpc_transport_chttp2 - name: grpc_lb_policy_grpclb headers: - src/core/ext/lb_policy/grpclb/grpclb.h @@ -569,6 +560,7 @@ filegroups: - test/core/end2end/fixtures/http_proxy.h - test/core/end2end/fixtures/proxy.h - test/core/iomgr/endpoint_tests.h + - test/core/util/debugger_macros.h - test/core/util/grpc_profiler.h - test/core/util/memory_counters.h - test/core/util/mock_endpoint.h @@ -583,6 +575,7 @@ filegroups: - test/core/end2end/fixtures/http_proxy.c - test/core/end2end/fixtures/proxy.c - test/core/iomgr/endpoint_tests.c + - test/core/util/debugger_macros.c - test/core/util/grpc_profiler.c - test/core/util/memory_counters.c - test/core/util/mock_endpoint.c @@ -596,8 +589,6 @@ filegroups: deps: - grpc - gpr_test_util - uses: - - grpc_debug_macros - name: grpc_transport_chttp2 headers: - src/core/ext/transport/chttp2/transport/bin_decoder.h diff --git a/src/core/ext/debug/debugger_macros.c b/src/core/ext/debug/debugger_macros.c deleted file mode 100644 index de6a2f38a7..0000000000 --- a/src/core/ext/debug/debugger_macros.c +++ /dev/null @@ -1,71 +0,0 @@ -/* - * - * 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. - * - */ - -/* - * A collection of 'macros' that help navigating the grpc object hierarchy - * Not intended to be robust for main-line code, often cuts across abstraction - * boundaries. - */ - -#include - -#include "src/core/ext/client_channel/client_channel.h" -#include "src/core/ext/transport/chttp2/transport/internal.h" -#include "src/core/lib/channel/connected_channel.h" -#include "src/core/lib/surface/call.h" - -void grpc_summon_debugger_macros() {} - -grpc_stream *grpc_transport_stream_from_call(grpc_call *call) { - grpc_call_stack *cs = grpc_call_get_call_stack(call); - for (;;) { - grpc_call_element *el = grpc_call_stack_element(cs, cs->count - 1); - if (el->filter == &grpc_client_channel_filter) { - grpc_subchannel_call *scc = grpc_client_channel_get_subchannel_call(el); - if (scc == NULL) { - fprintf(stderr, "No subchannel-call"); - return NULL; - } - cs = grpc_subchannel_call_get_call_stack(scc); - } else if (el->filter == &grpc_connected_filter) { - return grpc_connected_channel_get_stream(el); - } else { - fprintf(stderr, "Unrecognized filter: %s", el->filter->name); - return NULL; - } - } -} - -grpc_chttp2_stream *grpc_chttp2_stream_from_call(grpc_call *call) { - return (grpc_chttp2_stream *)grpc_transport_stream_from_call(call); -} diff --git a/src/core/ext/debug/debugger_macros.h b/src/core/ext/debug/debugger_macros.h deleted file mode 100644 index 4494176560..0000000000 --- a/src/core/ext/debug/debugger_macros.h +++ /dev/null @@ -1,39 +0,0 @@ -/* - * - * 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. - * - */ - -#ifndef DEBUGGER_MACROS_H -#define DEBUGGER_MACROS_H - -void grpc_summon_debugger_macros(); - -#endif diff --git a/templates/test/core/end2end/end2end_defs.include b/templates/test/core/end2end/end2end_defs.include index 4086a30360..68b9e69c2f 100644 --- a/templates/test/core/end2end/end2end_defs.include +++ b/templates/test/core/end2end/end2end_defs.include @@ -42,7 +42,7 @@ #include -#include "src/core/ext/debug/debugger_macros.h" +#include "test/core/util/debugger_macros.h" static bool g_pre_init_called = false; diff --git a/test/core/end2end/end2end_nosec_tests.c b/test/core/end2end/end2end_nosec_tests.c index 6a0032c324..fdfa31b5fb 100644 --- a/test/core/end2end/end2end_nosec_tests.c +++ b/test/core/end2end/end2end_nosec_tests.c @@ -41,7 +41,7 @@ #include -#include "src/core/ext/debug/debugger_macros.h" +#include "test/core/util/debugger_macros.h" static bool g_pre_init_called = false; diff --git a/test/core/end2end/end2end_tests.c b/test/core/end2end/end2end_tests.c index c9641d7d13..f529d6a899 100644 --- a/test/core/end2end/end2end_tests.c +++ b/test/core/end2end/end2end_tests.c @@ -41,7 +41,7 @@ #include -#include "src/core/ext/debug/debugger_macros.h" +#include "test/core/util/debugger_macros.h" static bool g_pre_init_called = false; diff --git a/test/core/util/debugger_macros.c b/test/core/util/debugger_macros.c new file mode 100644 index 0000000000..de6a2f38a7 --- /dev/null +++ b/test/core/util/debugger_macros.c @@ -0,0 +1,71 @@ +/* + * + * 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. + * + */ + +/* + * A collection of 'macros' that help navigating the grpc object hierarchy + * Not intended to be robust for main-line code, often cuts across abstraction + * boundaries. + */ + +#include + +#include "src/core/ext/client_channel/client_channel.h" +#include "src/core/ext/transport/chttp2/transport/internal.h" +#include "src/core/lib/channel/connected_channel.h" +#include "src/core/lib/surface/call.h" + +void grpc_summon_debugger_macros() {} + +grpc_stream *grpc_transport_stream_from_call(grpc_call *call) { + grpc_call_stack *cs = grpc_call_get_call_stack(call); + for (;;) { + grpc_call_element *el = grpc_call_stack_element(cs, cs->count - 1); + if (el->filter == &grpc_client_channel_filter) { + grpc_subchannel_call *scc = grpc_client_channel_get_subchannel_call(el); + if (scc == NULL) { + fprintf(stderr, "No subchannel-call"); + return NULL; + } + cs = grpc_subchannel_call_get_call_stack(scc); + } else if (el->filter == &grpc_connected_filter) { + return grpc_connected_channel_get_stream(el); + } else { + fprintf(stderr, "Unrecognized filter: %s", el->filter->name); + return NULL; + } + } +} + +grpc_chttp2_stream *grpc_chttp2_stream_from_call(grpc_call *call) { + return (grpc_chttp2_stream *)grpc_transport_stream_from_call(call); +} diff --git a/test/core/util/debugger_macros.h b/test/core/util/debugger_macros.h new file mode 100644 index 0000000000..4494176560 --- /dev/null +++ b/test/core/util/debugger_macros.h @@ -0,0 +1,39 @@ +/* + * + * 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. + * + */ + +#ifndef DEBUGGER_MACROS_H +#define DEBUGGER_MACROS_H + +void grpc_summon_debugger_macros(); + +#endif diff --git a/tools/run_tests/generated/sources_and_headers.json b/tools/run_tests/generated/sources_and_headers.json index d24c37e007..8a9bedc94f 100644 --- a/tools/run_tests/generated/sources_and_headers.json +++ b/tools/run_tests/generated/sources_and_headers.json @@ -7449,26 +7449,6 @@ "third_party": false, "type": "filegroup" }, - { - "deps": [ - "gpr", - "grpc_base", - "grpc_client_channel", - "grpc_transport_chttp2" - ], - "headers": [ - "src/core/ext/debug/debugger_macros.h" - ], - "is_filegroup": true, - "language": "c", - "name": "grpc_debug_macros", - "src": [ - "src/core/ext/debug/debugger_macros.c", - "src/core/ext/debug/debugger_macros.h" - ], - "third_party": false, - "type": "filegroup" - }, { "deps": [ "gpr", @@ -7663,10 +7643,8 @@ }, { "deps": [ - "gpr", "gpr_test_util", - "grpc", - "grpc_debug_macros" + "grpc" ], "headers": [ "test/core/end2end/cq_verifier.h", @@ -7674,6 +7652,7 @@ "test/core/end2end/fixtures/http_proxy.h", "test/core/end2end/fixtures/proxy.h", "test/core/iomgr/endpoint_tests.h", + "test/core/util/debugger_macros.h", "test/core/util/grpc_profiler.h", "test/core/util/memory_counters.h", "test/core/util/mock_endpoint.h", @@ -7697,6 +7676,8 @@ "test/core/end2end/fixtures/proxy.h", "test/core/iomgr/endpoint_tests.c", "test/core/iomgr/endpoint_tests.h", + "test/core/util/debugger_macros.c", + "test/core/util/debugger_macros.h", "test/core/util/grpc_profiler.c", "test/core/util/grpc_profiler.h", "test/core/util/memory_counters.c", diff --git a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj index 5a0e09e1bb..98f73b76bf 100644 --- a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj +++ b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj @@ -184,6 +184,7 @@ + @@ -192,7 +193,6 @@ - @@ -298,43 +298,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -357,6 +320,8 @@ + + @@ -377,8 +342,6 @@ - - @@ -613,90 +576,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters index be8024c7aa..d88585d002 100644 --- a/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters +++ b/vsprojects/vcxproj/grpc_test_util/grpc_test_util.vcxproj.filters @@ -31,6 +31,9 @@ test\core\iomgr + + test\core\util + test\core\util @@ -61,9 +64,6 @@ test\core\util - - src\core\ext\debug - src\core\lib\channel @@ -415,132 +415,6 @@ src\core\lib\transport - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\alpn - @@ -650,6 +524,9 @@ test\core\iomgr + + test\core\util + test\core\util @@ -674,9 +551,6 @@ test\core\util - - src\core\ext\debug - src\core\lib\channel @@ -992,117 +866,6 @@ src\core\lib\transport - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\alpn - @@ -1124,27 +887,6 @@ {f7bfac91-5eb2-dea7-4601-6c63edbbf997} - - {5db70e06-741d-708c-bf0a-b59f8ca1f8bd} - - - {7f75a084-6bc4-e813-f85b-120148aa35da} - - - {88f64b2c-ca67-05ef-c15b-8ab420357a2a} - - - {b5f17b17-8012-87c9-dfb2-428dd29d0b94} - - - {608f56aa-d257-f25b-14aa-1776a771defd} - - - {49d381db-172f-9765-4135-d7a10c4485bf} - - - {4395ba2e-6b6d-ea05-8a1e-915b8f0f85f6} - {f4e8c61e-1ca6-0fdd-7b5e-b7f9a30c9a21} diff --git a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj index c9e18e94b0..daf92305c4 100644 --- a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj +++ b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj @@ -146,42 +146,13 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -190,149 +161,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -345,6 +173,8 @@ + + @@ -365,326 +195,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters index 017e96ff62..c9a1b4c10d 100644 --- a/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters +++ b/vsprojects/vcxproj/grpc_test_util_unsecure/grpc_test_util_unsecure.vcxproj.filters @@ -16,6 +16,9 @@ test\core\iomgr + + test\core\util + test\core\util @@ -46,572 +49,6 @@ test\core\util - - src\core\ext\debug - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\compression - - - src\core\lib\compression - - - src\core\lib\debug - - - src\core\lib\http - - - src\core\lib\http - - - src\core\lib\http - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\json - - - src\core\lib\json - - - src\core\lib\json - - - src\core\lib\json - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\alpn - - - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - - - include\grpc\impl\codegen - @@ -629,6 +66,9 @@ test\core\iomgr + + test\core\util + test\core\util @@ -653,507 +93,9 @@ test\core\util - - src\core\ext\debug - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\channel - - - src\core\lib\compression - - - src\core\lib\compression - - - src\core\lib\debug - - - src\core\lib\http - - - src\core\lib\http - - - src\core\lib\http - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\iomgr - - - src\core\lib\json - - - src\core\lib\json - - - src\core\lib\json - - - src\core\lib\json - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\slice - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\surface - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\lib\transport - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\client_channel - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\transport - - - src\core\ext\transport\chttp2\alpn - - - {9793fab6-15ae-1f61-712d-c3d673654d72} - - - {c2447106-a6bf-6b88-9ad0-a42b7ac1573c} - - - {dba70812-267b-656c-9f8c-636338d3f5c0} - - - {b9e2ddac-f042-3042-ba4b-79ba4445e68c} - - - {65483377-42fd-137e-3847-00dfd4675db3} - - - {51a516dc-93e3-4dd5-d114-2d06f5df4ad7} - - - {a927155d-bcf6-0dd8-6d63-be48bcaf617f} - - - {ecb054bb-d7ce-b4db-7f82-ae022486c076} - - - {de5ce030-9e5d-b93a-da8f-ee5825ded59a} - - - {fb32254e-a807-768a-3686-4e87f3bf1e8e} - - - {87c61e56-5090-5e1a-22af-02e3c8bf4a2a} - - - {e50ce1d1-6b17-dad2-9ef3-46f68d4bee1b} - - - {67007111-23fe-296f-1808-91f2b96a31aa} - - - {e3d002a7-9318-1ac5-4259-e177f58ccc9a} - - - {ac14fd16-a4af-6b22-4226-2d7dabf25409} - - - {24268e45-f6c3-6024-b49a-d01bb9c12d96} - - - {0be401bd-3e26-dead-fdf4-2ce27a1ac3a3} - - - {ac2f12e3-ac77-f0a7-d15d-92899e61ed25} - - - {9015222c-df04-298f-3f2c-d19babffc180} - - - {c3ff117a-aae9-dedd-2f5a-888f0383cbb8} - - - {588ffbfc-2f94-a99f-85b0-4c47ec9f8d13} - - - {732318c6-bb34-9a99-611b-9928db3d4e2a} - - - {2c0ca4a1-38df-329d-eeba-5c5b61dc81a5} - {037c7645-1698-cf2d-4163-525240323101} -- cgit v1.2.3 From d3c8fc005d4c2c97ae7d71210667e165dc9884ca Mon Sep 17 00:00:00 2001 From: Craig Tiller Date: Fri, 3 Feb 2017 14:35:09 -0800 Subject: Test fixes --- test/core/end2end/bad_server_response_test.c | 2 +- test/core/end2end/tests/resource_quota_server.c | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) (limited to 'test/core/end2end') diff --git a/test/core/end2end/bad_server_response_test.c b/test/core/end2end/bad_server_response_test.c index d5f428eb82..42d960c428 100644 --- a/test/core/end2end/bad_server_response_test.c +++ b/test/core/end2end/bad_server_response_test.c @@ -135,7 +135,7 @@ static void handle_read(grpc_exec_ctx *exec_ctx, void *arg, grpc_error *error) { gpr_log(GPR_DEBUG, "got %" PRIuPTR " bytes, expected %" PRIuPTR " bytes", state.incoming_data_length, EXPECTED_INCOMING_DATA_LENGTH); - if (state.incoming_data_length > EXPECTED_INCOMING_DATA_LENGTH) { + if (state.incoming_data_length >= EXPECTED_INCOMING_DATA_LENGTH) { handle_write(exec_ctx); } else { grpc_endpoint_read(exec_ctx, state.tcp, &state.temp_incoming_buffer, diff --git a/test/core/end2end/tests/resource_quota_server.c b/test/core/end2end/tests/resource_quota_server.c index 3aeb9b27f3..4f9ed7a3a1 100644 --- a/test/core/end2end/tests/resource_quota_server.c +++ b/test/core/end2end/tests/resource_quota_server.c @@ -353,11 +353,6 @@ void resource_quota_server(grpc_end2end_test_config config) { NUM_CALLS, cancelled_calls_on_server, cancelled_calls_on_client, deadline_exceeded); - /* The call may be cancelled after the server has sent its status but before - * the client has received it. This means that we should see strictly more - * failures on the client than on the server. */ - GPR_ASSERT(cancelled_calls_on_client >= cancelled_calls_on_server); - grpc_byte_buffer_destroy(request_payload); grpc_slice_unref(request_payload_slice); grpc_resource_quota_unref(resource_quota); -- cgit v1.2.3