aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--BUILD51
-rw-r--r--Makefile123
-rw-r--r--PYTHON-MANIFEST.in2
-rw-r--r--binding.gyp9
-rw-r--r--build.yaml72
-rw-r--r--config.m416
-rw-r--r--gRPC.podspec25
-rwxr-xr-xgrpc.gemspec17
-rw-r--r--include/grpc/grpc.h3
-rw-r--r--include/grpc/impl/codegen/grpc_types.h7
-rw-r--r--package.json17
-rw-r--r--package.xml17
-rw-r--r--src/core/ext/lb_policy/grpclb/load_balancer_api.c (renamed from src/core/lib/client_config/lb_policies/load_balancer_api.c)2
-rw-r--r--src/core/ext/lb_policy/grpclb/load_balancer_api.h (renamed from src/core/lib/client_config/lb_policies/load_balancer_api.h)8
-rw-r--r--src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c (renamed from src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c)2
-rw-r--r--src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h (renamed from src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h)0
-rw-r--r--src/core/ext/lb_policy/pick_first/pick_first.c (renamed from src/core/lib/client_config/lb_policies/pick_first.c)38
-rw-r--r--src/core/ext/lb_policy/round_robin/round_robin.c (renamed from src/core/lib/client_config/lb_policies/round_robin.c)29
-rw-r--r--src/core/ext/transport/chttp2/transport/chttp2_transport.c57
-rw-r--r--src/core/ext/transport/chttp2/transport/frame_data.c24
-rw-r--r--src/core/ext/transport/chttp2/transport/frame_data.h2
-rw-r--r--src/core/ext/transport/chttp2/transport/frame_rst_stream.c8
-rw-r--r--src/core/ext/transport/chttp2/transport/frame_rst_stream.h4
-rw-r--r--src/core/ext/transport/chttp2/transport/frame_window_update.c12
-rw-r--r--src/core/ext/transport/chttp2/transport/frame_window_update.h4
-rw-r--r--src/core/ext/transport/chttp2/transport/hpack_encoder.c6
-rw-r--r--src/core/ext/transport/chttp2/transport/hpack_encoder.h2
-rw-r--r--src/core/ext/transport/chttp2/transport/hpack_parser.c3
-rw-r--r--src/core/ext/transport/chttp2/transport/internal.h8
-rw-r--r--src/core/ext/transport/chttp2/transport/parsing.c34
-rw-r--r--src/core/ext/transport/chttp2/transport/writing.c42
-rw-r--r--src/core/lib/channel/http_client_filter.c4
-rw-r--r--src/core/lib/channel/http_server_filter.c18
-rw-r--r--src/core/lib/client_config/lb_policy_registry.c7
-rw-r--r--src/core/lib/client_config/lb_policy_registry.h2
-rw-r--r--src/core/lib/iomgr/ev_posix.c6
-rw-r--r--src/core/lib/iomgr/iomgr_windows.c3
-rw-r--r--src/core/lib/iomgr/pollset_windows.c4
-rw-r--r--src/core/lib/iomgr/pollset_windows.h3
-rw-r--r--src/core/lib/iomgr/unix_sockets_posix_noop.c7
-rw-r--r--src/core/lib/surface/call.c20
-rw-r--r--src/core/lib/surface/init.c12
-rw-r--r--src/core/lib/surface/server.c30
-rw-r--r--src/core/lib/transport/static_metadata.c19
-rw-r--r--src/core/lib/transport/static_metadata.h106
-rw-r--r--src/core/lib/transport/transport.c19
-rw-r--r--src/core/lib/transport/transport.h27
-rw-r--r--src/core/plugin_registry/grpc_plugin_registry.c (renamed from src/core/lib/client_config/lb_policies/pick_first.h)21
-rw-r--r--src/core/plugin_registry/grpc_unsecure_plugin_registry.c (renamed from src/core/lib/client_config/lb_policies/round_robin.h)24
-rw-r--r--src/cpp/server/server.cc3
-rw-r--r--src/python/grpcio/grpc/_cython/imports.generated.h2
-rw-r--r--src/python/grpcio/grpc_core_dependencies.py9
-rw-r--r--src/python/grpcio/precompiled.py3
-rw-r--r--src/ruby/ext/grpc/rb_grpc_imports.generated.h2
-rw-r--r--templates/src/core/plugin_registry.template52
-rw-r--r--test/core/bad_client/bad_client.c9
-rw-r--r--test/core/client_config/lb_policies_test.c3
-rw-r--r--test/core/end2end/end2end_nosec_tests.c6
-rw-r--r--test/core/end2end/end2end_tests.c6
-rw-r--r--test/core/end2end/fixtures/proxy.c9
-rwxr-xr-xtest/core/end2end/gen_build_yaml.py1
-rw-r--r--test/core/end2end/tests/idempotent_request.c248
-rw-r--r--test/core/end2end/tests/simple_request.c1
-rw-r--r--test/core/internal_api_canaries/iomgr.c115
-rw-r--r--test/core/internal_api_canaries/support.c58
-rw-r--r--test/core/internal_api_canaries/transport.c81
-rw-r--r--test/core/iomgr/endpoint_pair_test.c4
-rw-r--r--test/core/surface/server_test.c16
-rw-r--r--test/core/transport/chttp2/hpack_encoder_test.c7
-rw-r--r--test/cpp/grpclb/grpclb_api_test.cc2
-rwxr-xr-xtools/buildgen/plugins/expand_filegroups.py20
-rwxr-xr-xtools/codegen/core/gen_load_balancing_proto.sh4
-rwxr-xr-xtools/codegen/core/gen_static_metadata.py29
-rwxr-xr-xtools/distrib/check_include_guards.py2
-rwxr-xr-xtools/distrib/check_nanopb_output.sh4
-rw-r--r--tools/doxygen/Doxyfile.core.internal17
-rwxr-xr-xtools/gce/create_interop_worker.sh64
-rwxr-xr-xtools/run_tests/build_python.sh1
-rwxr-xr-xtools/run_tests/jobset.py7
-rwxr-xr-xtools/run_tests/performance/build_performance.sh40
-rwxr-xr-xtools/run_tests/performance/remote_host_build.sh36
-rwxr-xr-xtools/run_tests/performance/remote_host_prepare.sh44
-rwxr-xr-xtools/run_tests/run_performance_tests.py353
-rwxr-xr-xtools/run_tests/run_python.sh1
-rwxr-xr-xtools/run_tests/run_tests.py39
-rw-r--r--tools/run_tests/sources_and_headers.json104
-rw-r--r--tools/run_tests/tests.json501
-rw-r--r--vsprojects/build_vs2010.bat2
-rw-r--r--vsprojects/build_vs2013.bat2
-rw-r--r--vsprojects/build_vs2015.bat2
-rw-r--r--vsprojects/buildtests_c.sln81
-rw-r--r--vsprojects/vcxproj/grpc/grpc.vcxproj26
-rw-r--r--vsprojects/vcxproj/grpc/grpc.vcxproj.filters93
-rw-r--r--vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj26
-rw-r--r--vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters93
-rw-r--r--vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj2
-rw-r--r--vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj.filters3
-rw-r--r--vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj2
-rw-r--r--vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj.filters3
-rw-r--r--vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj199
-rw-r--r--vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj.filters21
-rw-r--r--vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj199
-rw-r--r--vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj.filters21
-rw-r--r--vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj199
-rw-r--r--vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj.filters21
105 files changed, 3347 insertions, 527 deletions
diff --git a/BUILD b/BUILD
index f83a45809f..fccd2fefd9 100644
--- a/BUILD
+++ b/BUILD
@@ -159,6 +159,8 @@ cc_library(
cc_library(
name = "grpc",
srcs = [
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/ext/transport/chttp2/transport/alpn.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
@@ -198,9 +200,6 @@ cc_library(
"src/core/lib/client_config/client_config.h",
"src/core/lib/client_config/connector.h",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.h",
"src/core/lib/client_config/lb_policy_registry.h",
@@ -232,9 +231,7 @@ cc_library(
"src/core/lib/iomgr/iomgr_internal.h",
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.h",
"src/core/lib/iomgr/resolve_address.h",
@@ -262,7 +259,6 @@ cc_library(
"src/core/lib/json/json_common.h",
"src/core/lib/json/json_reader.h",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/security/auth_filters.h",
"src/core/lib/security/b64.h",
"src/core/lib/security/credentials.h",
@@ -298,6 +294,10 @@ cc_library(
"src/core/lib/tsi/ssl_types.h",
"src/core/lib/tsi/transport_security.h",
"src/core/lib/tsi/transport_security_interface.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.c",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c",
+ "src/core/ext/lb_policy/pick_first/pick_first.c",
+ "src/core/ext/lb_policy/round_robin/round_robin.c",
"src/core/ext/transport/chttp2/client/insecure/channel_create.c",
"src/core/ext/transport/chttp2/client/secure/secure_channel_create.c",
"src/core/ext/transport/chttp2/server/insecure/server_chttp2.c",
@@ -345,9 +345,6 @@ cc_library(
"src/core/lib/client_config/connector.c",
"src/core/lib/client_config/default_initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.c",
- "src/core/lib/client_config/lb_policies/load_balancer_api.c",
- "src/core/lib/client_config/lb_policies/pick_first.c",
- "src/core/lib/client_config/lb_policies/round_robin.c",
"src/core/lib/client_config/lb_policy.c",
"src/core/lib/client_config/lb_policy_factory.c",
"src/core/lib/client_config/lb_policy_registry.c",
@@ -411,7 +408,6 @@ cc_library(
"src/core/lib/json/json_reader.c",
"src/core/lib/json/json_string.c",
"src/core/lib/json/json_writer.c",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c",
"src/core/lib/security/b64.c",
"src/core/lib/security/client_auth_filter.c",
"src/core/lib/security/credentials.c",
@@ -457,6 +453,7 @@ cc_library(
"src/core/lib/tsi/fake_transport_security.c",
"src/core/lib/tsi/ssl_transport_security.c",
"src/core/lib/tsi/transport_security.c",
+ "src/core/plugin_registry/grpc_plugin_registry.c",
],
hdrs = [
"include/grpc/byte_buffer.h",
@@ -530,6 +527,8 @@ cc_library(
cc_library(
name = "grpc_unsecure",
srcs = [
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/ext/transport/chttp2/transport/alpn.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
@@ -569,9 +568,6 @@ cc_library(
"src/core/lib/client_config/client_config.h",
"src/core/lib/client_config/connector.h",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.h",
"src/core/lib/client_config/lb_policy_registry.h",
@@ -603,9 +599,7 @@ cc_library(
"src/core/lib/iomgr/iomgr_internal.h",
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.h",
"src/core/lib/iomgr/resolve_address.h",
@@ -633,7 +627,6 @@ cc_library(
"src/core/lib/json/json_common.h",
"src/core/lib/json/json_reader.h",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/statistics/census_interface.h",
"src/core/lib/statistics/census_rpc_stats.h",
"src/core/lib/surface/api_trace.h",
@@ -655,6 +648,10 @@ cc_library(
"src/core/lib/transport/static_metadata.h",
"src/core/lib/transport/transport.h",
"src/core/lib/transport/transport_impl.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.c",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c",
+ "src/core/ext/lb_policy/pick_first/pick_first.c",
+ "src/core/ext/lb_policy/round_robin/round_robin.c",
"src/core/ext/transport/chttp2/client/insecure/channel_create.c",
"src/core/ext/transport/chttp2/server/insecure/server_chttp2.c",
"src/core/ext/transport/chttp2/transport/alpn.c",
@@ -700,9 +697,6 @@ cc_library(
"src/core/lib/client_config/connector.c",
"src/core/lib/client_config/default_initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.c",
- "src/core/lib/client_config/lb_policies/load_balancer_api.c",
- "src/core/lib/client_config/lb_policies/pick_first.c",
- "src/core/lib/client_config/lb_policies/round_robin.c",
"src/core/lib/client_config/lb_policy.c",
"src/core/lib/client_config/lb_policy_factory.c",
"src/core/lib/client_config/lb_policy_registry.c",
@@ -765,7 +759,6 @@ cc_library(
"src/core/lib/json/json_reader.c",
"src/core/lib/json/json_string.c",
"src/core/lib/json/json_writer.c",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c",
"src/core/lib/surface/alarm.c",
"src/core/lib/surface/api_trace.c",
"src/core/lib/surface/byte_buffer.c",
@@ -794,6 +787,7 @@ cc_library(
"src/core/lib/transport/static_metadata.c",
"src/core/lib/transport/transport.c",
"src/core/lib/transport/transport_op_string.c",
+ "src/core/plugin_registry/grpc_unsecure_plugin_registry.c",
],
hdrs = [
"include/grpc/byte_buffer.h",
@@ -1361,6 +1355,10 @@ objc_library(
objc_library(
name = "grpc_objc",
srcs = [
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.c",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c",
+ "src/core/ext/lb_policy/pick_first/pick_first.c",
+ "src/core/ext/lb_policy/round_robin/round_robin.c",
"src/core/ext/transport/chttp2/client/insecure/channel_create.c",
"src/core/ext/transport/chttp2/client/secure/secure_channel_create.c",
"src/core/ext/transport/chttp2/server/insecure/server_chttp2.c",
@@ -1408,9 +1406,6 @@ objc_library(
"src/core/lib/client_config/connector.c",
"src/core/lib/client_config/default_initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.c",
- "src/core/lib/client_config/lb_policies/load_balancer_api.c",
- "src/core/lib/client_config/lb_policies/pick_first.c",
- "src/core/lib/client_config/lb_policies/round_robin.c",
"src/core/lib/client_config/lb_policy.c",
"src/core/lib/client_config/lb_policy_factory.c",
"src/core/lib/client_config/lb_policy_registry.c",
@@ -1474,7 +1469,6 @@ objc_library(
"src/core/lib/json/json_reader.c",
"src/core/lib/json/json_string.c",
"src/core/lib/json/json_writer.c",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c",
"src/core/lib/security/b64.c",
"src/core/lib/security/client_auth_filter.c",
"src/core/lib/security/credentials.c",
@@ -1520,6 +1514,7 @@ objc_library(
"src/core/lib/tsi/fake_transport_security.c",
"src/core/lib/tsi/ssl_transport_security.c",
"src/core/lib/tsi/transport_security.c",
+ "src/core/plugin_registry/grpc_plugin_registry.c",
],
hdrs = [
"include/grpc/byte_buffer.h",
@@ -1535,6 +1530,8 @@ objc_library(
"include/grpc/impl/codegen/propagation_bits.h",
"include/grpc/impl/codegen/status.h",
"include/grpc/status.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/ext/transport/chttp2/transport/alpn.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
@@ -1574,9 +1571,6 @@ objc_library(
"src/core/lib/client_config/client_config.h",
"src/core/lib/client_config/connector.h",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.h",
"src/core/lib/client_config/lb_policy_registry.h",
@@ -1608,9 +1602,7 @@ objc_library(
"src/core/lib/iomgr/iomgr_internal.h",
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.h",
"src/core/lib/iomgr/resolve_address.h",
@@ -1638,7 +1630,6 @@ objc_library(
"src/core/lib/json/json_common.h",
"src/core/lib/json/json_reader.h",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/security/auth_filters.h",
"src/core/lib/security/b64.h",
"src/core/lib/security/credentials.h",
diff --git a/Makefile b/Makefile
index 28a7dc6c4a..e99e5301eb 100644
--- a/Makefile
+++ b/Makefile
@@ -944,6 +944,9 @@ httpcli_format_request_test: $(BINDIR)/$(CONFIG)/httpcli_format_request_test
httpcli_test: $(BINDIR)/$(CONFIG)/httpcli_test
httpscli_test: $(BINDIR)/$(CONFIG)/httpscli_test
init_test: $(BINDIR)/$(CONFIG)/init_test
+internal_api_canary_iomgr_test: $(BINDIR)/$(CONFIG)/internal_api_canary_iomgr_test
+internal_api_canary_support_test: $(BINDIR)/$(CONFIG)/internal_api_canary_support_test
+internal_api_canary_transport_test: $(BINDIR)/$(CONFIG)/internal_api_canary_transport_test
invalid_call_argument_test: $(BINDIR)/$(CONFIG)/invalid_call_argument_test
json_fuzzer_test: $(BINDIR)/$(CONFIG)/json_fuzzer_test
json_rewrite: $(BINDIR)/$(CONFIG)/json_rewrite
@@ -1248,6 +1251,9 @@ buildtests_c: privatelibs_c \
$(BINDIR)/$(CONFIG)/httpcli_test \
$(BINDIR)/$(CONFIG)/httpscli_test \
$(BINDIR)/$(CONFIG)/init_test \
+ $(BINDIR)/$(CONFIG)/internal_api_canary_iomgr_test \
+ $(BINDIR)/$(CONFIG)/internal_api_canary_support_test \
+ $(BINDIR)/$(CONFIG)/internal_api_canary_transport_test \
$(BINDIR)/$(CONFIG)/invalid_call_argument_test \
$(BINDIR)/$(CONFIG)/json_rewrite \
$(BINDIR)/$(CONFIG)/json_rewrite_test \
@@ -2420,6 +2426,10 @@ endif
LIBGRPC_SRC = \
+ src/core/ext/lb_policy/grpclb/load_balancer_api.c \
+ src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c \
+ src/core/ext/lb_policy/pick_first/pick_first.c \
+ src/core/ext/lb_policy/round_robin/round_robin.c \
src/core/ext/transport/chttp2/client/insecure/channel_create.c \
src/core/ext/transport/chttp2/client/secure/secure_channel_create.c \
src/core/ext/transport/chttp2/server/insecure/server_chttp2.c \
@@ -2467,9 +2477,6 @@ LIBGRPC_SRC = \
src/core/lib/client_config/connector.c \
src/core/lib/client_config/default_initial_connect_string.c \
src/core/lib/client_config/initial_connect_string.c \
- src/core/lib/client_config/lb_policies/load_balancer_api.c \
- src/core/lib/client_config/lb_policies/pick_first.c \
- src/core/lib/client_config/lb_policies/round_robin.c \
src/core/lib/client_config/lb_policy.c \
src/core/lib/client_config/lb_policy_factory.c \
src/core/lib/client_config/lb_policy_registry.c \
@@ -2533,7 +2540,6 @@ LIBGRPC_SRC = \
src/core/lib/json/json_reader.c \
src/core/lib/json/json_string.c \
src/core/lib/json/json_writer.c \
- src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c \
src/core/lib/security/b64.c \
src/core/lib/security/client_auth_filter.c \
src/core/lib/security/credentials.c \
@@ -2579,6 +2585,7 @@ LIBGRPC_SRC = \
src/core/lib/tsi/fake_transport_security.c \
src/core/lib/tsi/ssl_transport_security.c \
src/core/lib/tsi/transport_security.c \
+ src/core/plugin_registry/grpc_plugin_registry.c \
third_party/nanopb/pb_common.c \
third_party/nanopb/pb_decode.c \
third_party/nanopb/pb_encode.c \
@@ -2779,6 +2786,10 @@ endif
LIBGRPC_UNSECURE_SRC = \
+ src/core/ext/lb_policy/grpclb/load_balancer_api.c \
+ src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c \
+ src/core/ext/lb_policy/pick_first/pick_first.c \
+ src/core/ext/lb_policy/round_robin/round_robin.c \
src/core/ext/transport/chttp2/client/insecure/channel_create.c \
src/core/ext/transport/chttp2/server/insecure/server_chttp2.c \
src/core/ext/transport/chttp2/transport/alpn.c \
@@ -2824,9 +2835,6 @@ LIBGRPC_UNSECURE_SRC = \
src/core/lib/client_config/connector.c \
src/core/lib/client_config/default_initial_connect_string.c \
src/core/lib/client_config/initial_connect_string.c \
- src/core/lib/client_config/lb_policies/load_balancer_api.c \
- src/core/lib/client_config/lb_policies/pick_first.c \
- src/core/lib/client_config/lb_policies/round_robin.c \
src/core/lib/client_config/lb_policy.c \
src/core/lib/client_config/lb_policy_factory.c \
src/core/lib/client_config/lb_policy_registry.c \
@@ -2889,7 +2897,6 @@ LIBGRPC_UNSECURE_SRC = \
src/core/lib/json/json_reader.c \
src/core/lib/json/json_string.c \
src/core/lib/json/json_writer.c \
- src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c \
src/core/lib/surface/alarm.c \
src/core/lib/surface/api_trace.c \
src/core/lib/surface/byte_buffer.c \
@@ -2918,6 +2925,7 @@ LIBGRPC_UNSECURE_SRC = \
src/core/lib/transport/static_metadata.c \
src/core/lib/transport/transport.c \
src/core/lib/transport/transport_op_string.c \
+ src/core/plugin_registry/grpc_unsecure_plugin_registry.c \
third_party/nanopb/pb_common.c \
third_party/nanopb/pb_decode.c \
third_party/nanopb/pb_encode.c \
@@ -5806,6 +5814,7 @@ LIBEND2END_TESTS_SRC = \
test/core/end2end/tests/graceful_server_shutdown.c \
test/core/end2end/tests/high_initial_seqno.c \
test/core/end2end/tests/hpack_size.c \
+ test/core/end2end/tests/idempotent_request.c \
test/core/end2end/tests/invoke_large_request.c \
test/core/end2end/tests/large_metadata.c \
test/core/end2end/tests/max_concurrent_streams.c \
@@ -5880,6 +5889,7 @@ LIBEND2END_NOSEC_TESTS_SRC = \
test/core/end2end/tests/graceful_server_shutdown.c \
test/core/end2end/tests/high_initial_seqno.c \
test/core/end2end/tests/hpack_size.c \
+ test/core/end2end/tests/idempotent_request.c \
test/core/end2end/tests/invoke_large_request.c \
test/core/end2end/tests/large_metadata.c \
test/core/end2end/tests/max_concurrent_streams.c \
@@ -8070,6 +8080,102 @@ endif
endif
+INTERNAL_API_CANARY_IOMGR_TEST_SRC = \
+ test/core/internal_api_canaries/iomgr.c \
+
+INTERNAL_API_CANARY_IOMGR_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(INTERNAL_API_CANARY_IOMGR_TEST_SRC))))
+ifeq ($(NO_SECURE),true)
+
+# You can't build secure targets if you don't have OpenSSL.
+
+$(BINDIR)/$(CONFIG)/internal_api_canary_iomgr_test: openssl_dep_error
+
+else
+
+
+
+$(BINDIR)/$(CONFIG)/internal_api_canary_iomgr_test: $(INTERNAL_API_CANARY_IOMGR_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
+ $(E) "[LD] Linking $@"
+ $(Q) mkdir -p `dirname $@`
+ $(Q) $(LD) $(LDFLAGS) $(INTERNAL_API_CANARY_IOMGR_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -o $(BINDIR)/$(CONFIG)/internal_api_canary_iomgr_test
+
+endif
+
+$(OBJDIR)/$(CONFIG)/test/core/internal_api_canaries/iomgr.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
+
+deps_internal_api_canary_iomgr_test: $(INTERNAL_API_CANARY_IOMGR_TEST_OBJS:.o=.dep)
+
+ifneq ($(NO_SECURE),true)
+ifneq ($(NO_DEPS),true)
+-include $(INTERNAL_API_CANARY_IOMGR_TEST_OBJS:.o=.dep)
+endif
+endif
+
+
+INTERNAL_API_CANARY_SUPPORT_TEST_SRC = \
+ test/core/internal_api_canaries/iomgr.c \
+
+INTERNAL_API_CANARY_SUPPORT_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(INTERNAL_API_CANARY_SUPPORT_TEST_SRC))))
+ifeq ($(NO_SECURE),true)
+
+# You can't build secure targets if you don't have OpenSSL.
+
+$(BINDIR)/$(CONFIG)/internal_api_canary_support_test: openssl_dep_error
+
+else
+
+
+
+$(BINDIR)/$(CONFIG)/internal_api_canary_support_test: $(INTERNAL_API_CANARY_SUPPORT_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
+ $(E) "[LD] Linking $@"
+ $(Q) mkdir -p `dirname $@`
+ $(Q) $(LD) $(LDFLAGS) $(INTERNAL_API_CANARY_SUPPORT_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -o $(BINDIR)/$(CONFIG)/internal_api_canary_support_test
+
+endif
+
+$(OBJDIR)/$(CONFIG)/test/core/internal_api_canaries/iomgr.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
+
+deps_internal_api_canary_support_test: $(INTERNAL_API_CANARY_SUPPORT_TEST_OBJS:.o=.dep)
+
+ifneq ($(NO_SECURE),true)
+ifneq ($(NO_DEPS),true)
+-include $(INTERNAL_API_CANARY_SUPPORT_TEST_OBJS:.o=.dep)
+endif
+endif
+
+
+INTERNAL_API_CANARY_TRANSPORT_TEST_SRC = \
+ test/core/internal_api_canaries/iomgr.c \
+
+INTERNAL_API_CANARY_TRANSPORT_TEST_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(INTERNAL_API_CANARY_TRANSPORT_TEST_SRC))))
+ifeq ($(NO_SECURE),true)
+
+# You can't build secure targets if you don't have OpenSSL.
+
+$(BINDIR)/$(CONFIG)/internal_api_canary_transport_test: openssl_dep_error
+
+else
+
+
+
+$(BINDIR)/$(CONFIG)/internal_api_canary_transport_test: $(INTERNAL_API_CANARY_TRANSPORT_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
+ $(E) "[LD] Linking $@"
+ $(Q) mkdir -p `dirname $@`
+ $(Q) $(LD) $(LDFLAGS) $(INTERNAL_API_CANARY_TRANSPORT_TEST_OBJS) $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a $(LDLIBS) $(LDLIBS_SECURE) -o $(BINDIR)/$(CONFIG)/internal_api_canary_transport_test
+
+endif
+
+$(OBJDIR)/$(CONFIG)/test/core/internal_api_canaries/iomgr.o: $(LIBDIR)/$(CONFIG)/libgrpc_test_util.a $(LIBDIR)/$(CONFIG)/libgrpc.a $(LIBDIR)/$(CONFIG)/libgpr_test_util.a $(LIBDIR)/$(CONFIG)/libgpr.a
+
+deps_internal_api_canary_transport_test: $(INTERNAL_API_CANARY_TRANSPORT_TEST_OBJS:.o=.dep)
+
+ifneq ($(NO_SECURE),true)
+ifneq ($(NO_DEPS),true)
+-include $(INTERNAL_API_CANARY_TRANSPORT_TEST_OBJS:.o=.dep)
+endif
+endif
+
+
INVALID_CALL_ARGUMENT_TEST_SRC = \
test/core/end2end/invalid_call_argument_test.c \
@@ -13428,6 +13534,7 @@ src/core/lib/surface/init_secure.c: $(OPENSSL_DEP)
src/core/lib/tsi/fake_transport_security.c: $(OPENSSL_DEP)
src/core/lib/tsi/ssl_transport_security.c: $(OPENSSL_DEP)
src/core/lib/tsi/transport_security.c: $(OPENSSL_DEP)
+src/core/plugin_registry/grpc_plugin_registry.c: $(OPENSSL_DEP)
src/cpp/client/secure_credentials.cc: $(OPENSSL_DEP)
src/cpp/common/auth_property_iterator.cc: $(OPENSSL_DEP)
src/cpp/common/secure_auth_context.cc: $(OPENSSL_DEP)
diff --git a/PYTHON-MANIFEST.in b/PYTHON-MANIFEST.in
index 25aba87c18..534f4c1251 100644
--- a/PYTHON-MANIFEST.in
+++ b/PYTHON-MANIFEST.in
@@ -2,8 +2,10 @@ recursive-include src/python/grpcio/grpc *.c *.h *.py *.pyx *.pxd *.pxi *.python
recursive-exclude src/python/grpcio/grpc/_cython *.so *.pyd
graft src/python/grpcio/tests
graft src/core
+graft src/boringssl
graft include/grpc
graft third_party/boringssl
+graft third_party/nanopb
graft third_party/zlib
include src/python/grpcio/commands.py
include src/python/grpcio/grpc_version.py
diff --git a/binding.gyp b/binding.gyp
index 31c7e6a753..52e68b01ff 100644
--- a/binding.gyp
+++ b/binding.gyp
@@ -558,6 +558,10 @@
'gpr',
],
'sources': [
+ 'src/core/ext/lb_policy/grpclb/load_balancer_api.c',
+ 'src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c',
+ 'src/core/ext/lb_policy/pick_first/pick_first.c',
+ 'src/core/ext/lb_policy/round_robin/round_robin.c',
'src/core/ext/transport/chttp2/client/insecure/channel_create.c',
'src/core/ext/transport/chttp2/client/secure/secure_channel_create.c',
'src/core/ext/transport/chttp2/server/insecure/server_chttp2.c',
@@ -605,9 +609,6 @@
'src/core/lib/client_config/connector.c',
'src/core/lib/client_config/default_initial_connect_string.c',
'src/core/lib/client_config/initial_connect_string.c',
- 'src/core/lib/client_config/lb_policies/load_balancer_api.c',
- 'src/core/lib/client_config/lb_policies/pick_first.c',
- 'src/core/lib/client_config/lb_policies/round_robin.c',
'src/core/lib/client_config/lb_policy.c',
'src/core/lib/client_config/lb_policy_factory.c',
'src/core/lib/client_config/lb_policy_registry.c',
@@ -671,7 +672,6 @@
'src/core/lib/json/json_reader.c',
'src/core/lib/json/json_string.c',
'src/core/lib/json/json_writer.c',
- 'src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c',
'src/core/lib/security/b64.c',
'src/core/lib/security/client_auth_filter.c',
'src/core/lib/security/credentials.c',
@@ -717,6 +717,7 @@
'src/core/lib/tsi/fake_transport_security.c',
'src/core/lib/tsi/ssl_transport_security.c',
'src/core/lib/tsi/transport_security.c',
+ 'src/core/plugin_registry/grpc_plugin_registry.c',
'third_party/nanopb/pb_common.c',
'third_party/nanopb/pb_decode.c',
'third_party/nanopb/pb_encode.c',
diff --git a/build.yaml b/build.yaml
index 0b0749b2b4..733a451ff3 100644
--- a/build.yaml
+++ b/build.yaml
@@ -262,9 +262,6 @@ filegroups:
- src/core/lib/client_config/client_config.h
- src/core/lib/client_config/connector.h
- src/core/lib/client_config/initial_connect_string.h
- - src/core/lib/client_config/lb_policies/load_balancer_api.h
- - src/core/lib/client_config/lb_policies/pick_first.h
- - src/core/lib/client_config/lb_policies/round_robin.h
- src/core/lib/client_config/lb_policy.h
- src/core/lib/client_config/lb_policy_factory.h
- src/core/lib/client_config/lb_policy_registry.h
@@ -296,9 +293,7 @@ filegroups:
- src/core/lib/iomgr/iomgr_internal.h
- src/core/lib/iomgr/iomgr_posix.h
- src/core/lib/iomgr/pollset.h
- - src/core/lib/iomgr/pollset_posix.h
- src/core/lib/iomgr/pollset_set.h
- - src/core/lib/iomgr/pollset_set_posix.h
- src/core/lib/iomgr/pollset_set_windows.h
- src/core/lib/iomgr/pollset_windows.h
- src/core/lib/iomgr/resolve_address.h
@@ -326,7 +321,6 @@ filegroups:
- src/core/lib/json/json_common.h
- src/core/lib/json/json_reader.h
- src/core/lib/json/json_writer.h
- - src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h
- src/core/lib/statistics/census_interface.h
- src/core/lib/statistics/census_rpc_stats.h
- src/core/lib/surface/api_trace.h
@@ -365,9 +359,6 @@ filegroups:
- src/core/lib/client_config/connector.c
- src/core/lib/client_config/default_initial_connect_string.c
- src/core/lib/client_config/initial_connect_string.c
- - src/core/lib/client_config/lb_policies/load_balancer_api.c
- - src/core/lib/client_config/lb_policies/pick_first.c
- - src/core/lib/client_config/lb_policies/round_robin.c
- src/core/lib/client_config/lb_policy.c
- src/core/lib/client_config/lb_policy_factory.c
- src/core/lib/client_config/lb_policy_registry.c
@@ -430,7 +421,6 @@ filegroups:
- src/core/lib/json/json_reader.c
- src/core/lib/json/json_string.c
- src/core/lib/json/json_writer.c
- - src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c
- src/core/lib/surface/alarm.c
- src/core/lib/surface/api_trace.c
- src/core/lib/surface/byte_buffer.c
@@ -466,6 +456,27 @@ filegroups:
- include/grpc/impl/codegen/grpc_types.h
- include/grpc/impl/codegen/propagation_bits.h
- include/grpc/impl/codegen/status.h
+- name: grpc_lb_policy_grpclb
+ headers:
+ - src/core/ext/lb_policy/grpclb/load_balancer_api.h
+ - src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h
+ src:
+ - src/core/ext/lb_policy/grpclb/load_balancer_api.c
+ - src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c
+ uses:
+ - grpc_base
+- name: grpc_lb_policy_pick_first
+ src:
+ - src/core/ext/lb_policy/pick_first/pick_first.c
+ plugin: grpc_lb_policy_pick_first
+ uses:
+ - grpc_base
+- name: grpc_lb_policy_round_robin
+ src:
+ - src/core/ext/lb_policy/round_robin/round_robin.c
+ plugin: grpc_lb_policy_round_robin
+ uses:
+ - grpc_base
- name: grpc_secure
headers:
- src/core/lib/security/auth_filters.h
@@ -639,10 +650,14 @@ libs:
- grpc_transport_chttp2_client_secure
- grpc_transport_chttp2_server_insecure
- grpc_transport_chttp2_client_insecure
+ - grpc_lb_policy_grpclb
+ - grpc_lb_policy_pick_first
+ - grpc_lb_policy_round_robin
- grpc_secure
- grpc_codegen
- census
- nanopb
+ generate_plugin_registry: true
secure: true
vs_packages:
- grpc.dependencies.openssl
@@ -722,9 +737,13 @@ libs:
- grpc_base
- grpc_transport_chttp2_server_insecure
- grpc_transport_chttp2_client_insecure
+ - grpc_lb_policy_grpclb
+ - grpc_lb_policy_pick_first
+ - grpc_lb_policy_round_robin
- grpc_codegen
- census
- nanopb
+ generate_plugin_registry: true
secure: false
vs_project_guid: '{46CEDFFF-9692-456A-AA24-38B5D6BCF4C5}'
- name: grpc_zookeeper
@@ -1676,6 +1695,39 @@ targets:
- grpc
- gpr_test_util
- gpr
+- name: internal_api_canary_iomgr_test
+ build: test
+ run: false
+ language: c
+ src:
+ - test/core/internal_api_canaries/iomgr.c
+ deps:
+ - grpc_test_util
+ - grpc
+ - gpr_test_util
+ - gpr
+- name: internal_api_canary_support_test
+ build: test
+ run: false
+ language: c
+ src:
+ - test/core/internal_api_canaries/iomgr.c
+ deps:
+ - grpc_test_util
+ - grpc
+ - gpr_test_util
+ - gpr
+- name: internal_api_canary_transport_test
+ build: test
+ run: false
+ language: c
+ src:
+ - test/core/internal_api_canaries/iomgr.c
+ deps:
+ - grpc_test_util
+ - grpc
+ - gpr_test_util
+ - gpr
- name: invalid_call_argument_test
build: test
language: c
diff --git a/config.m4 b/config.m4
index 6e8daaec4a..91294bc244 100644
--- a/config.m4
+++ b/config.m4
@@ -80,6 +80,10 @@ if test "$PHP_GRPC" != "no"; then
src/core/lib/support/tmpfile_posix.c \
src/core/lib/support/tmpfile_win32.c \
src/core/lib/support/wrap_memcpy.c \
+ src/core/ext/lb_policy/grpclb/load_balancer_api.c \
+ src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c \
+ src/core/ext/lb_policy/pick_first/pick_first.c \
+ src/core/ext/lb_policy/round_robin/round_robin.c \
src/core/ext/transport/chttp2/client/insecure/channel_create.c \
src/core/ext/transport/chttp2/client/secure/secure_channel_create.c \
src/core/ext/transport/chttp2/server/insecure/server_chttp2.c \
@@ -127,9 +131,6 @@ if test "$PHP_GRPC" != "no"; then
src/core/lib/client_config/connector.c \
src/core/lib/client_config/default_initial_connect_string.c \
src/core/lib/client_config/initial_connect_string.c \
- src/core/lib/client_config/lb_policies/load_balancer_api.c \
- src/core/lib/client_config/lb_policies/pick_first.c \
- src/core/lib/client_config/lb_policies/round_robin.c \
src/core/lib/client_config/lb_policy.c \
src/core/lib/client_config/lb_policy_factory.c \
src/core/lib/client_config/lb_policy_registry.c \
@@ -193,7 +194,6 @@ if test "$PHP_GRPC" != "no"; then
src/core/lib/json/json_reader.c \
src/core/lib/json/json_string.c \
src/core/lib/json/json_writer.c \
- src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c \
src/core/lib/security/b64.c \
src/core/lib/security/client_auth_filter.c \
src/core/lib/security/credentials.c \
@@ -239,6 +239,7 @@ if test "$PHP_GRPC" != "no"; then
src/core/lib/tsi/fake_transport_security.c \
src/core/lib/tsi/ssl_transport_security.c \
src/core/lib/tsi/transport_security.c \
+ src/core/plugin_registry/grpc_plugin_registry.c \
third_party/nanopb/pb_common.c \
third_party/nanopb/pb_decode.c \
third_party/nanopb/pb_encode.c \
@@ -544,6 +545,10 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/php/ext/grpc)
PHP_ADD_BUILD_DIR($ext_builddir/src/boringssl)
+ PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/lb_policy/grpclb)
+ PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0)
+ PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/lb_policy/pick_first)
+ PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/lb_policy/round_robin)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/transport/chttp2/client/insecure)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/transport/chttp2/client/secure)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/transport/chttp2/server/insecure)
@@ -552,7 +557,6 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/census)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/channel)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/client_config)
- PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/client_config/lb_policies)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/client_config/resolvers)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/compression)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/debug)
@@ -560,12 +564,12 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/iomgr)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/json)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/profiling)
- PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/proto/grpc/lb/v0)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/security)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/support)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/surface)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/transport)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/lib/tsi)
+ PHP_ADD_BUILD_DIR($ext_builddir/src/core/plugin_registry)
PHP_ADD_BUILD_DIR($ext_builddir/third_party/boringssl/crypto)
PHP_ADD_BUILD_DIR($ext_builddir/third_party/boringssl/crypto/aes)
PHP_ADD_BUILD_DIR($ext_builddir/third_party/boringssl/crypto/asn1)
diff --git a/gRPC.podspec b/gRPC.podspec
index e7d4690ec9..20427f6821 100644
--- a/gRPC.podspec
+++ b/gRPC.podspec
@@ -161,6 +161,8 @@ Pod::Spec.new do |s|
'src/core/lib/support/tmpfile_posix.c',
'src/core/lib/support/tmpfile_win32.c',
'src/core/lib/support/wrap_memcpy.c',
+ 'src/core/ext/lb_policy/grpclb/load_balancer_api.h',
+ 'src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h',
'src/core/ext/transport/chttp2/transport/alpn.h',
'src/core/ext/transport/chttp2/transport/bin_encoder.h',
'src/core/ext/transport/chttp2/transport/chttp2_transport.h',
@@ -200,9 +202,6 @@ Pod::Spec.new do |s|
'src/core/lib/client_config/client_config.h',
'src/core/lib/client_config/connector.h',
'src/core/lib/client_config/initial_connect_string.h',
- 'src/core/lib/client_config/lb_policies/load_balancer_api.h',
- 'src/core/lib/client_config/lb_policies/pick_first.h',
- 'src/core/lib/client_config/lb_policies/round_robin.h',
'src/core/lib/client_config/lb_policy.h',
'src/core/lib/client_config/lb_policy_factory.h',
'src/core/lib/client_config/lb_policy_registry.h',
@@ -234,9 +233,7 @@ Pod::Spec.new do |s|
'src/core/lib/iomgr/iomgr_internal.h',
'src/core/lib/iomgr/iomgr_posix.h',
'src/core/lib/iomgr/pollset.h',
- 'src/core/lib/iomgr/pollset_posix.h',
'src/core/lib/iomgr/pollset_set.h',
- 'src/core/lib/iomgr/pollset_set_posix.h',
'src/core/lib/iomgr/pollset_set_windows.h',
'src/core/lib/iomgr/pollset_windows.h',
'src/core/lib/iomgr/resolve_address.h',
@@ -264,7 +261,6 @@ Pod::Spec.new do |s|
'src/core/lib/json/json_common.h',
'src/core/lib/json/json_reader.h',
'src/core/lib/json/json_writer.h',
- 'src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h',
'src/core/lib/security/auth_filters.h',
'src/core/lib/security/b64.h',
'src/core/lib/security/credentials.h',
@@ -317,6 +313,10 @@ Pod::Spec.new do |s|
'include/grpc/impl/codegen/propagation_bits.h',
'include/grpc/impl/codegen/status.h',
'include/grpc/status.h',
+ 'src/core/ext/lb_policy/grpclb/load_balancer_api.c',
+ 'src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c',
+ 'src/core/ext/lb_policy/pick_first/pick_first.c',
+ 'src/core/ext/lb_policy/round_robin/round_robin.c',
'src/core/ext/transport/chttp2/client/insecure/channel_create.c',
'src/core/ext/transport/chttp2/client/secure/secure_channel_create.c',
'src/core/ext/transport/chttp2/server/insecure/server_chttp2.c',
@@ -364,9 +364,6 @@ Pod::Spec.new do |s|
'src/core/lib/client_config/connector.c',
'src/core/lib/client_config/default_initial_connect_string.c',
'src/core/lib/client_config/initial_connect_string.c',
- 'src/core/lib/client_config/lb_policies/load_balancer_api.c',
- 'src/core/lib/client_config/lb_policies/pick_first.c',
- 'src/core/lib/client_config/lb_policies/round_robin.c',
'src/core/lib/client_config/lb_policy.c',
'src/core/lib/client_config/lb_policy_factory.c',
'src/core/lib/client_config/lb_policy_registry.c',
@@ -430,7 +427,6 @@ Pod::Spec.new do |s|
'src/core/lib/json/json_reader.c',
'src/core/lib/json/json_string.c',
'src/core/lib/json/json_writer.c',
- 'src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c',
'src/core/lib/security/b64.c',
'src/core/lib/security/client_auth_filter.c',
'src/core/lib/security/credentials.c',
@@ -476,6 +472,7 @@ Pod::Spec.new do |s|
'src/core/lib/tsi/fake_transport_security.c',
'src/core/lib/tsi/ssl_transport_security.c',
'src/core/lib/tsi/transport_security.c',
+ 'src/core/plugin_registry/grpc_plugin_registry.c',
'third_party/nanopb/pb_common.c',
'third_party/nanopb/pb_decode.c',
'third_party/nanopb/pb_encode.c'
@@ -492,6 +489,8 @@ Pod::Spec.new do |s|
'src/core/lib/support/thd_internal.h',
'src/core/lib/support/time_precise.h',
'src/core/lib/support/tmpfile.h',
+ 'src/core/ext/lb_policy/grpclb/load_balancer_api.h',
+ 'src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h',
'src/core/ext/transport/chttp2/transport/alpn.h',
'src/core/ext/transport/chttp2/transport/bin_encoder.h',
'src/core/ext/transport/chttp2/transport/chttp2_transport.h',
@@ -531,9 +530,6 @@ Pod::Spec.new do |s|
'src/core/lib/client_config/client_config.h',
'src/core/lib/client_config/connector.h',
'src/core/lib/client_config/initial_connect_string.h',
- 'src/core/lib/client_config/lb_policies/load_balancer_api.h',
- 'src/core/lib/client_config/lb_policies/pick_first.h',
- 'src/core/lib/client_config/lb_policies/round_robin.h',
'src/core/lib/client_config/lb_policy.h',
'src/core/lib/client_config/lb_policy_factory.h',
'src/core/lib/client_config/lb_policy_registry.h',
@@ -565,9 +561,7 @@ Pod::Spec.new do |s|
'src/core/lib/iomgr/iomgr_internal.h',
'src/core/lib/iomgr/iomgr_posix.h',
'src/core/lib/iomgr/pollset.h',
- 'src/core/lib/iomgr/pollset_posix.h',
'src/core/lib/iomgr/pollset_set.h',
- 'src/core/lib/iomgr/pollset_set_posix.h',
'src/core/lib/iomgr/pollset_set_windows.h',
'src/core/lib/iomgr/pollset_windows.h',
'src/core/lib/iomgr/resolve_address.h',
@@ -595,7 +589,6 @@ Pod::Spec.new do |s|
'src/core/lib/json/json_common.h',
'src/core/lib/json/json_reader.h',
'src/core/lib/json/json_writer.h',
- 'src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h',
'src/core/lib/security/auth_filters.h',
'src/core/lib/security/b64.h',
'src/core/lib/security/credentials.h',
diff --git a/grpc.gemspec b/grpc.gemspec
index beeb84849e..61b3da17be 100755
--- a/grpc.gemspec
+++ b/grpc.gemspec
@@ -157,6 +157,8 @@ Gem::Specification.new do |s|
s.files += %w( include/grpc/impl/codegen/propagation_bits.h )
s.files += %w( include/grpc/impl/codegen/status.h )
s.files += %w( include/grpc/status.h )
+ s.files += %w( src/core/ext/lb_policy/grpclb/load_balancer_api.h )
+ s.files += %w( src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h )
s.files += %w( src/core/ext/transport/chttp2/transport/alpn.h )
s.files += %w( src/core/ext/transport/chttp2/transport/bin_encoder.h )
s.files += %w( src/core/ext/transport/chttp2/transport/chttp2_transport.h )
@@ -196,9 +198,6 @@ Gem::Specification.new do |s|
s.files += %w( src/core/lib/client_config/client_config.h )
s.files += %w( src/core/lib/client_config/connector.h )
s.files += %w( src/core/lib/client_config/initial_connect_string.h )
- s.files += %w( src/core/lib/client_config/lb_policies/load_balancer_api.h )
- s.files += %w( src/core/lib/client_config/lb_policies/pick_first.h )
- s.files += %w( src/core/lib/client_config/lb_policies/round_robin.h )
s.files += %w( src/core/lib/client_config/lb_policy.h )
s.files += %w( src/core/lib/client_config/lb_policy_factory.h )
s.files += %w( src/core/lib/client_config/lb_policy_registry.h )
@@ -230,9 +229,7 @@ Gem::Specification.new do |s|
s.files += %w( src/core/lib/iomgr/iomgr_internal.h )
s.files += %w( src/core/lib/iomgr/iomgr_posix.h )
s.files += %w( src/core/lib/iomgr/pollset.h )
- s.files += %w( src/core/lib/iomgr/pollset_posix.h )
s.files += %w( src/core/lib/iomgr/pollset_set.h )
- s.files += %w( src/core/lib/iomgr/pollset_set_posix.h )
s.files += %w( src/core/lib/iomgr/pollset_set_windows.h )
s.files += %w( src/core/lib/iomgr/pollset_windows.h )
s.files += %w( src/core/lib/iomgr/resolve_address.h )
@@ -260,7 +257,6 @@ Gem::Specification.new do |s|
s.files += %w( src/core/lib/json/json_common.h )
s.files += %w( src/core/lib/json/json_reader.h )
s.files += %w( src/core/lib/json/json_writer.h )
- s.files += %w( src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h )
s.files += %w( src/core/lib/security/auth_filters.h )
s.files += %w( src/core/lib/security/b64.h )
s.files += %w( src/core/lib/security/credentials.h )
@@ -300,6 +296,10 @@ Gem::Specification.new do |s|
s.files += %w( third_party/nanopb/pb_common.h )
s.files += %w( third_party/nanopb/pb_decode.h )
s.files += %w( third_party/nanopb/pb_encode.h )
+ s.files += %w( src/core/ext/lb_policy/grpclb/load_balancer_api.c )
+ s.files += %w( src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c )
+ s.files += %w( src/core/ext/lb_policy/pick_first/pick_first.c )
+ s.files += %w( src/core/ext/lb_policy/round_robin/round_robin.c )
s.files += %w( src/core/ext/transport/chttp2/client/insecure/channel_create.c )
s.files += %w( src/core/ext/transport/chttp2/client/secure/secure_channel_create.c )
s.files += %w( src/core/ext/transport/chttp2/server/insecure/server_chttp2.c )
@@ -347,9 +347,6 @@ Gem::Specification.new do |s|
s.files += %w( src/core/lib/client_config/connector.c )
s.files += %w( src/core/lib/client_config/default_initial_connect_string.c )
s.files += %w( src/core/lib/client_config/initial_connect_string.c )
- s.files += %w( src/core/lib/client_config/lb_policies/load_balancer_api.c )
- s.files += %w( src/core/lib/client_config/lb_policies/pick_first.c )
- s.files += %w( src/core/lib/client_config/lb_policies/round_robin.c )
s.files += %w( src/core/lib/client_config/lb_policy.c )
s.files += %w( src/core/lib/client_config/lb_policy_factory.c )
s.files += %w( src/core/lib/client_config/lb_policy_registry.c )
@@ -413,7 +410,6 @@ Gem::Specification.new do |s|
s.files += %w( src/core/lib/json/json_reader.c )
s.files += %w( src/core/lib/json/json_string.c )
s.files += %w( src/core/lib/json/json_writer.c )
- s.files += %w( src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c )
s.files += %w( src/core/lib/security/b64.c )
s.files += %w( src/core/lib/security/client_auth_filter.c )
s.files += %w( src/core/lib/security/credentials.c )
@@ -459,6 +455,7 @@ Gem::Specification.new do |s|
s.files += %w( src/core/lib/tsi/fake_transport_security.c )
s.files += %w( src/core/lib/tsi/ssl_transport_security.c )
s.files += %w( src/core/lib/tsi/transport_security.c )
+ s.files += %w( src/core/plugin_registry/grpc_plugin_registry.c )
s.files += %w( third_party/nanopb/pb_common.c )
s.files += %w( third_party/nanopb/pb_decode.c )
s.files += %w( third_party/nanopb/pb_encode.c )
diff --git a/include/grpc/grpc.h b/include/grpc/grpc.h
index fe0cf28b3b..dbd2cc0000 100644
--- a/include/grpc/grpc.h
+++ b/include/grpc/grpc.h
@@ -297,7 +297,8 @@ GRPCAPI grpc_call_error grpc_server_request_call(
Must be called before grpc_server_start.
Returns NULL on failure. */
GRPCAPI void *grpc_server_register_method(grpc_server *server,
- const char *method, const char *host);
+ const char *method, const char *host,
+ uint32_t flags);
/** Request notification of a new pre-registered call. 'cq_for_notification'
must have been registered to the server via
diff --git a/include/grpc/impl/codegen/grpc_types.h b/include/grpc/impl/codegen/grpc_types.h
index b11f6ffec4..993fc97adb 100644
--- a/include/grpc/impl/codegen/grpc_types.h
+++ b/include/grpc/impl/codegen/grpc_types.h
@@ -199,6 +199,12 @@ typedef enum grpc_call_error {
/** Mask of all valid flags. */
#define GRPC_WRITE_USED_MASK (GRPC_WRITE_BUFFER_HINT | GRPC_WRITE_NO_COMPRESS)
+/* Initial metadata flags */
+/** Signal that the call is idempotent */
+#define GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST (0x00000010u)
+/** Mask of all valid flags */
+#define GRPC_INITIAL_METADATA_USED_MASK GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST
+
/** A single metadata element */
typedef struct grpc_metadata {
const char *key;
@@ -250,6 +256,7 @@ typedef struct {
char *host;
size_t host_capacity;
gpr_timespec deadline;
+ uint32_t flags;
void *reserved;
} grpc_call_details;
diff --git a/package.json b/package.json
index 0827d625fd..6a5ab6e276 100644
--- a/package.json
+++ b/package.json
@@ -100,6 +100,8 @@
"include/grpc/impl/codegen/propagation_bits.h",
"include/grpc/impl/codegen/status.h",
"include/grpc/status.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/ext/transport/chttp2/transport/alpn.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
@@ -139,9 +141,6 @@
"src/core/lib/client_config/client_config.h",
"src/core/lib/client_config/connector.h",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.h",
"src/core/lib/client_config/lb_policy_registry.h",
@@ -173,9 +172,7 @@
"src/core/lib/iomgr/iomgr_internal.h",
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.h",
"src/core/lib/iomgr/resolve_address.h",
@@ -203,7 +200,6 @@
"src/core/lib/json/json_common.h",
"src/core/lib/json/json_reader.h",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/security/auth_filters.h",
"src/core/lib/security/b64.h",
"src/core/lib/security/credentials.h",
@@ -243,6 +239,10 @@
"third_party/nanopb/pb_common.h",
"third_party/nanopb/pb_decode.h",
"third_party/nanopb/pb_encode.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.c",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c",
+ "src/core/ext/lb_policy/pick_first/pick_first.c",
+ "src/core/ext/lb_policy/round_robin/round_robin.c",
"src/core/ext/transport/chttp2/client/insecure/channel_create.c",
"src/core/ext/transport/chttp2/client/secure/secure_channel_create.c",
"src/core/ext/transport/chttp2/server/insecure/server_chttp2.c",
@@ -290,9 +290,6 @@
"src/core/lib/client_config/connector.c",
"src/core/lib/client_config/default_initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.c",
- "src/core/lib/client_config/lb_policies/load_balancer_api.c",
- "src/core/lib/client_config/lb_policies/pick_first.c",
- "src/core/lib/client_config/lb_policies/round_robin.c",
"src/core/lib/client_config/lb_policy.c",
"src/core/lib/client_config/lb_policy_factory.c",
"src/core/lib/client_config/lb_policy_registry.c",
@@ -356,7 +353,6 @@
"src/core/lib/json/json_reader.c",
"src/core/lib/json/json_string.c",
"src/core/lib/json/json_writer.c",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c",
"src/core/lib/security/b64.c",
"src/core/lib/security/client_auth_filter.c",
"src/core/lib/security/credentials.c",
@@ -402,6 +398,7 @@
"src/core/lib/tsi/fake_transport_security.c",
"src/core/lib/tsi/ssl_transport_security.c",
"src/core/lib/tsi/transport_security.c",
+ "src/core/plugin_registry/grpc_plugin_registry.c",
"third_party/nanopb/pb_common.c",
"third_party/nanopb/pb_decode.c",
"third_party/nanopb/pb_encode.c",
diff --git a/package.xml b/package.xml
index ec8af2871a..3d4522d77b 100644
--- a/package.xml
+++ b/package.xml
@@ -161,6 +161,8 @@
<file baseinstalldir="/" name="include/grpc/impl/codegen/propagation_bits.h" role="src" />
<file baseinstalldir="/" name="include/grpc/impl/codegen/status.h" role="src" />
<file baseinstalldir="/" name="include/grpc/status.h" role="src" />
+ <file baseinstalldir="/" name="src/core/ext/lb_policy/grpclb/load_balancer_api.h" role="src" />
+ <file baseinstalldir="/" name="src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h" role="src" />
<file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/alpn.h" role="src" />
<file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/bin_encoder.h" role="src" />
<file baseinstalldir="/" name="src/core/ext/transport/chttp2/transport/chttp2_transport.h" role="src" />
@@ -200,9 +202,6 @@
<file baseinstalldir="/" name="src/core/lib/client_config/client_config.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/connector.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/initial_connect_string.h" role="src" />
- <file baseinstalldir="/" name="src/core/lib/client_config/lb_policies/load_balancer_api.h" role="src" />
- <file baseinstalldir="/" name="src/core/lib/client_config/lb_policies/pick_first.h" role="src" />
- <file baseinstalldir="/" name="src/core/lib/client_config/lb_policies/round_robin.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/lb_policy.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/lb_policy_factory.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/lb_policy_registry.h" role="src" />
@@ -234,9 +233,7 @@
<file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_internal.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/iomgr/iomgr_posix.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/iomgr/pollset.h" role="src" />
- <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_posix.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/iomgr/pollset_set.h" role="src" />
- <file baseinstalldir="/" name="src/core/lib/iomgr/pollset_set_posix.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/iomgr/pollset_set_windows.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/iomgr/pollset_windows.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/iomgr/resolve_address.h" role="src" />
@@ -264,7 +261,6 @@
<file baseinstalldir="/" name="src/core/lib/json/json_common.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/json/json_reader.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/json/json_writer.h" role="src" />
- <file baseinstalldir="/" name="src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/security/auth_filters.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/security/b64.h" role="src" />
<file baseinstalldir="/" name="src/core/lib/security/credentials.h" role="src" />
@@ -304,6 +300,10 @@
<file baseinstalldir="/" name="third_party/nanopb/pb_common.h" role="src" />
<file baseinstalldir="/" name="third_party/nanopb/pb_decode.h" role="src" />
<file baseinstalldir="/" name="third_party/nanopb/pb_encode.h" role="src" />
+ <file baseinstalldir="/" name="src/core/ext/lb_policy/grpclb/load_balancer_api.c" role="src" />
+ <file baseinstalldir="/" name="src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c" role="src" />
+ <file baseinstalldir="/" name="src/core/ext/lb_policy/pick_first/pick_first.c" role="src" />
+ <file baseinstalldir="/" name="src/core/ext/lb_policy/round_robin/round_robin.c" role="src" />
<file baseinstalldir="/" name="src/core/ext/transport/chttp2/client/insecure/channel_create.c" role="src" />
<file baseinstalldir="/" name="src/core/ext/transport/chttp2/client/secure/secure_channel_create.c" role="src" />
<file baseinstalldir="/" name="src/core/ext/transport/chttp2/server/insecure/server_chttp2.c" role="src" />
@@ -351,9 +351,6 @@
<file baseinstalldir="/" name="src/core/lib/client_config/connector.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/default_initial_connect_string.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/initial_connect_string.c" role="src" />
- <file baseinstalldir="/" name="src/core/lib/client_config/lb_policies/load_balancer_api.c" role="src" />
- <file baseinstalldir="/" name="src/core/lib/client_config/lb_policies/pick_first.c" role="src" />
- <file baseinstalldir="/" name="src/core/lib/client_config/lb_policies/round_robin.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/lb_policy.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/lb_policy_factory.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/client_config/lb_policy_registry.c" role="src" />
@@ -417,7 +414,6 @@
<file baseinstalldir="/" name="src/core/lib/json/json_reader.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/json/json_string.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/json/json_writer.c" role="src" />
- <file baseinstalldir="/" name="src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/security/b64.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/security/client_auth_filter.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/security/credentials.c" role="src" />
@@ -463,6 +459,7 @@
<file baseinstalldir="/" name="src/core/lib/tsi/fake_transport_security.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/tsi/ssl_transport_security.c" role="src" />
<file baseinstalldir="/" name="src/core/lib/tsi/transport_security.c" role="src" />
+ <file baseinstalldir="/" name="src/core/plugin_registry/grpc_plugin_registry.c" role="src" />
<file baseinstalldir="/" name="third_party/nanopb/pb_common.c" role="src" />
<file baseinstalldir="/" name="third_party/nanopb/pb_decode.c" role="src" />
<file baseinstalldir="/" name="third_party/nanopb/pb_encode.c" role="src" />
diff --git a/src/core/lib/client_config/lb_policies/load_balancer_api.c b/src/core/ext/lb_policy/grpclb/load_balancer_api.c
index 4cbed200df..d8af644870 100644
--- a/src/core/lib/client_config/lb_policies/load_balancer_api.c
+++ b/src/core/ext/lb_policy/grpclb/load_balancer_api.c
@@ -31,7 +31,7 @@
*
*/
-#include "src/core/lib/client_config/lb_policies/load_balancer_api.h"
+#include "src/core/ext/lb_policy/grpclb/load_balancer_api.h"
#include "third_party/nanopb/pb_decode.h"
#include "third_party/nanopb/pb_encode.h"
diff --git a/src/core/lib/client_config/lb_policies/load_balancer_api.h b/src/core/ext/lb_policy/grpclb/load_balancer_api.h
index 83299adfa9..d329a2ffe8 100644
--- a/src/core/lib/client_config/lb_policies/load_balancer_api.h
+++ b/src/core/ext/lb_policy/grpclb/load_balancer_api.h
@@ -31,13 +31,13 @@
*
*/
-#ifndef GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_LOAD_BALANCER_API_H
-#define GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_LOAD_BALANCER_API_H
+#ifndef GRPC_CORE_EXT_LB_POLICY_GRPCLB_LOAD_BALANCER_API_H
+#define GRPC_CORE_EXT_LB_POLICY_GRPCLB_LOAD_BALANCER_API_H
#include <grpc/support/slice_buffer.h>
+#include "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h"
#include "src/core/lib/client_config/lb_policy_factory.h"
-#include "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h"
#ifdef __cplusplus
extern "C" {
@@ -82,4 +82,4 @@ void grpc_grpclb_response_destroy(grpc_grpclb_response *response);
}
#endif
-#endif /* GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_LOAD_BALANCER_API_H */
+#endif /* GRPC_CORE_EXT_LB_POLICY_GRPCLB_LOAD_BALANCER_API_H */
diff --git a/src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c b/src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c
index 8f82141f96..9719673181 100644
--- a/src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c
+++ b/src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c
@@ -33,7 +33,7 @@
/* Automatically generated nanopb constant definitions */
/* Generated by nanopb-0.3.5-dev */
-#include "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h"
+#include "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h"
#if PB_PROTO_HEADER_VERSION != 30
#error Regenerate this file with the current version of nanopb generator.
diff --git a/src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h b/src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h
index 3599f881bb..3599f881bb 100644
--- a/src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h
+++ b/src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h
diff --git a/src/core/lib/client_config/lb_policies/pick_first.c b/src/core/ext/lb_policy/pick_first/pick_first.c
index 9ac550d9e7..95fe372c1b 100644
--- a/src/core/lib/client_config/lb_policies/pick_first.c
+++ b/src/core/ext/lb_policy/pick_first/pick_first.c
@@ -31,12 +31,10 @@
*
*/
-#include "src/core/lib/client_config/lb_policies/pick_first.h"
-
#include <string.h>
#include <grpc/support/alloc.h>
-#include "src/core/lib/client_config/lb_policy_factory.h"
+#include "src/core/lib/client_config/lb_policy_registry.h"
#include "src/core/lib/transport/connectivity_state.h"
typedef struct pending_pick {
@@ -78,7 +76,7 @@ typedef struct {
#define GET_SELECTED(p) \
((grpc_connected_subchannel *)gpr_atm_acq_load(&(p)->selected))
-void pf_destroy(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
+static void pf_destroy(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
pick_first_lb_policy *p = (pick_first_lb_policy *)pol;
grpc_connected_subchannel *selected = GET_SELECTED(p);
size_t i;
@@ -95,7 +93,7 @@ void pf_destroy(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
gpr_free(p);
}
-void pf_shutdown(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
+static void pf_shutdown(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
pick_first_lb_policy *p = (pick_first_lb_policy *)pol;
pending_pick *pp;
grpc_connected_subchannel *selected;
@@ -162,7 +160,7 @@ static void start_picking(grpc_exec_ctx *exec_ctx, pick_first_lb_policy *p) {
&p->connectivity_changed);
}
-void pf_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
+static void pf_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
pick_first_lb_policy *p = (pick_first_lb_policy *)pol;
gpr_mu_lock(&p->mu);
if (!p->started_picking) {
@@ -171,9 +169,10 @@ void pf_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
gpr_mu_unlock(&p->mu);
}
-int pf_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, grpc_pollset *pollset,
- grpc_metadata_batch *initial_metadata,
- grpc_connected_subchannel **target, grpc_closure *on_complete) {
+static int pf_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol,
+ grpc_pollset *pollset, grpc_metadata_batch *initial_metadata,
+ grpc_connected_subchannel **target,
+ grpc_closure *on_complete) {
pick_first_lb_policy *p = (pick_first_lb_policy *)pol;
pending_pick *pp;
@@ -356,9 +355,10 @@ static grpc_connectivity_state pf_check_connectivity(grpc_exec_ctx *exec_ctx,
return st;
}
-void pf_notify_on_state_change(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol,
- grpc_connectivity_state *current,
- grpc_closure *notify) {
+static void pf_notify_on_state_change(grpc_exec_ctx *exec_ctx,
+ grpc_lb_policy *pol,
+ grpc_connectivity_state *current,
+ grpc_closure *notify) {
pick_first_lb_policy *p = (pick_first_lb_policy *)pol;
gpr_mu_lock(&p->mu);
grpc_connectivity_state_notify_on_state_change(exec_ctx, &p->state_tracker,
@@ -366,8 +366,8 @@ void pf_notify_on_state_change(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol,
gpr_mu_unlock(&p->mu);
}
-void pf_ping_one(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol,
- grpc_closure *closure) {
+static void pf_ping_one(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol,
+ grpc_closure *closure) {
pick_first_lb_policy *p = (pick_first_lb_policy *)pol;
grpc_connected_subchannel *selected = GET_SELECTED(p);
if (selected) {
@@ -439,6 +439,14 @@ static const grpc_lb_policy_factory_vtable pick_first_factory_vtable = {
static grpc_lb_policy_factory pick_first_lb_policy_factory = {
&pick_first_factory_vtable};
-grpc_lb_policy_factory *grpc_pick_first_lb_factory_create() {
+static grpc_lb_policy_factory *pick_first_lb_factory_create() {
return &pick_first_lb_policy_factory;
}
+
+/* Plugin registration */
+
+void grpc_lb_policy_pick_first_init() {
+ grpc_register_lb_policy(pick_first_lb_factory_create());
+}
+
+void grpc_lb_policy_pick_first_shutdown() {}
diff --git a/src/core/lib/client_config/lb_policies/round_robin.c b/src/core/ext/lb_policy/round_robin/round_robin.c
index a4bc2c4786..eb6cccdca9 100644
--- a/src/core/lib/client_config/lb_policies/round_robin.c
+++ b/src/core/ext/lb_policy/round_robin/round_robin.c
@@ -31,11 +31,12 @@
*
*/
-#include "src/core/lib/client_config/lb_policies/round_robin.h"
-
#include <string.h>
#include <grpc/support/alloc.h>
+
+#include "src/core/lib/client_config/lb_policy_registry.h"
+#include "src/core/lib/debug/trace.h"
#include "src/core/lib/transport/connectivity_state.h"
typedef struct round_robin_lb_policy round_robin_lb_policy;
@@ -199,7 +200,7 @@ static void remove_disconnected_sc_locked(round_robin_lb_policy *p,
gpr_free(node);
}
-void rr_destroy(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
+static void rr_destroy(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
round_robin_lb_policy *p = (round_robin_lb_policy *)pol;
size_t i;
ready_list *elem;
@@ -226,7 +227,7 @@ void rr_destroy(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
gpr_free(p);
}
-void rr_shutdown(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
+static void rr_shutdown(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
round_robin_lb_policy *p = (round_robin_lb_policy *)pol;
pending_pick *pp;
size_t i;
@@ -291,7 +292,7 @@ static void start_picking(grpc_exec_ctx *exec_ctx, round_robin_lb_policy *p) {
}
}
-void rr_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
+static void rr_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
round_robin_lb_policy *p = (round_robin_lb_policy *)pol;
gpr_mu_lock(&p->mu);
if (!p->started_picking) {
@@ -300,9 +301,10 @@ void rr_exit_idle(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol) {
gpr_mu_unlock(&p->mu);
}
-int rr_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol, grpc_pollset *pollset,
- grpc_metadata_batch *initial_metadata,
- grpc_connected_subchannel **target, grpc_closure *on_complete) {
+static int rr_pick(grpc_exec_ctx *exec_ctx, grpc_lb_policy *pol,
+ grpc_pollset *pollset, grpc_metadata_batch *initial_metadata,
+ grpc_connected_subchannel **target,
+ grpc_closure *on_complete) {
round_robin_lb_policy *p = (round_robin_lb_policy *)pol;
pending_pick *pp;
ready_list *selected;
@@ -558,6 +560,15 @@ static const grpc_lb_policy_factory_vtable round_robin_factory_vtable = {
static grpc_lb_policy_factory round_robin_lb_policy_factory = {
&round_robin_factory_vtable};
-grpc_lb_policy_factory *grpc_round_robin_lb_factory_create() {
+static grpc_lb_policy_factory *round_robin_lb_factory_create() {
return &round_robin_lb_policy_factory;
}
+
+/* Plugin registration */
+
+void grpc_lb_policy_round_robin_init() {
+ grpc_register_lb_policy(round_robin_lb_factory_create());
+ grpc_register_tracer("round_robin", &grpc_lb_round_robin_trace);
+}
+
+void grpc_lb_policy_round_robin_shutdown() {}
diff --git a/src/core/ext/transport/chttp2/transport/chttp2_transport.c b/src/core/ext/transport/chttp2/transport/chttp2_transport.c
index 0a307a73a6..b835e74c56 100644
--- a/src/core/ext/transport/chttp2/transport/chttp2_transport.c
+++ b/src/core/ext/transport/chttp2/transport/chttp2_transport.c
@@ -758,23 +758,35 @@ static void maybe_start_some_streams(
}
}
+#define CLOSURE_BARRIER_STATS_BIT (1 << 0)
+#define CLOSURE_BARRIER_FAILURE_BIT (1 << 1)
+#define CLOSURE_BARRIER_FIRST_REF_BIT (1 << 16)
+
static grpc_closure *add_closure_barrier(grpc_closure *closure) {
- closure->final_data += 2;
+ closure->final_data += CLOSURE_BARRIER_FIRST_REF_BIT;
return closure;
}
void grpc_chttp2_complete_closure_step(grpc_exec_ctx *exec_ctx,
+ grpc_chttp2_stream_global *stream_global,
grpc_closure **pclosure, int success) {
grpc_closure *closure = *pclosure;
if (closure == NULL) {
return;
}
- closure->final_data -= 2;
+ closure->final_data -= CLOSURE_BARRIER_FIRST_REF_BIT;
if (!success) {
- closure->final_data |= 1;
+ closure->final_data |= CLOSURE_BARRIER_FAILURE_BIT;
}
- if (closure->final_data < 2) {
- grpc_exec_ctx_enqueue(exec_ctx, closure, closure->final_data == 0, NULL);
+ if (closure->final_data < CLOSURE_BARRIER_FIRST_REF_BIT) {
+ if (closure->final_data & CLOSURE_BARRIER_STATS_BIT) {
+ grpc_transport_move_stats(&stream_global->stats,
+ stream_global->collecting_stats);
+ stream_global->collecting_stats = NULL;
+ }
+ grpc_exec_ctx_enqueue(
+ exec_ctx, closure,
+ (closure->final_data & CLOSURE_BARRIER_FAILURE_BIT) == 0, NULL);
}
*pclosure = NULL;
}
@@ -807,7 +819,13 @@ static void perform_stream_op_locked(
}
/* use final_data as a barrier until enqueue time; the inital counter is
dropped at the end of this function */
- on_complete->final_data = 2;
+ on_complete->final_data = CLOSURE_BARRIER_FIRST_REF_BIT;
+
+ if (op->collect_stats != NULL) {
+ GPR_ASSERT(stream_global->collecting_stats == NULL);
+ stream_global->collecting_stats = op->collect_stats;
+ on_complete->final_data |= CLOSURE_BARRIER_STATS_BIT;
+ }
if (op->cancel_with_status != GRPC_STATUS_OK) {
cancel_from_api(exec_ctx, transport_global, stream_global,
@@ -840,7 +858,8 @@ static void perform_stream_op_locked(
}
} else {
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_initial_metadata_finished, 0);
+ exec_ctx, stream_global,
+ &stream_global->send_initial_metadata_finished, 0);
}
}
@@ -850,7 +869,7 @@ static void perform_stream_op_locked(
stream_global->send_message_finished = add_closure_barrier(on_complete);
if (stream_global->write_closed) {
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_message_finished, 0);
+ exec_ctx, stream_global, &stream_global->send_message_finished, 0);
} else {
stream_global->send_message = op->send_message;
if (stream_global->id != 0) {
@@ -870,7 +889,8 @@ static void perform_stream_op_locked(
}
if (stream_global->write_closed) {
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_trailing_metadata_finished,
+ exec_ctx, stream_global,
+ &stream_global->send_trailing_metadata_finished,
grpc_metadata_batch_is_empty(op->send_trailing_metadata));
} else if (stream_global->id != 0) {
/* TODO(ctiller): check if there's flow control for any outstanding
@@ -909,7 +929,7 @@ static void perform_stream_op_locked(
grpc_chttp2_list_add_check_read_ops(transport_global, stream_global);
}
- grpc_chttp2_complete_closure_step(exec_ctx, &on_complete, 1);
+ grpc_chttp2_complete_closure_step(exec_ctx, stream_global, &on_complete, 1);
GPR_TIMER_END("perform_stream_op_locked", 0);
}
@@ -1080,7 +1100,8 @@ static void check_read_ops(grpc_exec_ctx *exec_ctx,
&stream_global->received_trailing_metadata,
stream_global->recv_trailing_metadata);
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->recv_trailing_metadata_finished, 1);
+ exec_ctx, stream_global,
+ &stream_global->recv_trailing_metadata_finished, 1);
}
}
}
@@ -1131,7 +1152,8 @@ static void cancel_from_api(grpc_exec_ctx *exec_ctx,
&transport_global->qbuf,
grpc_chttp2_rst_stream_create(
stream_global->id,
- (uint32_t)grpc_chttp2_grpc_status_to_http2_error(status)));
+ (uint32_t)grpc_chttp2_grpc_status_to_http2_error(status),
+ &stream_global->stats.outgoing));
}
grpc_chttp2_fake_status(exec_ctx, transport_global, stream_global, status,
NULL);
@@ -1179,10 +1201,12 @@ void grpc_chttp2_fake_status(grpc_exec_ctx *exec_ctx,
static void fail_pending_writes(grpc_exec_ctx *exec_ctx,
grpc_chttp2_stream_global *stream_global) {
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_initial_metadata_finished, 0);
+ exec_ctx, stream_global, &stream_global->send_initial_metadata_finished,
+ 0);
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_trailing_metadata_finished, 0);
- grpc_chttp2_complete_closure_step(exec_ctx,
+ exec_ctx, stream_global, &stream_global->send_trailing_metadata_finished,
+ 0);
+ grpc_chttp2_complete_closure_step(exec_ctx, stream_global,
&stream_global->send_message_finished, 0);
}
@@ -1319,7 +1343,8 @@ static void close_from_api(grpc_exec_ctx *exec_ctx,
gpr_slice_buffer_add(
&transport_global->qbuf,
- grpc_chttp2_rst_stream_create(stream_global->id, GRPC_CHTTP2_NO_ERROR));
+ grpc_chttp2_rst_stream_create(stream_global->id, GRPC_CHTTP2_NO_ERROR,
+ &stream_global->stats.outgoing));
if (optional_message) {
gpr_slice_ref(*optional_message);
diff --git a/src/core/ext/transport/chttp2/transport/frame_data.c b/src/core/ext/transport/chttp2/transport/frame_data.c
index cdd624647c..baa66e0008 100644
--- a/src/core/ext/transport/chttp2/transport/frame_data.c
+++ b/src/core/ext/transport/chttp2/transport/frame_data.c
@@ -113,11 +113,13 @@ grpc_byte_stream *grpc_chttp2_incoming_frame_queue_pop(
void grpc_chttp2_encode_data(uint32_t id, gpr_slice_buffer *inbuf,
uint32_t write_bytes, int is_eof,
+ grpc_transport_one_way_stats *stats,
gpr_slice_buffer *outbuf) {
gpr_slice hdr;
uint8_t *p;
+ static const size_t header_size = 9;
- hdr = gpr_slice_malloc(9);
+ hdr = gpr_slice_malloc(header_size);
p = GPR_SLICE_START_PTR(hdr);
GPR_ASSERT(write_bytes < (1 << 24));
*p++ = (uint8_t)(write_bytes >> 16);
@@ -132,6 +134,9 @@ void grpc_chttp2_encode_data(uint32_t id, gpr_slice_buffer *inbuf,
gpr_slice_buffer_add(outbuf, hdr);
gpr_slice_buffer_move_first(inbuf, write_bytes, outbuf);
+
+ stats->framing_bytes += header_size;
+ stats->data_bytes += write_bytes;
}
grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
@@ -156,6 +161,7 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
switch (p->state) {
fh_0:
case GRPC_CHTTP2_DATA_FH_0:
+ stream_parsing->stats.incoming.framing_bytes++;
p->frame_type = *cur;
switch (p->frame_type) {
case 0:
@@ -174,6 +180,7 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
}
/* fallthrough */
case GRPC_CHTTP2_DATA_FH_1:
+ stream_parsing->stats.incoming.framing_bytes++;
p->frame_size = ((uint32_t)*cur) << 24;
if (++cur == end) {
p->state = GRPC_CHTTP2_DATA_FH_2;
@@ -181,6 +188,7 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
}
/* fallthrough */
case GRPC_CHTTP2_DATA_FH_2:
+ stream_parsing->stats.incoming.framing_bytes++;
p->frame_size |= ((uint32_t)*cur) << 16;
if (++cur == end) {
p->state = GRPC_CHTTP2_DATA_FH_3;
@@ -188,6 +196,7 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
}
/* fallthrough */
case GRPC_CHTTP2_DATA_FH_3:
+ stream_parsing->stats.incoming.framing_bytes++;
p->frame_size |= ((uint32_t)*cur) << 8;
if (++cur == end) {
p->state = GRPC_CHTTP2_DATA_FH_4;
@@ -195,6 +204,7 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
}
/* fallthrough */
case GRPC_CHTTP2_DATA_FH_4:
+ stream_parsing->stats.incoming.framing_bytes++;
p->frame_size |= ((uint32_t)*cur);
p->state = GRPC_CHTTP2_DATA_FRAME;
++cur;
@@ -215,7 +225,9 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
}
grpc_chttp2_list_add_parsing_seen_stream(transport_parsing,
stream_parsing);
- if ((uint32_t)(end - cur) == p->frame_size) {
+ uint32_t remaining = (uint32_t)(end - cur);
+ if (remaining == p->frame_size) {
+ stream_parsing->stats.incoming.data_bytes += p->frame_size;
grpc_chttp2_incoming_byte_stream_push(
exec_ctx, p->parsing_frame,
gpr_slice_sub(slice, (size_t)(cur - beg), (size_t)(end - beg)));
@@ -224,7 +236,8 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
p->parsing_frame = NULL;
p->state = GRPC_CHTTP2_DATA_FH_0;
return GRPC_CHTTP2_PARSE_OK;
- } else if ((uint32_t)(end - cur) > p->frame_size) {
+ } else if (remaining > p->frame_size) {
+ stream_parsing->stats.incoming.data_bytes += p->frame_size;
grpc_chttp2_incoming_byte_stream_push(
exec_ctx, p->parsing_frame,
gpr_slice_sub(slice, (size_t)(cur - beg),
@@ -235,11 +248,12 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
cur += p->frame_size;
goto fh_0; /* loop */
} else {
+ GPR_ASSERT(remaining <= p->frame_size);
grpc_chttp2_incoming_byte_stream_push(
exec_ctx, p->parsing_frame,
gpr_slice_sub(slice, (size_t)(cur - beg), (size_t)(end - beg)));
- GPR_ASSERT((size_t)(end - cur) <= p->frame_size);
- p->frame_size -= (uint32_t)(end - cur);
+ p->frame_size -= remaining;
+ stream_parsing->stats.incoming.data_bytes += remaining;
return GRPC_CHTTP2_PARSE_OK;
}
}
diff --git a/src/core/ext/transport/chttp2/transport/frame_data.h b/src/core/ext/transport/chttp2/transport/frame_data.h
index f2762ed9de..8a073a9c11 100644
--- a/src/core/ext/transport/chttp2/transport/frame_data.h
+++ b/src/core/ext/transport/chttp2/transport/frame_data.h
@@ -41,6 +41,7 @@
#include "src/core/ext/transport/chttp2/transport/frame.h"
#include "src/core/lib/iomgr/exec_ctx.h"
#include "src/core/lib/transport/byte_stream.h"
+#include "src/core/lib/transport/transport.h"
typedef enum {
GRPC_CHTTP2_DATA_FH_0,
@@ -96,6 +97,7 @@ grpc_chttp2_parse_error grpc_chttp2_data_parser_parse(
void grpc_chttp2_encode_data(uint32_t id, gpr_slice_buffer *inbuf,
uint32_t write_bytes, int is_eof,
+ grpc_transport_one_way_stats *stats,
gpr_slice_buffer *outbuf);
#endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_FRAME_DATA_H */
diff --git a/src/core/ext/transport/chttp2/transport/frame_rst_stream.c b/src/core/ext/transport/chttp2/transport/frame_rst_stream.c
index acfc3627e8..d9a04bbf3c 100644
--- a/src/core/ext/transport/chttp2/transport/frame_rst_stream.c
+++ b/src/core/ext/transport/chttp2/transport/frame_rst_stream.c
@@ -38,8 +38,11 @@
#include "src/core/ext/transport/chttp2/transport/frame.h"
-gpr_slice grpc_chttp2_rst_stream_create(uint32_t id, uint32_t code) {
- gpr_slice slice = gpr_slice_malloc(13);
+gpr_slice grpc_chttp2_rst_stream_create(uint32_t id, uint32_t code,
+ grpc_transport_one_way_stats *stats) {
+ static const size_t frame_size = 13;
+ gpr_slice slice = gpr_slice_malloc(frame_size);
+ stats->framing_bytes += frame_size;
uint8_t *p = GPR_SLICE_START_PTR(slice);
*p++ = 0;
@@ -84,6 +87,7 @@ grpc_chttp2_parse_error grpc_chttp2_rst_stream_parser_parse(
cur++;
p->byte++;
}
+ stream_parsing->stats.incoming.framing_bytes += (uint64_t)(end - cur);
if (p->byte == 4) {
GPR_ASSERT(is_last);
diff --git a/src/core/ext/transport/chttp2/transport/frame_rst_stream.h b/src/core/ext/transport/chttp2/transport/frame_rst_stream.h
index 134f1368a0..729274e9a2 100644
--- a/src/core/ext/transport/chttp2/transport/frame_rst_stream.h
+++ b/src/core/ext/transport/chttp2/transport/frame_rst_stream.h
@@ -37,13 +37,15 @@
#include <grpc/support/slice.h>
#include "src/core/ext/transport/chttp2/transport/frame.h"
#include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/transport/transport.h"
typedef struct {
uint8_t byte;
uint8_t reason_bytes[4];
} grpc_chttp2_rst_stream_parser;
-gpr_slice grpc_chttp2_rst_stream_create(uint32_t stream_id, uint32_t code);
+gpr_slice grpc_chttp2_rst_stream_create(uint32_t stream_id, uint32_t code,
+ grpc_transport_one_way_stats *stats);
grpc_chttp2_parse_error grpc_chttp2_rst_stream_parser_begin_frame(
grpc_chttp2_rst_stream_parser *parser, uint32_t length, uint8_t flags);
diff --git a/src/core/ext/transport/chttp2/transport/frame_window_update.c b/src/core/ext/transport/chttp2/transport/frame_window_update.c
index 1a561cebaf..0baf6d2fdd 100644
--- a/src/core/ext/transport/chttp2/transport/frame_window_update.c
+++ b/src/core/ext/transport/chttp2/transport/frame_window_update.c
@@ -36,9 +36,11 @@
#include <grpc/support/log.h>
-gpr_slice grpc_chttp2_window_update_create(uint32_t id,
- uint32_t window_update) {
- gpr_slice slice = gpr_slice_malloc(13);
+gpr_slice grpc_chttp2_window_update_create(
+ uint32_t id, uint32_t window_update, grpc_transport_one_way_stats *stats) {
+ static const size_t frame_size = 13;
+ gpr_slice slice = gpr_slice_malloc(frame_size);
+ stats->header_bytes += frame_size;
uint8_t *p = GPR_SLICE_START_PTR(slice);
GPR_ASSERT(window_update);
@@ -87,6 +89,10 @@ grpc_chttp2_parse_error grpc_chttp2_window_update_parser_parse(
p->byte++;
}
+ if (stream_parsing != NULL) {
+ stream_parsing->stats.incoming.framing_bytes += (uint32_t)(end - cur);
+ }
+
if (p->byte == 4) {
uint32_t received_update = p->amount;
if (received_update == 0 || (received_update & 0x80000000u)) {
diff --git a/src/core/ext/transport/chttp2/transport/frame_window_update.h b/src/core/ext/transport/chttp2/transport/frame_window_update.h
index f9f670b6f1..a1093a6041 100644
--- a/src/core/ext/transport/chttp2/transport/frame_window_update.h
+++ b/src/core/ext/transport/chttp2/transport/frame_window_update.h
@@ -37,6 +37,7 @@
#include <grpc/support/slice.h>
#include "src/core/ext/transport/chttp2/transport/frame.h"
#include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/transport/transport.h"
typedef struct {
uint8_t byte;
@@ -44,7 +45,8 @@ typedef struct {
uint32_t amount;
} grpc_chttp2_window_update_parser;
-gpr_slice grpc_chttp2_window_update_create(uint32_t id, uint32_t window_delta);
+gpr_slice grpc_chttp2_window_update_create(uint32_t id, uint32_t window_delta,
+ grpc_transport_one_way_stats *stats);
grpc_chttp2_parse_error grpc_chttp2_window_update_parser_begin_frame(
grpc_chttp2_window_update_parser *parser, uint32_t length, uint8_t flags);
diff --git a/src/core/ext/transport/chttp2/transport/hpack_encoder.c b/src/core/ext/transport/chttp2/transport/hpack_encoder.c
index 819addd9e3..880305afdd 100644
--- a/src/core/ext/transport/chttp2/transport/hpack_encoder.c
+++ b/src/core/ext/transport/chttp2/transport/hpack_encoder.c
@@ -74,6 +74,7 @@ typedef struct {
/* output stream id */
uint32_t stream_id;
gpr_slice_buffer *output;
+ grpc_transport_one_way_stats *stats;
} framer_state;
/* fills p (which is expected to be 9 bytes long) with a data frame header */
@@ -102,6 +103,7 @@ static void finish_frame(framer_state *st, int is_header_boundary,
st->stream_id, st->output->length - st->output_length_at_start_of_frame,
(uint8_t)((is_last_in_stream ? GRPC_CHTTP2_DATA_FLAG_END_STREAM : 0) |
(is_header_boundary ? GRPC_CHTTP2_DATA_FLAG_END_HEADERS : 0)));
+ st->stats->framing_bytes += 9;
st->is_first_frame = 0;
}
@@ -147,8 +149,10 @@ static void add_header_data(framer_state *st, gpr_slice slice) {
remaining = GRPC_CHTTP2_MAX_PAYLOAD_LENGTH +
st->output_length_at_start_of_frame - st->output->length;
if (len <= remaining) {
+ st->stats->header_bytes += len;
gpr_slice_buffer_add(st->output, slice);
} else {
+ st->stats->header_bytes += remaining;
gpr_slice_buffer_add(st->output, gpr_slice_split_head(&slice, remaining));
finish_frame(st, 0, 0);
begin_frame(st);
@@ -535,6 +539,7 @@ void grpc_chttp2_hpack_compressor_set_max_table_size(
void grpc_chttp2_encode_header(grpc_chttp2_hpack_compressor *c,
uint32_t stream_id,
grpc_metadata_batch *metadata, int is_eof,
+ grpc_transport_one_way_stats *stats,
gpr_slice_buffer *outbuf) {
framer_state st;
grpc_linked_mdelem *l;
@@ -546,6 +551,7 @@ void grpc_chttp2_encode_header(grpc_chttp2_hpack_compressor *c,
st.stream_id = stream_id;
st.output = outbuf;
st.is_first_frame = 1;
+ st.stats = stats;
/* Encode a metadata batch; store the returned values, representing
a metadata element that needs to be unreffed back into the metadata
diff --git a/src/core/ext/transport/chttp2/transport/hpack_encoder.h b/src/core/ext/transport/chttp2/transport/hpack_encoder.h
index d79de35979..91c368fbe2 100644
--- a/src/core/ext/transport/chttp2/transport/hpack_encoder.h
+++ b/src/core/ext/transport/chttp2/transport/hpack_encoder.h
@@ -40,6 +40,7 @@
#include "src/core/ext/transport/chttp2/transport/frame.h"
#include "src/core/lib/transport/metadata.h"
#include "src/core/lib/transport/metadata_batch.h"
+#include "src/core/lib/transport/transport.h"
#define GRPC_CHTTP2_HPACKC_NUM_FILTERS 256
#define GRPC_CHTTP2_HPACKC_NUM_VALUES 256
@@ -90,6 +91,7 @@ void grpc_chttp2_hpack_compressor_set_max_usable_size(
void grpc_chttp2_encode_header(grpc_chttp2_hpack_compressor *c, uint32_t id,
grpc_metadata_batch *metadata, int is_eof,
+ grpc_transport_one_way_stats *stats,
gpr_slice_buffer *outbuf);
#endif /* GRPC_CORE_EXT_TRANSPORT_CHTTP2_TRANSPORT_HPACK_ENCODER_H */
diff --git a/src/core/ext/transport/chttp2/transport/hpack_parser.c b/src/core/ext/transport/chttp2/transport/hpack_parser.c
index ec3387efb8..259452fa42 100644
--- a/src/core/ext/transport/chttp2/transport/hpack_parser.c
+++ b/src/core/ext/transport/chttp2/transport/hpack_parser.c
@@ -1426,6 +1426,9 @@ grpc_chttp2_parse_error grpc_chttp2_header_parser_parse(
grpc_chttp2_stream_parsing *stream_parsing, gpr_slice slice, int is_last) {
grpc_chttp2_hpack_parser *parser = hpack_parser;
GPR_TIMER_BEGIN("grpc_chttp2_hpack_parser_parse", 0);
+ if (stream_parsing != NULL) {
+ stream_parsing->stats.incoming.header_bytes += GPR_SLICE_LENGTH(slice);
+ }
if (!grpc_chttp2_hpack_parser_parse(parser, GPR_SLICE_START_PTR(slice),
GPR_SLICE_END_PTR(slice))) {
GPR_TIMER_END("grpc_chttp2_hpack_parser_parse", 0);
diff --git a/src/core/ext/transport/chttp2/transport/internal.h b/src/core/ext/transport/chttp2/transport/internal.h
index 2fae653623..2c3c7a3820 100644
--- a/src/core/ext/transport/chttp2/transport/internal.h
+++ b/src/core/ext/transport/chttp2/transport/internal.h
@@ -394,6 +394,9 @@ typedef struct {
grpc_metadata_batch *recv_trailing_metadata;
grpc_closure *recv_trailing_metadata_finished;
+ grpc_transport_stream_stats *collecting_stats;
+ grpc_transport_stream_stats stats;
+
/** when the application requests writes be closed, the write_closed is
'queued'; when the close is flow controlled into the send path, we are
'sending' it; when the write has been performed it is 'sent' */
@@ -435,6 +438,8 @@ typedef struct {
gpr_slice fetching_slice;
size_t stream_fetched;
grpc_closure finished_fetch;
+ /** stats gathered during the write */
+ grpc_transport_one_way_stats stats;
} grpc_chttp2_stream_writing;
struct grpc_chttp2_stream_parsing {
@@ -460,6 +465,8 @@ struct grpc_chttp2_stream_parsing {
int64_t outgoing_window;
/** number of bytes received - reset at end of parse thread execution */
int64_t received_bytes;
+ /** stats gathered during the parse */
+ grpc_transport_stream_stats stats;
/** incoming metadata */
grpc_chttp2_incoming_metadata_buffer metadata_buffer[2];
@@ -635,6 +642,7 @@ void grpc_chttp2_parsing_become_skip_parser(
grpc_exec_ctx *exec_ctx, grpc_chttp2_transport_parsing *transport_parsing);
void grpc_chttp2_complete_closure_step(grpc_exec_ctx *exec_ctx,
+ grpc_chttp2_stream_global *stream_global,
grpc_closure **pclosure, int success);
#define GRPC_CHTTP2_CLIENT_CONNECT_STRING "PRI * HTTP/2.0\r\n\r\nSM\r\n\r\n"
diff --git a/src/core/ext/transport/chttp2/transport/parsing.c b/src/core/ext/transport/chttp2/transport/parsing.c
index a9f043cee3..1e815e096b 100644
--- a/src/core/ext/transport/chttp2/transport/parsing.c
+++ b/src/core/ext/transport/chttp2/transport/parsing.c
@@ -171,6 +171,9 @@ void grpc_chttp2_publish_reads(
grpc_chttp2_list_add_check_read_ops(transport_global, stream_global);
}
+ /* flush stats to global stream state */
+ grpc_transport_move_stats(&stream_parsing->stats, &stream_global->stats);
+
/* update outgoing flow control window */
was_zero = stream_global->outgoing_window <= 0;
GRPC_CHTTP2_FLOW_MOVE_STREAM("parsed", transport_global, stream_global,
@@ -544,8 +547,13 @@ static int init_data_frame_parser(
grpc_chttp2_parsing_lookup_stream(transport_parsing,
transport_parsing->incoming_stream_id);
grpc_chttp2_parse_error err = GRPC_CHTTP2_PARSE_OK;
- if (!stream_parsing || stream_parsing->received_close)
+ if (stream_parsing == NULL) {
+ return init_skip_frame_parser(exec_ctx, transport_parsing, 0);
+ }
+ stream_parsing->stats.incoming.framing_bytes += 9;
+ if (stream_parsing->received_close) {
return init_skip_frame_parser(exec_ctx, transport_parsing, 0);
+ }
if (err == GRPC_CHTTP2_PARSE_OK) {
err = update_incoming_window(exec_ctx, transport_parsing, stream_parsing);
}
@@ -566,7 +574,8 @@ static int init_data_frame_parser(
gpr_slice_buffer_add(
&transport_parsing->qbuf,
grpc_chttp2_rst_stream_create(transport_parsing->incoming_stream_id,
- GRPC_CHTTP2_PROTOCOL_ERROR));
+ GRPC_CHTTP2_PROTOCOL_ERROR,
+ &stream_parsing->stats.outgoing));
return init_skip_frame_parser(exec_ctx, transport_parsing, 0);
case GRPC_CHTTP2_CONNECTION_ERROR:
return 0;
@@ -717,6 +726,7 @@ static int init_header_frame_parser(
transport_parsing->incoming_stream = stream_parsing;
}
GPR_ASSERT(stream_parsing != NULL && (via_accept == 0 || via_accept == 1));
+ stream_parsing->stats.incoming.framing_bytes += 9;
if (stream_parsing->received_close) {
gpr_log(GPR_ERROR, "skipping already closed grpc_chttp2_stream header");
transport_parsing->incoming_stream = NULL;
@@ -752,9 +762,14 @@ static int init_window_update_frame_parser(
&transport_parsing->simple.window_update,
transport_parsing->incoming_frame_size,
transport_parsing->incoming_frame_flags);
- if (transport_parsing->incoming_stream_id) {
- transport_parsing->incoming_stream = grpc_chttp2_parsing_lookup_stream(
- transport_parsing, transport_parsing->incoming_stream_id);
+ if (transport_parsing->incoming_stream_id != 0) {
+ grpc_chttp2_stream_parsing *stream_parsing =
+ transport_parsing->incoming_stream = grpc_chttp2_parsing_lookup_stream(
+ transport_parsing, transport_parsing->incoming_stream_id);
+ if (stream_parsing == NULL) {
+ return init_skip_frame_parser(exec_ctx, transport_parsing, 0);
+ }
+ stream_parsing->stats.incoming.framing_bytes += 9;
}
transport_parsing->parser = grpc_chttp2_window_update_parser_parse;
transport_parsing->parser_data = &transport_parsing->simple.window_update;
@@ -778,11 +793,13 @@ static int init_rst_stream_parser(
&transport_parsing->simple.rst_stream,
transport_parsing->incoming_frame_size,
transport_parsing->incoming_frame_flags);
- transport_parsing->incoming_stream = grpc_chttp2_parsing_lookup_stream(
- transport_parsing, transport_parsing->incoming_stream_id);
+ grpc_chttp2_stream_parsing *stream_parsing =
+ transport_parsing->incoming_stream = grpc_chttp2_parsing_lookup_stream(
+ transport_parsing, transport_parsing->incoming_stream_id);
if (!transport_parsing->incoming_stream) {
return init_skip_frame_parser(exec_ctx, transport_parsing, 0);
}
+ stream_parsing->stats.incoming.framing_bytes += 9;
transport_parsing->parser = grpc_chttp2_rst_stream_parser_parse;
transport_parsing->parser_data = &transport_parsing->simple.rst_stream;
return ok;
@@ -856,7 +873,8 @@ static int parse_frame_slice(grpc_exec_ctx *exec_ctx,
gpr_slice_buffer_add(
&transport_parsing->qbuf,
grpc_chttp2_rst_stream_create(transport_parsing->incoming_stream_id,
- GRPC_CHTTP2_PROTOCOL_ERROR));
+ GRPC_CHTTP2_PROTOCOL_ERROR,
+ &stream_parsing->stats.outgoing));
}
return 1;
case GRPC_CHTTP2_CONNECTION_ERROR:
diff --git a/src/core/ext/transport/chttp2/transport/writing.c b/src/core/ext/transport/chttp2/transport/writing.c
index 8d5886f225..6bb188f1da 100644
--- a/src/core/ext/transport/chttp2/transport/writing.c
+++ b/src/core/ext/transport/chttp2/transport/writing.c
@@ -161,8 +161,10 @@ int grpc_chttp2_unlocking_check_writes(
transport_global->announce_incoming_window, UINT32_MAX);
GRPC_CHTTP2_FLOW_DEBIT_TRANSPORT("write", transport_global,
announce_incoming_window, announced);
- gpr_slice_buffer_add(&transport_writing->outbuf,
- grpc_chttp2_window_update_create(0, announced));
+ grpc_transport_one_way_stats throwaway_stats;
+ gpr_slice_buffer_add(
+ &transport_writing->outbuf,
+ grpc_chttp2_window_update_create(0, announced, &throwaway_stats));
}
GPR_TIMER_END("grpc_chttp2_unlocking_check_writes", 0);
@@ -205,7 +207,8 @@ static void finalize_outbuf(grpc_exec_ctx *exec_ctx,
if (stream_writing->send_initial_metadata != NULL) {
grpc_chttp2_encode_header(
&transport_writing->hpack_compressor, stream_writing->id,
- stream_writing->send_initial_metadata, 0, &transport_writing->outbuf);
+ stream_writing->send_initial_metadata, 0, &stream_writing->stats,
+ &transport_writing->outbuf);
stream_writing->send_initial_metadata = NULL;
stream_writing->sent_initial_metadata = 1;
}
@@ -216,7 +219,8 @@ static void finalize_outbuf(grpc_exec_ctx *exec_ctx,
gpr_slice_buffer_add(
&transport_writing->outbuf,
grpc_chttp2_window_update_create(stream_writing->id,
- stream_writing->announce_window));
+ stream_writing->announce_window,
+ &stream_writing->stats));
GRPC_CHTTP2_FLOW_DEBIT_STREAM("write", transport_writing, stream_writing,
announce_window, announce);
stream_writing->announce_window = 0;
@@ -255,7 +259,8 @@ static void finalize_outbuf(grpc_exec_ctx *exec_ctx,
stream_writing->send_trailing_metadata);
grpc_chttp2_encode_data(
stream_writing->id, &stream_writing->flow_controlled_buffer,
- send_bytes, is_last_frame, &transport_writing->outbuf);
+ send_bytes, is_last_frame, &stream_writing->stats,
+ &transport_writing->outbuf);
GRPC_CHTTP2_FLOW_DEBIT_STREAM("write", transport_writing,
stream_writing, outgoing_window,
send_bytes);
@@ -281,19 +286,20 @@ static void finalize_outbuf(grpc_exec_ctx *exec_ctx,
stream_writing->send_trailing_metadata != NULL) {
if (grpc_metadata_batch_is_empty(
stream_writing->send_trailing_metadata)) {
- grpc_chttp2_encode_data(stream_writing->id,
- &stream_writing->flow_controlled_buffer, 0, 1,
- &transport_writing->outbuf);
+ grpc_chttp2_encode_data(
+ stream_writing->id, &stream_writing->flow_controlled_buffer, 0, 1,
+ &stream_writing->stats, &transport_writing->outbuf);
} else {
- grpc_chttp2_encode_header(&transport_writing->hpack_compressor,
- stream_writing->id,
- stream_writing->send_trailing_metadata, 1,
- &transport_writing->outbuf);
+ grpc_chttp2_encode_header(
+ &transport_writing->hpack_compressor, stream_writing->id,
+ stream_writing->send_trailing_metadata, 1, &stream_writing->stats,
+ &transport_writing->outbuf);
}
if (!transport_writing->is_client && !stream_writing->read_closed) {
gpr_slice_buffer_add(&transport_writing->outbuf,
grpc_chttp2_rst_stream_create(
- stream_writing->id, GRPC_CHTTP2_NO_ERROR));
+ stream_writing->id, GRPC_CHTTP2_NO_ERROR,
+ &stream_writing->stats));
}
stream_writing->send_trailing_metadata = NULL;
stream_writing->sent_trailing_metadata = 1;
@@ -328,17 +334,21 @@ void grpc_chttp2_cleanup_writing(
transport_global, transport_writing, &stream_global, &stream_writing)) {
if (stream_writing->sent_initial_metadata) {
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_initial_metadata_finished, 1);
+ exec_ctx, stream_global,
+ &stream_global->send_initial_metadata_finished, 1);
}
+ grpc_transport_move_one_way_stats(&stream_writing->stats,
+ &stream_global->stats.outgoing);
if (stream_writing->sent_message) {
GPR_ASSERT(stream_writing->send_message == NULL);
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_message_finished, 1);
+ exec_ctx, stream_global, &stream_global->send_message_finished, 1);
stream_writing->sent_message = 0;
}
if (stream_writing->sent_trailing_metadata) {
grpc_chttp2_complete_closure_step(
- exec_ctx, &stream_global->send_trailing_metadata_finished, 1);
+ exec_ctx, stream_global,
+ &stream_global->send_trailing_metadata_finished, 1);
}
if (stream_writing->sent_trailing_metadata) {
grpc_chttp2_mark_stream_closed(exec_ctx, transport_global, stream_global,
diff --git a/src/core/lib/channel/http_client_filter.c b/src/core/lib/channel/http_client_filter.c
index 7dbac38414..b4e58b7f29 100644
--- a/src/core/lib/channel/http_client_filter.c
+++ b/src/core/lib/channel/http_client_filter.c
@@ -112,7 +112,9 @@ static void hc_mutate_op(grpc_call_element *elem,
/* Send : prefixed headers, which have to be before any application
layer headers. */
grpc_metadata_batch_add_head(op->send_initial_metadata, &calld->method,
- GRPC_MDELEM_METHOD_POST);
+ op->send_idempotent_request
+ ? GRPC_MDELEM_METHOD_PUT
+ : GRPC_MDELEM_METHOD_POST);
grpc_metadata_batch_add_head(op->send_initial_metadata, &calld->scheme,
channeld->static_scheme);
grpc_metadata_batch_add_tail(op->send_initial_metadata, &calld->te_trailers,
diff --git a/src/core/lib/channel/http_server_filter.c b/src/core/lib/channel/http_server_filter.c
index df99b77ab3..db1a3d5010 100644
--- a/src/core/lib/channel/http_server_filter.c
+++ b/src/core/lib/channel/http_server_filter.c
@@ -41,7 +41,7 @@
typedef struct call_data {
uint8_t seen_path;
- uint8_t seen_post;
+ uint8_t seen_method;
uint8_t sent_status;
uint8_t seen_scheme;
uint8_t seen_te_trailers;
@@ -50,6 +50,7 @@ typedef struct call_data {
grpc_linked_mdelem content_type;
grpc_metadata_batch *recv_initial_metadata;
+ bool *recv_idempotent_request;
/** Closure to call when finished with the hs_on_recv hook */
grpc_closure *on_done_recv;
/** Receive closures are chained: we inject this closure as the on_done_recv
@@ -72,11 +73,16 @@ static grpc_mdelem *server_filter(void *user_data, grpc_mdelem *md) {
/* Check if it is one of the headers we care about. */
if (md == GRPC_MDELEM_TE_TRAILERS || md == GRPC_MDELEM_METHOD_POST ||
- md == GRPC_MDELEM_SCHEME_HTTP || md == GRPC_MDELEM_SCHEME_HTTPS ||
+ md == GRPC_MDELEM_METHOD_PUT || md == GRPC_MDELEM_SCHEME_HTTP ||
+ md == GRPC_MDELEM_SCHEME_HTTPS ||
md == GRPC_MDELEM_CONTENT_TYPE_APPLICATION_SLASH_GRPC) {
/* swallow it */
if (md == GRPC_MDELEM_METHOD_POST) {
- calld->seen_post = 1;
+ calld->seen_method = 1;
+ *calld->recv_idempotent_request = false;
+ } else if (md == GRPC_MDELEM_METHOD_PUT) {
+ calld->seen_method = 1;
+ *calld->recv_idempotent_request = true;
} else if (md->key == GRPC_MDSTR_SCHEME) {
calld->seen_scheme = 1;
} else if (md == GRPC_MDELEM_TE_TRAILERS) {
@@ -142,7 +148,7 @@ static void hs_on_recv(grpc_exec_ctx *exec_ctx, void *user_data, bool success) {
/* Have we seen the required http2 transport headers?
(:method, :scheme, content-type, with :path and :authority covered
at the channel level right now) */
- if (calld->seen_post && calld->seen_scheme && calld->seen_te_trailers &&
+ if (calld->seen_method && calld->seen_scheme && calld->seen_te_trailers &&
calld->seen_path && calld->seen_authority) {
/* do nothing */
} else {
@@ -152,7 +158,7 @@ static void hs_on_recv(grpc_exec_ctx *exec_ctx, void *user_data, bool success) {
if (!calld->seen_authority) {
gpr_log(GPR_ERROR, "Missing :authority header");
}
- if (!calld->seen_post) {
+ if (!calld->seen_method) {
gpr_log(GPR_ERROR, "Missing :method header");
}
if (!calld->seen_scheme) {
@@ -185,7 +191,9 @@ static void hs_mutate_op(grpc_call_element *elem,
if (op->recv_initial_metadata) {
/* substitute our callback for the higher callback */
+ GPR_ASSERT(op->recv_idempotent_request != NULL);
calld->recv_initial_metadata = op->recv_initial_metadata;
+ calld->recv_idempotent_request = op->recv_idempotent_request;
calld->on_done_recv = op->recv_initial_metadata_ready;
op->recv_initial_metadata_ready = &calld->hs_on_recv;
}
diff --git a/src/core/lib/client_config/lb_policy_registry.c b/src/core/lib/client_config/lb_policy_registry.c
index f703e630a0..d1dc502b9a 100644
--- a/src/core/lib/client_config/lb_policy_registry.c
+++ b/src/core/lib/client_config/lb_policy_registry.c
@@ -40,12 +40,7 @@
static grpc_lb_policy_factory *g_all_of_the_lb_policies[MAX_POLICIES];
static int g_number_of_lb_policies = 0;
-static grpc_lb_policy_factory *g_default_lb_policy_factory;
-
-void grpc_lb_policy_registry_init(grpc_lb_policy_factory *default_factory) {
- g_number_of_lb_policies = 0;
- g_default_lb_policy_factory = default_factory;
-}
+void grpc_lb_policy_registry_init(void) { g_number_of_lb_policies = 0; }
void grpc_lb_policy_registry_shutdown(void) {
int i;
diff --git a/src/core/lib/client_config/lb_policy_registry.h b/src/core/lib/client_config/lb_policy_registry.h
index 789854bd20..1ecf7fe39f 100644
--- a/src/core/lib/client_config/lb_policy_registry.h
+++ b/src/core/lib/client_config/lb_policy_registry.h
@@ -39,7 +39,7 @@
/** Initialize the registry and set \a default_factory as the factory to be
* returned when no name is provided in a lookup */
-void grpc_lb_policy_registry_init(grpc_lb_policy_factory *default_factory);
+void grpc_lb_policy_registry_init(void);
void grpc_lb_policy_registry_shutdown(void);
/** Register a LB policy factory. */
diff --git a/src/core/lib/iomgr/ev_posix.c b/src/core/lib/iomgr/ev_posix.c
index c8da5b1347..952cf28345 100644
--- a/src/core/lib/iomgr/ev_posix.c
+++ b/src/core/lib/iomgr/ev_posix.c
@@ -31,6 +31,10 @@
*
*/
+#include <grpc/support/port_platform.h>
+
+#ifdef GPR_POSIX_SOCKET
+
#include "src/core/lib/iomgr/ev_posix.h"
#include <string.h>
@@ -242,3 +246,5 @@ void grpc_pollset_set_del_fd(grpc_exec_ctx *exec_ctx,
}
void grpc_kick_poller(void) { g_event_engine->kick_poller(); }
+
+#endif // GPR_POSIX_SOCKET
diff --git a/src/core/lib/iomgr/iomgr_windows.c b/src/core/lib/iomgr/iomgr_windows.c
index af7e616394..f3c752e72a 100644
--- a/src/core/lib/iomgr/iomgr_windows.c
+++ b/src/core/lib/iomgr/iomgr_windows.c
@@ -41,6 +41,7 @@
#include "src/core/lib/iomgr/iocp_windows.h"
#include "src/core/lib/iomgr/iomgr.h"
+#include "src/core/lib/iomgr/pollset_windows.h"
#include "src/core/lib/iomgr/socket_windows.h"
/* Windows' io manager is going to be fully designed using IO completion
@@ -61,11 +62,13 @@ static void winsock_shutdown(void) {
void grpc_iomgr_platform_init(void) {
winsock_init();
grpc_iocp_init();
+ grpc_pollset_global_init();
}
void grpc_iomgr_platform_flush(void) { grpc_iocp_flush(); }
void grpc_iomgr_platform_shutdown(void) {
+ grpc_pollset_global_shutdown();
grpc_iocp_shutdown();
winsock_shutdown();
}
diff --git a/src/core/lib/iomgr/pollset_windows.c b/src/core/lib/iomgr/pollset_windows.c
index 6b339127a8..acb2bac634 100644
--- a/src/core/lib/iomgr/pollset_windows.c
+++ b/src/core/lib/iomgr/pollset_windows.c
@@ -47,7 +47,7 @@ gpr_mu grpc_polling_mu;
static grpc_pollset_worker *g_active_poller;
static grpc_pollset_worker g_global_root_worker;
-void grpc_pollset_global_init() {
+void grpc_pollset_global_init(void) {
gpr_mu_init(&grpc_polling_mu);
g_active_poller = NULL;
g_global_root_worker.links[GRPC_POLLSET_WORKER_LINK_GLOBAL].next =
@@ -55,7 +55,7 @@ void grpc_pollset_global_init() {
&g_global_root_worker;
}
-void grpc_pollset_global_shutdown() { gpr_mu_destroy(&grpc_polling_mu); }
+void grpc_pollset_global_shutdown(void) { gpr_mu_destroy(&grpc_polling_mu); }
static void remove_worker(grpc_pollset_worker *worker,
grpc_pollset_worker_link_type type) {
diff --git a/src/core/lib/iomgr/pollset_windows.h b/src/core/lib/iomgr/pollset_windows.h
index fa9553ffea..1833dcf035 100644
--- a/src/core/lib/iomgr/pollset_windows.h
+++ b/src/core/lib/iomgr/pollset_windows.h
@@ -72,4 +72,7 @@ struct grpc_pollset {
grpc_closure *on_shutdown;
};
+void grpc_pollset_global_init(void);
+void grpc_pollset_global_shutdown(void);
+
#endif /* GRPC_CORE_LIB_IOMGR_POLLSET_WINDOWS_H */
diff --git a/src/core/lib/iomgr/unix_sockets_posix_noop.c b/src/core/lib/iomgr/unix_sockets_posix_noop.c
index 06f6ee05e7..43e006e15e 100644
--- a/src/core/lib/iomgr/unix_sockets_posix_noop.c
+++ b/src/core/lib/iomgr/unix_sockets_posix_noop.c
@@ -35,7 +35,12 @@
#ifndef GPR_HAVE_UNIX_SOCKET
-void grpc_create_socketpair_if_unix(int sv[2]) {}
+void grpc_create_socketpair_if_unix(int sv[2]) {
+ // TODO: Either implement this for the non-Unix socket case or make
+ // sure that it is never called in any such case. Until then, leave an
+ // assertion to notify if this gets called inadvertently
+ GPR_ASSERT(0);
+}
grpc_resolved_addresses *grpc_resolve_unix_domain_address(const char *name) {
return NULL;
diff --git a/src/core/lib/surface/call.c b/src/core/lib/surface/call.c
index d63a4a7401..77ad410b50 100644
--- a/src/core/lib/surface/call.c
+++ b/src/core/lib/surface/call.c
@@ -174,6 +174,9 @@ struct grpc_call {
/* Received call statuses from various sources */
received_status status[STATUS_SOURCE_COUNT];
+ /* Call stats: only valid after trailing metadata received */
+ grpc_transport_stream_stats stats;
+
/* Compression algorithm for the call */
grpc_compression_algorithm compression_algorithm;
/* Supported encodings (compression algorithms), a bitset */
@@ -909,7 +912,7 @@ static void set_cancelled_value(grpc_status_code status, void *dest) {
*(int *)dest = (status != GRPC_STATUS_OK);
}
-static int are_write_flags_valid(uint32_t flags) {
+static bool are_write_flags_valid(uint32_t flags) {
/* check that only bits in GRPC_WRITE_(INTERNAL?)_USED_MASK are set */
const uint32_t allowed_write_positions =
(GRPC_WRITE_USED_MASK | GRPC_WRITE_INTERNAL_USED_MASK);
@@ -917,6 +920,15 @@ static int are_write_flags_valid(uint32_t flags) {
return !(flags & invalid_positions);
}
+static bool are_initial_metadata_flags_valid(uint32_t flags, bool is_client) {
+ /* check that only bits in GRPC_WRITE_(INTERNAL?)_USED_MASK are set */
+ uint32_t invalid_positions = ~GRPC_INITIAL_METADATA_USED_MASK;
+ if (!is_client) {
+ invalid_positions |= GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST;
+ }
+ return !(flags & invalid_positions);
+}
+
static batch_control *allocate_batch_control(grpc_call *call) {
size_t i;
for (i = 0; i < MAX_CONCURRENT_BATCHES; i++) {
@@ -1196,7 +1208,7 @@ static grpc_call_error call_start_batch(grpc_exec_ctx *exec_ctx,
switch (op->op) {
case GRPC_OP_SEND_INITIAL_METADATA:
/* Flag validation: currently allow no flags */
- if (op->flags != 0) {
+ if (!are_initial_metadata_flags_valid(op->flags, call->is_client)) {
error = GRPC_CALL_ERROR_INVALID_FLAGS;
goto done_with_error;
}
@@ -1220,6 +1232,8 @@ static grpc_call_error call_start_batch(grpc_exec_ctx *exec_ctx,
call->metadata_batch[0][0].deadline = call->send_deadline;
stream_op.send_initial_metadata =
&call->metadata_batch[0 /* is_receiving */][0 /* is_trailing */];
+ stream_op.send_idempotent_request =
+ (op->flags & GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST) != 0;
break;
case GRPC_OP_SEND_MESSAGE:
if (!are_write_flags_valid(op->flags)) {
@@ -1371,6 +1385,7 @@ static grpc_call_error call_start_batch(grpc_exec_ctx *exec_ctx,
bctl->recv_final_op = 1;
stream_op.recv_trailing_metadata =
&call->metadata_batch[1 /* is_receiving */][1 /* is_trailing */];
+ stream_op.collect_stats = &call->stats;
break;
case GRPC_OP_RECV_CLOSE_ON_SERVER:
/* Flag validation: currently allow no flags */
@@ -1392,6 +1407,7 @@ static grpc_call_error call_start_batch(grpc_exec_ctx *exec_ctx,
bctl->recv_final_op = 1;
stream_op.recv_trailing_metadata =
&call->metadata_batch[1 /* is_receiving */][1 /* is_trailing */];
+ stream_op.collect_stats = &call->stats;
break;
}
}
diff --git a/src/core/lib/surface/init.c b/src/core/lib/surface/init.c
index dbfc8a9336..3ccc21fb31 100644
--- a/src/core/lib/surface/init.c
+++ b/src/core/lib/surface/init.c
@@ -48,8 +48,6 @@
#include "src/core/lib/channel/connected_channel.h"
#include "src/core/lib/channel/http_client_filter.h"
#include "src/core/lib/channel/http_server_filter.h"
-#include "src/core/lib/client_config/lb_policies/pick_first.h"
-#include "src/core/lib/client_config/lb_policies/round_robin.h"
#include "src/core/lib/client_config/lb_policy_registry.h"
#include "src/core/lib/client_config/resolver_registry.h"
#include "src/core/lib/client_config/resolvers/dns_resolver.h"
@@ -75,6 +73,9 @@
#define GRPC_DEFAULT_NAME_PREFIX "dns:///"
#endif
+/* (generated) built in registry of plugins */
+extern void grpc_register_built_in_plugins(void);
+
#define MAX_PLUGINS 128
static gpr_once g_basic_init = GPR_ONCE_INIT;
@@ -83,6 +84,7 @@ static int g_initializations;
static void do_basic_init(void) {
gpr_mu_init(&g_init_mu);
+ grpc_register_built_in_plugins();
/* TODO(ctiller): ideally remove this strict linkage */
grpc_register_plugin(census_grpc_plugin_init, census_grpc_plugin_destroy);
g_initializations = 0;
@@ -165,14 +167,12 @@ void grpc_init(void) {
gpr_time_init();
grpc_mdctx_global_init();
grpc_channel_init_init();
- grpc_lb_policy_registry_init(grpc_pick_first_lb_factory_create());
- grpc_register_lb_policy(grpc_pick_first_lb_factory_create());
- grpc_register_lb_policy(grpc_round_robin_lb_factory_create());
+ grpc_lb_policy_registry_init();
grpc_resolver_registry_init(GRPC_DEFAULT_NAME_PREFIX);
grpc_register_resolver_type(grpc_dns_resolver_factory_create());
grpc_register_resolver_type(grpc_ipv4_resolver_factory_create());
grpc_register_resolver_type(grpc_ipv6_resolver_factory_create());
-#ifdef GPR_POSIX_SOCKET
+#ifdef GPR_HAVE_UNIX_SOCKET
grpc_register_resolver_type(grpc_unix_resolver_factory_create());
#endif
grpc_register_tracer("api", &grpc_api_trace);
diff --git a/src/core/lib/surface/server.c b/src/core/lib/surface/server.c
index 080734e9d5..55e5e49e11 100644
--- a/src/core/lib/surface/server.c
+++ b/src/core/lib/surface/server.c
@@ -100,6 +100,7 @@ typedef struct requested_call {
typedef struct channel_registered_method {
registered_method *server_registered_method;
+ uint32_t flags;
grpc_mdstr *method;
grpc_mdstr *host;
} channel_registered_method;
@@ -152,6 +153,7 @@ struct call_data {
grpc_completion_queue *cq_new;
grpc_metadata_batch *recv_initial_metadata;
+ bool recv_idempotent_request;
grpc_metadata_array initial_metadata;
grpc_closure got_initial_metadata;
@@ -171,6 +173,7 @@ struct request_matcher {
struct registered_method {
char *method;
char *host;
+ uint32_t flags;
request_matcher request_matcher;
registered_method *next;
};
@@ -468,6 +471,9 @@ static void start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_call_element *elem) {
if (!rm) break;
if (rm->host != calld->host) continue;
if (rm->method != calld->path) continue;
+ if ((rm->flags & GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST) &&
+ !calld->recv_idempotent_request)
+ continue;
finish_start_new_rpc(exec_ctx, server, elem,
&rm->server_registered_method->request_matcher);
return;
@@ -480,6 +486,9 @@ static void start_new_rpc(grpc_exec_ctx *exec_ctx, grpc_call_element *elem) {
if (!rm) break;
if (rm->host != NULL) continue;
if (rm->method != calld->path) continue;
+ if ((rm->flags & GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST) &&
+ !calld->recv_idempotent_request)
+ continue;
finish_start_new_rpc(exec_ctx, server, elem,
&rm->server_registered_method->request_matcher);
return;
@@ -598,9 +607,11 @@ static void server_mutate_op(grpc_call_element *elem,
call_data *calld = elem->call_data;
if (op->recv_initial_metadata != NULL) {
+ GPR_ASSERT(op->recv_idempotent_request == NULL);
calld->recv_initial_metadata = op->recv_initial_metadata;
calld->on_done_recv_initial_metadata = op->recv_initial_metadata_ready;
op->recv_initial_metadata_ready = &calld->server_on_recv_initial_metadata;
+ op->recv_idempotent_request = &calld->recv_idempotent_request;
}
}
@@ -830,10 +841,12 @@ static int streq(const char *a, const char *b) {
}
void *grpc_server_register_method(grpc_server *server, const char *method,
- const char *host) {
+ const char *host, uint32_t flags) {
registered_method *m;
- GRPC_API_TRACE("grpc_server_register_method(server=%p, method=%s, host=%s)",
- 3, (server, method, host));
+ GRPC_API_TRACE(
+ "grpc_server_register_method(server=%p, method=%s, host=%s, "
+ "flags=0x%08x)",
+ 4, (server, method, host, flags));
if (!method) {
gpr_log(GPR_ERROR,
"grpc_server_register_method method string cannot be NULL");
@@ -846,12 +859,18 @@ void *grpc_server_register_method(grpc_server *server, const char *method,
return NULL;
}
}
+ if ((flags & ~GRPC_INITIAL_METADATA_USED_MASK) != 0) {
+ gpr_log(GPR_ERROR, "grpc_server_register_method invalid flags 0x%08x",
+ flags);
+ return NULL;
+ }
m = gpr_malloc(sizeof(registered_method));
memset(m, 0, sizeof(*m));
request_matcher_init(&m->request_matcher, server->max_requested_calls);
m->method = gpr_strdup(method);
m->host = gpr_strdup(host);
m->next = server->registered_methods;
+ m->flags = flags;
server->registered_methods = m;
return m;
}
@@ -930,6 +949,7 @@ void grpc_server_setup_transport(grpc_exec_ctx *exec_ctx, grpc_server *s,
if (probes > max_probes) max_probes = probes;
crm = &chand->registered_methods[(hash + probes) % slots];
crm->server_registered_method = rm;
+ crm->flags = rm->flags;
crm->host = host;
crm->method = method;
}
@@ -1247,6 +1267,10 @@ static void begin_call(grpc_exec_ctx *exec_ctx, grpc_server *server,
cpstr(&rc->data.batch.details->method,
&rc->data.batch.details->method_capacity, calld->path);
rc->data.batch.details->deadline = calld->deadline;
+ rc->data.batch.details->flags =
+ 0 | (calld->recv_idempotent_request
+ ? GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST
+ : 0);
break;
case REGISTERED_CALL:
*rc->data.registered.deadline = calld->deadline;
diff --git a/src/core/lib/transport/static_metadata.c b/src/core/lib/transport/static_metadata.c
index eda277b3dc..bde1fafc88 100644
--- a/src/core/lib/transport/static_metadata.c
+++ b/src/core/lib/transport/static_metadata.c
@@ -1,5 +1,4 @@
/*
- *
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
@@ -28,19 +27,16 @@
* 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.
- *
*/
/*
* WARNING: Auto-generated code.
*
* To make changes to this file, change
- * tools/codegen/core/gen_static_metadata.py,
- * and then re-run it.
+ * tools/codegen/core/gen_static_metadata.py, and then re-run it.
*
* See metadata.h for an explanation of the interface here, and metadata.c for
- * an
- * explanation of what's going on.
+ * an explanation of what's going on.
*/
#include "src/core/lib/transport/static_metadata.h"
@@ -52,7 +48,7 @@ uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 4, 8, 6, 2, 4, 8, 6, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
const uint8_t grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT * 2] =
{11, 35, 10, 35, 12, 35, 12, 49, 13, 35, 14, 35, 15, 35, 16, 35, 17, 35,
@@ -60,10 +56,10 @@ const uint8_t grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT * 2] =
30, 18, 30, 35, 31, 35, 32, 35, 36, 35, 37, 35, 38, 35, 39, 35, 42, 33,
42, 34, 42, 48, 42, 53, 42, 54, 42, 55, 42, 56, 43, 33, 43, 48, 43, 53,
46, 0, 46, 1, 46, 2, 50, 35, 57, 35, 58, 35, 59, 35, 60, 35, 61, 35,
- 62, 35, 63, 35, 64, 35, 65, 35, 66, 40, 66, 68, 67, 78, 67, 79, 69, 35,
- 70, 35, 71, 35, 72, 35, 73, 35, 74, 35, 75, 41, 75, 51, 75, 52, 76, 35,
- 77, 35, 80, 3, 80, 4, 80, 5, 80, 6, 80, 7, 80, 8, 80, 9, 81, 35,
- 82, 83, 84, 35, 85, 35, 86, 35, 87, 35, 88, 35};
+ 62, 35, 63, 35, 64, 35, 65, 35, 66, 40, 66, 68, 66, 71, 67, 79, 67, 80,
+ 69, 35, 70, 35, 72, 35, 73, 35, 74, 35, 75, 35, 76, 41, 76, 51, 76, 52,
+ 77, 35, 78, 35, 81, 3, 81, 4, 81, 5, 81, 6, 81, 7, 81, 8, 81, 9,
+ 82, 35, 83, 84, 85, 35, 86, 35, 87, 35, 88, 35, 89, 35};
const char *const grpc_static_metadata_strings[GRPC_STATIC_MDSTR_COUNT] = {
"0",
@@ -137,6 +133,7 @@ const char *const grpc_static_metadata_strings[GRPC_STATIC_MDSTR_COUNT] = {
"POST",
"proxy-authenticate",
"proxy-authorization",
+ "PUT",
"range",
"referer",
"refresh",
diff --git a/src/core/lib/transport/static_metadata.h b/src/core/lib/transport/static_metadata.h
index aff136a6d2..a05553a870 100644
--- a/src/core/lib/transport/static_metadata.h
+++ b/src/core/lib/transport/static_metadata.h
@@ -1,5 +1,4 @@
/*
- *
* Copyright 2015-2016, Google Inc.
* All rights reserved.
*
@@ -28,19 +27,16 @@
* 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.
- *
*/
/*
* WARNING: Auto-generated code.
*
* To make changes to this file, change
- * tools/codegen/core/gen_static_metadata.py,
- * and then re-run it.
+ * tools/codegen/core/gen_static_metadata.py, and then re-run it.
*
* See metadata.h for an explanation of the interface here, and metadata.c for
- * an
- * explanation of what's going on.
+ * an explanation of what's going on.
*/
#ifndef GRPC_CORE_LIB_TRANSPORT_STATIC_METADATA_H
@@ -48,7 +44,7 @@
#include "src/core/lib/transport/metadata.h"
-#define GRPC_STATIC_MDSTR_COUNT 89
+#define GRPC_STATIC_MDSTR_COUNT 90
extern grpc_mdstr grpc_static_mdstr_table[GRPC_STATIC_MDSTR_COUNT];
/* "0" */
#define GRPC_MDSTR_0 (&grpc_static_mdstr_table[0])
@@ -193,44 +189,46 @@ extern grpc_mdstr grpc_static_mdstr_table[GRPC_STATIC_MDSTR_COUNT];
#define GRPC_MDSTR_PROXY_AUTHENTICATE (&grpc_static_mdstr_table[69])
/* "proxy-authorization" */
#define GRPC_MDSTR_PROXY_AUTHORIZATION (&grpc_static_mdstr_table[70])
+/* "PUT" */
+#define GRPC_MDSTR_PUT (&grpc_static_mdstr_table[71])
/* "range" */
-#define GRPC_MDSTR_RANGE (&grpc_static_mdstr_table[71])
+#define GRPC_MDSTR_RANGE (&grpc_static_mdstr_table[72])
/* "referer" */
-#define GRPC_MDSTR_REFERER (&grpc_static_mdstr_table[72])
+#define GRPC_MDSTR_REFERER (&grpc_static_mdstr_table[73])
/* "refresh" */
-#define GRPC_MDSTR_REFRESH (&grpc_static_mdstr_table[73])
+#define GRPC_MDSTR_REFRESH (&grpc_static_mdstr_table[74])
/* "retry-after" */
-#define GRPC_MDSTR_RETRY_AFTER (&grpc_static_mdstr_table[74])
+#define GRPC_MDSTR_RETRY_AFTER (&grpc_static_mdstr_table[75])
/* ":scheme" */
-#define GRPC_MDSTR_SCHEME (&grpc_static_mdstr_table[75])
+#define GRPC_MDSTR_SCHEME (&grpc_static_mdstr_table[76])
/* "server" */
-#define GRPC_MDSTR_SERVER (&grpc_static_mdstr_table[76])
+#define GRPC_MDSTR_SERVER (&grpc_static_mdstr_table[77])
/* "set-cookie" */
-#define GRPC_MDSTR_SET_COOKIE (&grpc_static_mdstr_table[77])
+#define GRPC_MDSTR_SET_COOKIE (&grpc_static_mdstr_table[78])
/* "/" */
-#define GRPC_MDSTR_SLASH (&grpc_static_mdstr_table[78])
+#define GRPC_MDSTR_SLASH (&grpc_static_mdstr_table[79])
/* "/index.html" */
-#define GRPC_MDSTR_SLASH_INDEX_DOT_HTML (&grpc_static_mdstr_table[79])
+#define GRPC_MDSTR_SLASH_INDEX_DOT_HTML (&grpc_static_mdstr_table[80])
/* ":status" */
-#define GRPC_MDSTR_STATUS (&grpc_static_mdstr_table[80])
+#define GRPC_MDSTR_STATUS (&grpc_static_mdstr_table[81])
/* "strict-transport-security" */
-#define GRPC_MDSTR_STRICT_TRANSPORT_SECURITY (&grpc_static_mdstr_table[81])
+#define GRPC_MDSTR_STRICT_TRANSPORT_SECURITY (&grpc_static_mdstr_table[82])
/* "te" */
-#define GRPC_MDSTR_TE (&grpc_static_mdstr_table[82])
+#define GRPC_MDSTR_TE (&grpc_static_mdstr_table[83])
/* "trailers" */
-#define GRPC_MDSTR_TRAILERS (&grpc_static_mdstr_table[83])
+#define GRPC_MDSTR_TRAILERS (&grpc_static_mdstr_table[84])
/* "transfer-encoding" */
-#define GRPC_MDSTR_TRANSFER_ENCODING (&grpc_static_mdstr_table[84])
+#define GRPC_MDSTR_TRANSFER_ENCODING (&grpc_static_mdstr_table[85])
/* "user-agent" */
-#define GRPC_MDSTR_USER_AGENT (&grpc_static_mdstr_table[85])
+#define GRPC_MDSTR_USER_AGENT (&grpc_static_mdstr_table[86])
/* "vary" */
-#define GRPC_MDSTR_VARY (&grpc_static_mdstr_table[86])
+#define GRPC_MDSTR_VARY (&grpc_static_mdstr_table[87])
/* "via" */
-#define GRPC_MDSTR_VIA (&grpc_static_mdstr_table[87])
+#define GRPC_MDSTR_VIA (&grpc_static_mdstr_table[88])
/* "www-authenticate" */
-#define GRPC_MDSTR_WWW_AUTHENTICATE (&grpc_static_mdstr_table[88])
+#define GRPC_MDSTR_WWW_AUTHENTICATE (&grpc_static_mdstr_table[89])
-#define GRPC_STATIC_MDELEM_COUNT 78
+#define GRPC_STATIC_MDELEM_COUNT 79
extern grpc_mdelem grpc_static_mdelem_table[GRPC_STATIC_MDELEM_COUNT];
extern uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT];
/* "accept-charset": "" */
@@ -343,61 +341,63 @@ extern uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT];
#define GRPC_MDELEM_METHOD_GET (&grpc_static_mdelem_table[49])
/* ":method": "POST" */
#define GRPC_MDELEM_METHOD_POST (&grpc_static_mdelem_table[50])
+/* ":method": "PUT" */
+#define GRPC_MDELEM_METHOD_PUT (&grpc_static_mdelem_table[51])
/* ":path": "/" */
-#define GRPC_MDELEM_PATH_SLASH (&grpc_static_mdelem_table[51])
+#define GRPC_MDELEM_PATH_SLASH (&grpc_static_mdelem_table[52])
/* ":path": "/index.html" */
-#define GRPC_MDELEM_PATH_SLASH_INDEX_DOT_HTML (&grpc_static_mdelem_table[52])
+#define GRPC_MDELEM_PATH_SLASH_INDEX_DOT_HTML (&grpc_static_mdelem_table[53])
/* "proxy-authenticate": "" */
-#define GRPC_MDELEM_PROXY_AUTHENTICATE_EMPTY (&grpc_static_mdelem_table[53])
+#define GRPC_MDELEM_PROXY_AUTHENTICATE_EMPTY (&grpc_static_mdelem_table[54])
/* "proxy-authorization": "" */
-#define GRPC_MDELEM_PROXY_AUTHORIZATION_EMPTY (&grpc_static_mdelem_table[54])
+#define GRPC_MDELEM_PROXY_AUTHORIZATION_EMPTY (&grpc_static_mdelem_table[55])
/* "range": "" */
-#define GRPC_MDELEM_RANGE_EMPTY (&grpc_static_mdelem_table[55])
+#define GRPC_MDELEM_RANGE_EMPTY (&grpc_static_mdelem_table[56])
/* "referer": "" */
-#define GRPC_MDELEM_REFERER_EMPTY (&grpc_static_mdelem_table[56])
+#define GRPC_MDELEM_REFERER_EMPTY (&grpc_static_mdelem_table[57])
/* "refresh": "" */
-#define GRPC_MDELEM_REFRESH_EMPTY (&grpc_static_mdelem_table[57])
+#define GRPC_MDELEM_REFRESH_EMPTY (&grpc_static_mdelem_table[58])
/* "retry-after": "" */
-#define GRPC_MDELEM_RETRY_AFTER_EMPTY (&grpc_static_mdelem_table[58])
+#define GRPC_MDELEM_RETRY_AFTER_EMPTY (&grpc_static_mdelem_table[59])
/* ":scheme": "grpc" */
-#define GRPC_MDELEM_SCHEME_GRPC (&grpc_static_mdelem_table[59])
+#define GRPC_MDELEM_SCHEME_GRPC (&grpc_static_mdelem_table[60])
/* ":scheme": "http" */
-#define GRPC_MDELEM_SCHEME_HTTP (&grpc_static_mdelem_table[60])
+#define GRPC_MDELEM_SCHEME_HTTP (&grpc_static_mdelem_table[61])
/* ":scheme": "https" */
-#define GRPC_MDELEM_SCHEME_HTTPS (&grpc_static_mdelem_table[61])
+#define GRPC_MDELEM_SCHEME_HTTPS (&grpc_static_mdelem_table[62])
/* "server": "" */
-#define GRPC_MDELEM_SERVER_EMPTY (&grpc_static_mdelem_table[62])
+#define GRPC_MDELEM_SERVER_EMPTY (&grpc_static_mdelem_table[63])
/* "set-cookie": "" */
-#define GRPC_MDELEM_SET_COOKIE_EMPTY (&grpc_static_mdelem_table[63])
+#define GRPC_MDELEM_SET_COOKIE_EMPTY (&grpc_static_mdelem_table[64])
/* ":status": "200" */
-#define GRPC_MDELEM_STATUS_200 (&grpc_static_mdelem_table[64])
+#define GRPC_MDELEM_STATUS_200 (&grpc_static_mdelem_table[65])
/* ":status": "204" */
-#define GRPC_MDELEM_STATUS_204 (&grpc_static_mdelem_table[65])
+#define GRPC_MDELEM_STATUS_204 (&grpc_static_mdelem_table[66])
/* ":status": "206" */
-#define GRPC_MDELEM_STATUS_206 (&grpc_static_mdelem_table[66])
+#define GRPC_MDELEM_STATUS_206 (&grpc_static_mdelem_table[67])
/* ":status": "304" */
-#define GRPC_MDELEM_STATUS_304 (&grpc_static_mdelem_table[67])
+#define GRPC_MDELEM_STATUS_304 (&grpc_static_mdelem_table[68])
/* ":status": "400" */
-#define GRPC_MDELEM_STATUS_400 (&grpc_static_mdelem_table[68])
+#define GRPC_MDELEM_STATUS_400 (&grpc_static_mdelem_table[69])
/* ":status": "404" */
-#define GRPC_MDELEM_STATUS_404 (&grpc_static_mdelem_table[69])
+#define GRPC_MDELEM_STATUS_404 (&grpc_static_mdelem_table[70])
/* ":status": "500" */
-#define GRPC_MDELEM_STATUS_500 (&grpc_static_mdelem_table[70])
+#define GRPC_MDELEM_STATUS_500 (&grpc_static_mdelem_table[71])
/* "strict-transport-security": "" */
#define GRPC_MDELEM_STRICT_TRANSPORT_SECURITY_EMPTY \
- (&grpc_static_mdelem_table[71])
+ (&grpc_static_mdelem_table[72])
/* "te": "trailers" */
-#define GRPC_MDELEM_TE_TRAILERS (&grpc_static_mdelem_table[72])
+#define GRPC_MDELEM_TE_TRAILERS (&grpc_static_mdelem_table[73])
/* "transfer-encoding": "" */
-#define GRPC_MDELEM_TRANSFER_ENCODING_EMPTY (&grpc_static_mdelem_table[73])
+#define GRPC_MDELEM_TRANSFER_ENCODING_EMPTY (&grpc_static_mdelem_table[74])
/* "user-agent": "" */
-#define GRPC_MDELEM_USER_AGENT_EMPTY (&grpc_static_mdelem_table[74])
+#define GRPC_MDELEM_USER_AGENT_EMPTY (&grpc_static_mdelem_table[75])
/* "vary": "" */
-#define GRPC_MDELEM_VARY_EMPTY (&grpc_static_mdelem_table[75])
+#define GRPC_MDELEM_VARY_EMPTY (&grpc_static_mdelem_table[76])
/* "via": "" */
-#define GRPC_MDELEM_VIA_EMPTY (&grpc_static_mdelem_table[76])
+#define GRPC_MDELEM_VIA_EMPTY (&grpc_static_mdelem_table[77])
/* "www-authenticate": "" */
-#define GRPC_MDELEM_WWW_AUTHENTICATE_EMPTY (&grpc_static_mdelem_table[77])
+#define GRPC_MDELEM_WWW_AUTHENTICATE_EMPTY (&grpc_static_mdelem_table[78])
extern const uint8_t
grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT * 2];
diff --git a/src/core/lib/transport/transport.c b/src/core/lib/transport/transport.c
index 18256aae5e..411e4f140a 100644
--- a/src/core/lib/transport/transport.c
+++ b/src/core/lib/transport/transport.c
@@ -35,6 +35,7 @@
#include <grpc/support/alloc.h>
#include <grpc/support/atm.h>
#include <grpc/support/log.h>
+#include <grpc/support/sync.h>
#include "src/core/lib/transport/transport_impl.h"
#ifdef GRPC_STREAM_REFCOUNT_DEBUG
@@ -76,6 +77,24 @@ void grpc_stream_ref_init(grpc_stream_refcount *refcount, int initial_refs,
grpc_closure_init(&refcount->destroy, cb, cb_arg);
}
+static void move64(uint64_t *from, uint64_t *to) {
+ *to += *from;
+ *from = 0;
+}
+
+void grpc_transport_move_one_way_stats(grpc_transport_one_way_stats *from,
+ grpc_transport_one_way_stats *to) {
+ move64(&from->framing_bytes, &to->framing_bytes);
+ move64(&from->data_bytes, &to->data_bytes);
+ move64(&from->header_bytes, &to->header_bytes);
+}
+
+void grpc_transport_move_stats(grpc_transport_stream_stats *from,
+ grpc_transport_stream_stats *to) {
+ grpc_transport_move_one_way_stats(&from->incoming, &to->incoming);
+ grpc_transport_move_one_way_stats(&from->outgoing, &to->outgoing);
+}
+
size_t grpc_transport_stream_size(grpc_transport *transport) {
return transport->vtable->sizeof_stream;
}
diff --git a/src/core/lib/transport/transport.h b/src/core/lib/transport/transport.h
index e98cfe9515..6dd782c19e 100644
--- a/src/core/lib/transport/transport.h
+++ b/src/core/lib/transport/transport.h
@@ -78,11 +78,32 @@ void grpc_stream_unref(grpc_exec_ctx *exec_ctx, grpc_stream_refcount *refcount);
grpc_stream_ref_init(rc, ir, cb, cb_arg)
#endif
+typedef struct {
+ uint64_t framing_bytes;
+ uint64_t data_bytes;
+ uint64_t header_bytes;
+} grpc_transport_one_way_stats;
+
+typedef struct grpc_transport_stream_stats {
+ grpc_transport_one_way_stats incoming;
+ grpc_transport_one_way_stats outgoing;
+} grpc_transport_stream_stats;
+
+void grpc_transport_move_one_way_stats(grpc_transport_one_way_stats *from,
+ grpc_transport_one_way_stats *to);
+
+void grpc_transport_move_stats(grpc_transport_stream_stats *from,
+ grpc_transport_stream_stats *to);
+
/* Transport stream op: a set of operations to perform on a transport
against a single stream */
typedef struct grpc_transport_stream_op {
- /** Send initial metadata to the peer, from the provided metadata batch. */
+ /** Send initial metadata to the peer, from the provided metadata batch.
+ idempotent_request MUST be set if this is non-null */
grpc_metadata_batch *send_initial_metadata;
+ /** Iff send_initial_metadata != NULL, flags if this is an idempotent request
+ or not */
+ bool send_idempotent_request;
/** Send trailing metadata to the peer, from the provided metadata batch. */
grpc_metadata_batch *send_trailing_metadata;
@@ -92,6 +113,7 @@ typedef struct grpc_transport_stream_op {
/** Receive initial metadata from the stream, into provided metadata batch. */
grpc_metadata_batch *recv_initial_metadata;
+ bool *recv_idempotent_request;
/** Should be enqueued when initial metadata is ready to be processed. */
grpc_closure *recv_initial_metadata_ready;
@@ -104,6 +126,9 @@ typedef struct grpc_transport_stream_op {
*/
grpc_metadata_batch *recv_trailing_metadata;
+ /** Collect any stats into provided buffer, zero internal stat counters */
+ grpc_transport_stream_stats *collect_stats;
+
/** Should be enqueued when all requested operations (excluding recv_message
and recv_initial_metadata which have their own closures) in a given batch
have been completed. */
diff --git a/src/core/lib/client_config/lb_policies/pick_first.h b/src/core/plugin_registry/grpc_plugin_registry.c
index dba86ea7ad..3e3c214c22 100644
--- a/src/core/lib/client_config/lb_policies/pick_first.h
+++ b/src/core/plugin_registry/grpc_plugin_registry.c
@@ -1,6 +1,6 @@
/*
*
- * Copyright 2015-2016, Google Inc.
+ * Copyright 2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -31,13 +31,16 @@
*
*/
-#ifndef GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_PICK_FIRST_H
-#define GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_PICK_FIRST_H
+#include <grpc/grpc.h>
-#include "src/core/lib/client_config/lb_policy_factory.h"
+extern void grpc_lb_policy_pick_first_init(void);
+extern void grpc_lb_policy_pick_first_shutdown(void);
+extern void grpc_lb_policy_round_robin_init(void);
+extern void grpc_lb_policy_round_robin_shutdown(void);
-/** Returns a load balancing factory for the pick first policy, which picks up
- * the first subchannel from \a subchannels to succesfully connect */
-grpc_lb_policy_factory *grpc_pick_first_lb_factory_create();
-
-#endif /* GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_PICK_FIRST_H */
+void grpc_register_built_in_plugins(void) {
+ grpc_register_plugin(grpc_lb_policy_pick_first_init,
+ grpc_lb_policy_pick_first_shutdown);
+ grpc_register_plugin(grpc_lb_policy_round_robin_init,
+ grpc_lb_policy_round_robin_shutdown);
+}
diff --git a/src/core/lib/client_config/lb_policies/round_robin.h b/src/core/plugin_registry/grpc_unsecure_plugin_registry.c
index 52db1caa0c..3e3c214c22 100644
--- a/src/core/lib/client_config/lb_policies/round_robin.h
+++ b/src/core/plugin_registry/grpc_unsecure_plugin_registry.c
@@ -1,6 +1,6 @@
/*
*
- * Copyright 2015-2016, Google Inc.
+ * Copyright 2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -31,16 +31,16 @@
*
*/
-#ifndef GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_ROUND_ROBIN_H
-#define GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_ROUND_ROBIN_H
+#include <grpc/grpc.h>
-#include "src/core/lib/client_config/lb_policy.h"
+extern void grpc_lb_policy_pick_first_init(void);
+extern void grpc_lb_policy_pick_first_shutdown(void);
+extern void grpc_lb_policy_round_robin_init(void);
+extern void grpc_lb_policy_round_robin_shutdown(void);
-extern int grpc_lb_round_robin_trace;
-
-#include "src/core/lib/client_config/lb_policy_factory.h"
-
-/** Returns a load balancing factory for the round robin policy */
-grpc_lb_policy_factory *grpc_round_robin_lb_factory_create();
-
-#endif /* GRPC_CORE_LIB_CLIENT_CONFIG_LB_POLICIES_ROUND_ROBIN_H */
+void grpc_register_built_in_plugins(void) {
+ grpc_register_plugin(grpc_lb_policy_pick_first_init,
+ grpc_lb_policy_pick_first_shutdown);
+ grpc_register_plugin(grpc_lb_policy_round_robin_init,
+ grpc_lb_policy_round_robin_shutdown);
+}
diff --git a/src/cpp/server/server.cc b/src/cpp/server/server.cc
index 7e5f557ffa..5ec05e4dcc 100644
--- a/src/cpp/server/server.cc
+++ b/src/cpp/server/server.cc
@@ -264,6 +264,7 @@ class Server::SyncRequest GRPC_FINAL : public CompletionQueueTag {
void* const tag_;
bool in_flight_;
const bool has_request_payload_;
+ uint32_t incoming_flags_;
grpc_call* call_;
grpc_call_details* call_details_;
gpr_timespec deadline_;
@@ -334,7 +335,7 @@ bool Server::RegisterService(const grpc::string* host, Service* service) {
}
RpcServiceMethod* method = it->get();
void* tag = grpc_server_register_method(server_, method->name(),
- host ? host->c_str() : nullptr);
+ host ? host->c_str() : nullptr, 0);
if (tag == nullptr) {
gpr_log(GPR_DEBUG, "Attempt to register %s multiple times",
method->name());
diff --git a/src/python/grpcio/grpc/_cython/imports.generated.h b/src/python/grpcio/grpc/_cython/imports.generated.h
index 4d18369e1f..adcd8e954a 100644
--- a/src/python/grpcio/grpc/_cython/imports.generated.h
+++ b/src/python/grpcio/grpc/_cython/imports.generated.h
@@ -283,7 +283,7 @@ extern grpc_call_destroy_type grpc_call_destroy_import;
typedef grpc_call_error(*grpc_server_request_call_type)(grpc_server *server, grpc_call **call, grpc_call_details *details, grpc_metadata_array *request_metadata, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new);
extern grpc_server_request_call_type grpc_server_request_call_import;
#define grpc_server_request_call grpc_server_request_call_import
-typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host);
+typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host, uint32_t flags);
extern grpc_server_register_method_type grpc_server_register_method_import;
#define grpc_server_register_method grpc_server_register_method_import
typedef grpc_call_error(*grpc_server_request_registered_call_type)(grpc_server *server, void *registered_method, grpc_call **call, gpr_timespec *deadline, grpc_metadata_array *request_metadata, grpc_byte_buffer **optional_payload, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new);
diff --git a/src/python/grpcio/grpc_core_dependencies.py b/src/python/grpcio/grpc_core_dependencies.py
index 98890488ec..137ce16277 100644
--- a/src/python/grpcio/grpc_core_dependencies.py
+++ b/src/python/grpcio/grpc_core_dependencies.py
@@ -74,6 +74,10 @@ CORE_SOURCE_FILES = [
'src/core/lib/support/tmpfile_posix.c',
'src/core/lib/support/tmpfile_win32.c',
'src/core/lib/support/wrap_memcpy.c',
+ 'src/core/ext/lb_policy/grpclb/load_balancer_api.c',
+ 'src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c',
+ 'src/core/ext/lb_policy/pick_first/pick_first.c',
+ 'src/core/ext/lb_policy/round_robin/round_robin.c',
'src/core/ext/transport/chttp2/client/insecure/channel_create.c',
'src/core/ext/transport/chttp2/client/secure/secure_channel_create.c',
'src/core/ext/transport/chttp2/server/insecure/server_chttp2.c',
@@ -121,9 +125,6 @@ CORE_SOURCE_FILES = [
'src/core/lib/client_config/connector.c',
'src/core/lib/client_config/default_initial_connect_string.c',
'src/core/lib/client_config/initial_connect_string.c',
- 'src/core/lib/client_config/lb_policies/load_balancer_api.c',
- 'src/core/lib/client_config/lb_policies/pick_first.c',
- 'src/core/lib/client_config/lb_policies/round_robin.c',
'src/core/lib/client_config/lb_policy.c',
'src/core/lib/client_config/lb_policy_factory.c',
'src/core/lib/client_config/lb_policy_registry.c',
@@ -187,7 +188,6 @@ CORE_SOURCE_FILES = [
'src/core/lib/json/json_reader.c',
'src/core/lib/json/json_string.c',
'src/core/lib/json/json_writer.c',
- 'src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c',
'src/core/lib/security/b64.c',
'src/core/lib/security/client_auth_filter.c',
'src/core/lib/security/credentials.c',
@@ -233,6 +233,7 @@ CORE_SOURCE_FILES = [
'src/core/lib/tsi/fake_transport_security.c',
'src/core/lib/tsi/ssl_transport_security.c',
'src/core/lib/tsi/transport_security.c',
+ 'src/core/plugin_registry/grpc_plugin_registry.c',
'third_party/nanopb/pb_common.c',
'third_party/nanopb/pb_decode.c',
'third_party/nanopb/pb_encode.c',
diff --git a/src/python/grpcio/precompiled.py b/src/python/grpcio/precompiled.py
index d34250b02c..aeeb2754ea 100644
--- a/src/python/grpcio/precompiled.py
+++ b/src/python/grpcio/precompiled.py
@@ -91,6 +91,9 @@ class BuildTaggedExt(setuptools.Command):
def update_setup_arguments(setup_arguments):
+ if not USE_PRECOMPILED_BINARIES:
+ sys.stderr.write('not using precompiled extension')
+ return
url = '{}/{}.so'.format(BINARIES_REPOSITORY, _tagged_ext_name('cygrpc'))
target_path = os.path.join(PYTHON_STEM, 'grpc/_cython/cygrpc.so')
try:
diff --git a/src/ruby/ext/grpc/rb_grpc_imports.generated.h b/src/ruby/ext/grpc/rb_grpc_imports.generated.h
index 3bf81af8fb..22ea84c750 100644
--- a/src/ruby/ext/grpc/rb_grpc_imports.generated.h
+++ b/src/ruby/ext/grpc/rb_grpc_imports.generated.h
@@ -283,7 +283,7 @@ extern grpc_call_destroy_type grpc_call_destroy_import;
typedef grpc_call_error(*grpc_server_request_call_type)(grpc_server *server, grpc_call **call, grpc_call_details *details, grpc_metadata_array *request_metadata, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new);
extern grpc_server_request_call_type grpc_server_request_call_import;
#define grpc_server_request_call grpc_server_request_call_import
-typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host);
+typedef void *(*grpc_server_register_method_type)(grpc_server *server, const char *method, const char *host, uint32_t flags);
extern grpc_server_register_method_type grpc_server_register_method_import;
#define grpc_server_register_method grpc_server_register_method_import
typedef grpc_call_error(*grpc_server_request_registered_call_type)(grpc_server *server, void *registered_method, grpc_call **call, gpr_timespec *deadline, grpc_metadata_array *request_metadata, grpc_byte_buffer **optional_payload, grpc_completion_queue *cq_bound_to_call, grpc_completion_queue *cq_for_notification, void *tag_new);
diff --git a/templates/src/core/plugin_registry.template b/templates/src/core/plugin_registry.template
new file mode 100644
index 0000000000..352682c3f0
--- /dev/null
+++ b/templates/src/core/plugin_registry.template
@@ -0,0 +1,52 @@
+%YAML 1.2
+---
+foreach: libs
+cond: selected.get('generate_plugin_registry', False)
+output_name: ${selected.name}_plugin_registry.c
+template: |
+ /*
+ *
+ * Copyright 2016, Google Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+ #include <grpc/grpc.h>
+
+ %for plugin in selected.plugins:
+ extern void ${plugin}_init(void);
+ extern void ${plugin}_shutdown(void);
+ %endfor
+
+ void grpc_register_built_in_plugins(void) {
+ %for plugin in selected.plugins:
+ grpc_register_plugin(${plugin}_init,
+ ${plugin}_shutdown);
+ %endfor
+ }
diff --git a/test/core/bad_client/bad_client.c b/test/core/bad_client/bad_client.c
index 7fd7a00c81..d385cab372 100644
--- a/test/core/bad_client/bad_client.c
+++ b/test/core/bad_client/bad_client.c
@@ -33,6 +33,9 @@
#include "test/core/bad_client/bad_client.h"
+#include <grpc/support/alloc.h>
+#include <grpc/support/sync.h>
+#include <grpc/support/thd.h>
#include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
#include "src/core/lib/channel/channel_stack.h"
#include "src/core/lib/channel/http_server_filter.h"
@@ -41,10 +44,6 @@
#include "src/core/lib/surface/completion_queue.h"
#include "src/core/lib/surface/server.h"
-#include <grpc/support/alloc.h>
-#include <grpc/support/sync.h>
-#include <grpc/support/thd.h>
-
typedef struct {
grpc_server *server;
grpc_completion_queue *cq;
@@ -110,7 +109,7 @@ void grpc_run_bad_client_test(grpc_bad_client_server_side_validator validator,
grpc_server_register_completion_queue(a.server, a.cq, NULL);
a.registered_method =
grpc_server_register_method(a.server, GRPC_BAD_CLIENT_REGISTERED_METHOD,
- GRPC_BAD_CLIENT_REGISTERED_HOST);
+ GRPC_BAD_CLIENT_REGISTERED_HOST, 0);
grpc_server_start(a.server);
transport = grpc_create_chttp2_transport(&exec_ctx, NULL, sfd.server, 0);
server_setup_transport(&a, transport);
diff --git a/test/core/client_config/lb_policies_test.c b/test/core/client_config/lb_policies_test.c
index bc7040de77..ac42891f94 100644
--- a/test/core/client_config/lb_policies_test.c
+++ b/test/core/client_config/lb_policies_test.c
@@ -43,7 +43,6 @@
#include "src/core/lib/channel/channel_stack.h"
#include "src/core/lib/channel/client_channel.h"
-#include "src/core/lib/client_config/lb_policies/round_robin.h"
#include "src/core/lib/client_config/lb_policy_registry.h"
#include "src/core/lib/support/string.h"
#include "src/core/lib/surface/channel.h"
@@ -881,7 +880,7 @@ int main(int argc, char **argv) {
grpc_test_init(argc, argv);
grpc_init();
- grpc_lb_round_robin_trace = 1;
+ grpc_tracer_set_enabled("round_robin", 1);
GPR_ASSERT(grpc_lb_policy_create(&exec_ctx, "this-lb-policy-does-not-exist",
NULL) == NULL);
diff --git a/test/core/end2end/end2end_nosec_tests.c b/test/core/end2end/end2end_nosec_tests.c
index b8934512c6..f560900a25 100644
--- a/test/core/end2end/end2end_nosec_tests.c
+++ b/test/core/end2end/end2end_nosec_tests.c
@@ -56,6 +56,7 @@ extern void empty_batch(grpc_end2end_test_config config);
extern void graceful_server_shutdown(grpc_end2end_test_config config);
extern void high_initial_seqno(grpc_end2end_test_config config);
extern void hpack_size(grpc_end2end_test_config config);
+extern void idempotent_request(grpc_end2end_test_config config);
extern void invoke_large_request(grpc_end2end_test_config config);
extern void large_metadata(grpc_end2end_test_config config);
extern void max_concurrent_streams(grpc_end2end_test_config config);
@@ -97,6 +98,7 @@ void grpc_end2end_tests(int argc, char **argv,
graceful_server_shutdown(config);
high_initial_seqno(config);
hpack_size(config);
+ idempotent_request(config);
invoke_large_request(config);
large_metadata(config);
max_concurrent_streams(config);
@@ -184,6 +186,10 @@ void grpc_end2end_tests(int argc, char **argv,
hpack_size(config);
continue;
}
+ if (0 == strcmp("idempotent_request", argv[i])) {
+ idempotent_request(config);
+ continue;
+ }
if (0 == strcmp("invoke_large_request", argv[i])) {
invoke_large_request(config);
continue;
diff --git a/test/core/end2end/end2end_tests.c b/test/core/end2end/end2end_tests.c
index f0969794c6..f191c3a20d 100644
--- a/test/core/end2end/end2end_tests.c
+++ b/test/core/end2end/end2end_tests.c
@@ -57,6 +57,7 @@ extern void empty_batch(grpc_end2end_test_config config);
extern void graceful_server_shutdown(grpc_end2end_test_config config);
extern void high_initial_seqno(grpc_end2end_test_config config);
extern void hpack_size(grpc_end2end_test_config config);
+extern void idempotent_request(grpc_end2end_test_config config);
extern void invoke_large_request(grpc_end2end_test_config config);
extern void large_metadata(grpc_end2end_test_config config);
extern void max_concurrent_streams(grpc_end2end_test_config config);
@@ -99,6 +100,7 @@ void grpc_end2end_tests(int argc, char **argv,
graceful_server_shutdown(config);
high_initial_seqno(config);
hpack_size(config);
+ idempotent_request(config);
invoke_large_request(config);
large_metadata(config);
max_concurrent_streams(config);
@@ -190,6 +192,10 @@ void grpc_end2end_tests(int argc, char **argv,
hpack_size(config);
continue;
}
+ if (0 == strcmp("idempotent_request", argv[i])) {
+ idempotent_request(config);
+ continue;
+ }
if (0 == strcmp("invoke_large_request", argv[i])) {
invoke_large_request(config);
continue;
diff --git a/test/core/end2end/fixtures/proxy.c b/test/core/end2end/fixtures/proxy.c
index 434e75dd15..1ca53cdad9 100644
--- a/test/core/end2end/fixtures/proxy.c
+++ b/test/core/end2end/fixtures/proxy.c
@@ -1,6 +1,6 @@
/*
*
- * Copyright 2015, Google Inc.
+ * Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -338,10 +338,10 @@ static void on_new_call(void *arg, int success) {
proxy->new_call_details.deadline, NULL);
gpr_ref_init(&pc->refs, 1);
- op.flags = 0;
op.reserved = NULL;
op.op = GRPC_OP_RECV_INITIAL_METADATA;
+ op.flags = 0;
op.data.recv_initial_metadata = &pc->p2s_initial_metadata;
refpc(pc, "on_p2s_recv_initial_metadata");
err = grpc_call_start_batch(
@@ -349,6 +349,7 @@ static void on_new_call(void *arg, int success) {
GPR_ASSERT(err == GRPC_CALL_OK);
op.op = GRPC_OP_SEND_INITIAL_METADATA;
+ op.flags = proxy->new_call_details.flags;
op.data.send_initial_metadata.count = pc->c2p_initial_metadata.count;
op.data.send_initial_metadata.metadata = pc->c2p_initial_metadata.metadata;
refpc(pc, "on_p2s_sent_initial_metadata");
@@ -357,6 +358,7 @@ static void on_new_call(void *arg, int success) {
GPR_ASSERT(err == GRPC_CALL_OK);
op.op = GRPC_OP_RECV_MESSAGE;
+ op.flags = 0;
op.data.recv_message = &pc->c2p_msg;
refpc(pc, "on_c2p_recv_msg");
err = grpc_call_start_batch(pc->c2p, &op, 1,
@@ -364,6 +366,7 @@ static void on_new_call(void *arg, int success) {
GPR_ASSERT(err == GRPC_CALL_OK);
op.op = GRPC_OP_RECV_MESSAGE;
+ op.flags = 0;
op.data.recv_message = &pc->p2s_msg;
refpc(pc, "on_p2s_recv_msg");
err = grpc_call_start_batch(pc->p2s, &op, 1,
@@ -371,6 +374,7 @@ static void on_new_call(void *arg, int success) {
GPR_ASSERT(err == GRPC_CALL_OK);
op.op = GRPC_OP_RECV_STATUS_ON_CLIENT;
+ op.flags = 0;
op.data.recv_status_on_client.trailing_metadata =
&pc->p2s_trailing_metadata;
op.data.recv_status_on_client.status = &pc->p2s_status;
@@ -383,6 +387,7 @@ static void on_new_call(void *arg, int success) {
GPR_ASSERT(err == GRPC_CALL_OK);
op.op = GRPC_OP_RECV_CLOSE_ON_SERVER;
+ op.flags = 0;
op.data.recv_close_on_server.cancelled = &pc->c2p_server_cancelled;
refpc(pc, "on_c2p_closed");
err = grpc_call_start_batch(pc->c2p, &op, 1, new_closure(on_c2p_closed, pc),
diff --git a/test/core/end2end/gen_build_yaml.py b/test/core/end2end/gen_build_yaml.py
index adf2b3c8d9..30dbc4346e 100755
--- a/test/core/end2end/gen_build_yaml.py
+++ b/test/core/end2end/gen_build_yaml.py
@@ -98,6 +98,7 @@ END2END_TESTS = {
'hpack_size': default_test_options._replace(proxyable=False,
traceable=False),
'high_initial_seqno': default_test_options,
+ 'idempotent_request': default_test_options,
'invoke_large_request': default_test_options,
'large_metadata': default_test_options,
'max_concurrent_streams': default_test_options._replace(proxyable=False),
diff --git a/test/core/end2end/tests/idempotent_request.c b/test/core/end2end/tests/idempotent_request.c
new file mode 100644
index 0000000000..485a854441
--- /dev/null
+++ b/test/core/end2end/tests/idempotent_request.c
@@ -0,0 +1,248 @@
+/*
+ *
+ * Copyright 2015-2016, Google Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+#include "test/core/end2end/end2end_tests.h"
+
+#include <stdio.h>
+#include <string.h>
+
+#include <grpc/byte_buffer.h>
+#include <grpc/grpc.h>
+#include <grpc/support/alloc.h>
+#include <grpc/support/log.h>
+#include <grpc/support/time.h>
+#include <grpc/support/useful.h>
+#include "src/core/lib/support/string.h"
+#include "test/core/end2end/cq_verifier.h"
+
+enum { TIMEOUT = 200000 };
+
+static void *tag(intptr_t t) { return (void *)t; }
+
+static grpc_end2end_test_fixture begin_test(grpc_end2end_test_config config,
+ const char *test_name,
+ grpc_channel_args *client_args,
+ grpc_channel_args *server_args) {
+ grpc_end2end_test_fixture f;
+ 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);
+ return f;
+}
+
+static gpr_timespec n_seconds_time(int n) {
+ return GRPC_TIMEOUT_SECONDS_TO_DEADLINE(n);
+}
+
+static gpr_timespec five_seconds_time(void) { return n_seconds_time(5); }
+
+static void drain_cq(grpc_completion_queue *cq) {
+ grpc_event ev;
+ do {
+ ev = grpc_completion_queue_next(cq, five_seconds_time(), NULL);
+ } while (ev.type != GRPC_QUEUE_SHUTDOWN);
+}
+
+static void shutdown_server(grpc_end2end_test_fixture *f) {
+ if (!f->server) return;
+ grpc_server_shutdown_and_notify(f->server, f->cq, tag(1000));
+ GPR_ASSERT(grpc_completion_queue_pluck(
+ f->cq, tag(1000), GRPC_TIMEOUT_SECONDS_TO_DEADLINE(5), NULL)
+ .type == GRPC_OP_COMPLETE);
+ grpc_server_destroy(f->server);
+ f->server = NULL;
+}
+
+static void shutdown_client(grpc_end2end_test_fixture *f) {
+ if (!f->client) return;
+ grpc_channel_destroy(f->client);
+ f->client = NULL;
+}
+
+static void end_test(grpc_end2end_test_fixture *f) {
+ shutdown_server(f);
+ shutdown_client(f);
+
+ grpc_completion_queue_shutdown(f->cq);
+ drain_cq(f->cq);
+ grpc_completion_queue_destroy(f->cq);
+}
+
+static void simple_request_body(grpc_end2end_test_fixture f) {
+ grpc_call *c;
+ grpc_call *s;
+ gpr_timespec deadline = five_seconds_time();
+ cq_verifier *cqv = cq_verifier_create(f.cq);
+ grpc_op ops[6];
+ grpc_op *op;
+ grpc_metadata_array initial_metadata_recv;
+ grpc_metadata_array trailing_metadata_recv;
+ grpc_metadata_array request_metadata_recv;
+ grpc_call_details call_details;
+ grpc_status_code status;
+ grpc_call_error error;
+ char *details = NULL;
+ size_t details_capacity = 0;
+ int was_cancelled = 2;
+ char *peer;
+
+ c = grpc_channel_create_call(f.client, NULL, GRPC_PROPAGATE_DEFAULTS, f.cq,
+ "/foo", "foo.test.google.fr:1234", deadline,
+ NULL);
+ GPR_ASSERT(c);
+
+ peer = grpc_call_get_peer(c);
+ GPR_ASSERT(peer != NULL);
+ gpr_log(GPR_DEBUG, "client_peer_before_call=%s", peer);
+ gpr_free(peer);
+
+ grpc_metadata_array_init(&initial_metadata_recv);
+ grpc_metadata_array_init(&trailing_metadata_recv);
+ grpc_metadata_array_init(&request_metadata_recv);
+ grpc_call_details_init(&call_details);
+
+ op = ops;
+ op->op = GRPC_OP_SEND_INITIAL_METADATA;
+ op->data.send_initial_metadata.count = 0;
+ op->flags = GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST;
+ op->reserved = NULL;
+ op++;
+ op->op = GRPC_OP_SEND_CLOSE_FROM_CLIENT;
+ op->flags = 0;
+ op->reserved = NULL;
+ op++;
+ op->op = GRPC_OP_RECV_INITIAL_METADATA;
+ op->data.recv_initial_metadata = &initial_metadata_recv;
+ op->flags = 0;
+ op->reserved = NULL;
+ op++;
+ op->op = GRPC_OP_RECV_STATUS_ON_CLIENT;
+ op->data.recv_status_on_client.trailing_metadata = &trailing_metadata_recv;
+ op->data.recv_status_on_client.status = &status;
+ op->data.recv_status_on_client.status_details = &details;
+ op->data.recv_status_on_client.status_details_capacity = &details_capacity;
+ op->flags = 0;
+ op->reserved = NULL;
+ op++;
+ error = grpc_call_start_batch(c, ops, (size_t)(op - ops), tag(1), NULL);
+ GPR_ASSERT(GRPC_CALL_OK == error);
+
+ error =
+ grpc_server_request_call(f.server, &s, &call_details,
+ &request_metadata_recv, f.cq, f.cq, tag(101));
+ GPR_ASSERT(GRPC_CALL_OK == error);
+ cq_expect_completion(cqv, tag(101), 1);
+ cq_verify(cqv);
+
+ peer = grpc_call_get_peer(s);
+ GPR_ASSERT(peer != NULL);
+ gpr_log(GPR_DEBUG, "server_peer=%s", peer);
+ gpr_free(peer);
+ peer = grpc_call_get_peer(c);
+ GPR_ASSERT(peer != NULL);
+ gpr_log(GPR_DEBUG, "client_peer=%s", peer);
+ gpr_free(peer);
+
+ op = ops;
+ op->op = GRPC_OP_SEND_INITIAL_METADATA;
+ op->data.send_initial_metadata.count = 0;
+ op->flags = 0;
+ op->reserved = NULL;
+ op++;
+ op->op = GRPC_OP_SEND_STATUS_FROM_SERVER;
+ op->data.send_status_from_server.trailing_metadata_count = 0;
+ op->data.send_status_from_server.status = GRPC_STATUS_UNIMPLEMENTED;
+ op->data.send_status_from_server.status_details = "xyz";
+ op->flags = 0;
+ op->reserved = NULL;
+ op++;
+ op->op = GRPC_OP_RECV_CLOSE_ON_SERVER;
+ op->data.recv_close_on_server.cancelled = &was_cancelled;
+ op->flags = 0;
+ op->reserved = NULL;
+ op++;
+ error = grpc_call_start_batch(s, ops, (size_t)(op - ops), tag(102), NULL);
+ GPR_ASSERT(GRPC_CALL_OK == error);
+
+ cq_expect_completion(cqv, tag(102), 1);
+ cq_expect_completion(cqv, tag(1), 1);
+ cq_verify(cqv);
+
+ GPR_ASSERT(status == GRPC_STATUS_UNIMPLEMENTED);
+ GPR_ASSERT(0 == strcmp(details, "xyz"));
+ GPR_ASSERT(0 == strcmp(call_details.method, "/foo"));
+ GPR_ASSERT(0 == strcmp(call_details.host, "foo.test.google.fr:1234"));
+ GPR_ASSERT(GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST == call_details.flags);
+ GPR_ASSERT(was_cancelled == 1);
+
+ gpr_free(details);
+ grpc_metadata_array_destroy(&initial_metadata_recv);
+ grpc_metadata_array_destroy(&trailing_metadata_recv);
+ grpc_metadata_array_destroy(&request_metadata_recv);
+ grpc_call_details_destroy(&call_details);
+
+ grpc_call_destroy(c);
+ grpc_call_destroy(s);
+
+ cq_verifier_destroy(cqv);
+}
+
+static void test_invoke_simple_request(grpc_end2end_test_config config) {
+ grpc_end2end_test_fixture f;
+
+ f = begin_test(config, "test_invoke_simple_request", NULL, NULL);
+ simple_request_body(f);
+ end_test(&f);
+ config.tear_down_data(&f);
+}
+
+static void test_invoke_10_simple_requests(grpc_end2end_test_config config) {
+ int i;
+ grpc_end2end_test_fixture f =
+ begin_test(config, "test_invoke_10_simple_requests", NULL, NULL);
+ for (i = 0; i < 10; i++) {
+ simple_request_body(f);
+ gpr_log(GPR_INFO, "Passed simple request %d", i);
+ }
+ end_test(&f);
+ config.tear_down_data(&f);
+}
+
+void idempotent_request(grpc_end2end_test_config config) {
+ int i;
+ for (i = 0; i < 10; i++) {
+ test_invoke_simple_request(config);
+ }
+ test_invoke_10_simple_requests(config);
+}
diff --git a/test/core/end2end/tests/simple_request.c b/test/core/end2end/tests/simple_request.c
index bc634ef83a..d75c5594a9 100644
--- a/test/core/end2end/tests/simple_request.c
+++ b/test/core/end2end/tests/simple_request.c
@@ -203,6 +203,7 @@ static void simple_request_body(grpc_end2end_test_fixture f) {
GPR_ASSERT(0 == strcmp(details, "xyz"));
GPR_ASSERT(0 == strcmp(call_details.method, "/foo"));
GPR_ASSERT(0 == strcmp(call_details.host, "foo.test.google.fr:1234"));
+ GPR_ASSERT(0 == call_details.flags);
GPR_ASSERT(was_cancelled == 1);
gpr_free(details);
diff --git a/test/core/internal_api_canaries/iomgr.c b/test/core/internal_api_canaries/iomgr.c
new file mode 100644
index 0000000000..04d66994cd
--- /dev/null
+++ b/test/core/internal_api_canaries/iomgr.c
@@ -0,0 +1,115 @@
+/*
+ *
+ * Copyright 2015-2016, Google Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+#include "src/core/lib/iomgr/iomgr.h"
+#include "src/core/lib/iomgr/closure.h"
+#include "src/core/lib/iomgr/endpoint.h"
+#include "src/core/lib/iomgr/exec_ctx.h"
+#include "src/core/lib/iomgr/executor.h"
+
+/*******************************************************************************
+ * NOTE: If this test fails to compile, then the api changes are likely to cause
+ * merge failures downstream. Please pay special attention to reviewing
+ * these changes, and solicit help as appropriate when merging downstream.
+ *
+ * This test is NOT expected to be run directly.
+ ******************************************************************************/
+
+static void test_code(void) {
+ /* iomgr.h */
+ grpc_iomgr_init();
+ grpc_iomgr_shutdown();
+
+ /* closure.h */
+ grpc_closure closure;
+ closure.cb = NULL;
+ closure.cb_arg = NULL;
+ closure.final_data = 0;
+
+ grpc_closure_list closure_list = GRPC_CLOSURE_LIST_INIT;
+ closure_list.head = NULL;
+ closure_list.tail = NULL;
+
+ grpc_closure_init(&closure, NULL, NULL);
+
+ grpc_closure_create(NULL, NULL);
+
+ grpc_closure_list_move(NULL, NULL);
+ grpc_closure_list_add(NULL, NULL, true);
+ bool x = grpc_closure_list_empty(closure_list);
+ grpc_closure_next(&closure);
+
+ /* exec_ctx.h */
+ grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT;
+ grpc_exec_ctx_flush(&exec_ctx);
+ grpc_exec_ctx_finish(&exec_ctx);
+ grpc_exec_ctx_enqueue(&exec_ctx, &closure, x, NULL);
+ grpc_exec_ctx_enqueue_list(&exec_ctx, &closure_list, NULL);
+
+ /* endpoint.h */
+ grpc_endpoint endpoint;
+ grpc_endpoint_vtable vtable = {
+ grpc_endpoint_read, grpc_endpoint_write,
+ grpc_endpoint_add_to_pollset, grpc_endpoint_add_to_pollset_set,
+ grpc_endpoint_shutdown, grpc_endpoint_destroy,
+ grpc_endpoint_get_peer};
+ endpoint.vtable = &vtable;
+
+ grpc_endpoint_read(&exec_ctx, &endpoint, NULL, NULL);
+ grpc_endpoint_get_peer(&endpoint);
+ grpc_endpoint_write(&exec_ctx, &endpoint, NULL, NULL);
+ grpc_endpoint_shutdown(&exec_ctx, &endpoint);
+ grpc_endpoint_destroy(&exec_ctx, &endpoint);
+ grpc_endpoint_add_to_pollset(&exec_ctx, &endpoint, NULL);
+ grpc_endpoint_add_to_pollset_set(&exec_ctx, &endpoint, NULL);
+
+ /* executor.h */
+ grpc_executor_init();
+ grpc_executor_enqueue(&closure, x);
+ grpc_executor_shutdown();
+
+ /* pollset.h */
+ grpc_pollset_size();
+ grpc_pollset_init(NULL, NULL);
+ grpc_pollset_shutdown(NULL, NULL, NULL);
+ grpc_pollset_reset(NULL);
+ grpc_pollset_destroy(NULL);
+ grpc_pollset_work(NULL, NULL, NULL, gpr_now(GPR_CLOCK_REALTIME),
+ gpr_now(GPR_CLOCK_MONOTONIC));
+ grpc_pollset_kick(NULL, NULL);
+}
+
+int main(void) {
+ if (false) test_code();
+ return 0;
+}
diff --git a/test/core/internal_api_canaries/support.c b/test/core/internal_api_canaries/support.c
new file mode 100644
index 0000000000..7e00e0d2ff
--- /dev/null
+++ b/test/core/internal_api_canaries/support.c
@@ -0,0 +1,58 @@
+/*
+ *
+ * Copyright 2015-2016, Google Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+/*******************************************************************************
+ * NOTE: If this test fails to compile, then the api changes are likely to cause
+ * merge failures downstream. Please pay special attention to reviewing
+ * these changes, and solicit help as appropriate when merging downstream.
+ *
+ * This test is NOT expected to be run directly.
+ ******************************************************************************/
+
+#include "src/core/lib/support/env.h"
+#include "src/core/lib/support/load_file.h"
+#include "src/core/lib/support/tmpfile.h"
+
+static void test_code(void) {
+ /* env.h */
+ gpr_set_env("abc", gpr_getenv("xyz"));
+ /* load_file.h */
+ gpr_load_file("abc", 1, NULL);
+ /* tmpfile.h */
+ fclose(gpr_tmpfile("foo", NULL));
+}
+
+int main(void) {
+ if (false) test_code();
+ return 0;
+}
diff --git a/test/core/internal_api_canaries/transport.c b/test/core/internal_api_canaries/transport.c
new file mode 100644
index 0000000000..01daabaa56
--- /dev/null
+++ b/test/core/internal_api_canaries/transport.c
@@ -0,0 +1,81 @@
+/*
+ *
+ * Copyright 2015-2016, Google Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ */
+
+/*******************************************************************************
+ * NOTE: If this test fails to compile, then the api changes are likely to cause
+ * merge failures downstream. Please pay special attention to reviewing
+ * these changes, and solicit help as appropriate when merging downstream.
+ *
+ * This test is NOT expected to be run directly.
+ ******************************************************************************/
+
+#include "src/core/lib/transport/transport.h"
+#include "src/core/lib/transport/transport_impl.h"
+
+static void test_code(void) {
+ /* transport_impl.h */
+ grpc_transport transport;
+ grpc_transport_vtable vtable = {12345,
+ grpc_transport_init_stream,
+ grpc_transport_set_pollset,
+ grpc_transport_perform_stream_op,
+ grpc_transport_perform_op,
+ grpc_transport_destroy_stream,
+ grpc_transport_destroy,
+ grpc_transport_get_peer};
+ transport.vtable = &vtable;
+
+ /* transport.h */
+ GRPC_STREAM_REF_INIT(NULL, 0, NULL, NULL, "xyz");
+ GPR_ASSERT(0 == grpc_transport_stream_size(NULL));
+ GPR_ASSERT(grpc_transport_init_stream(&transport, NULL, NULL, NULL, NULL));
+ grpc_transport_set_pollset(&transport, NULL, NULL, NULL);
+ grpc_transport_destroy_stream(&transport, NULL, NULL);
+ grpc_transport_stream_op_finish_with_failure(NULL, NULL);
+ grpc_transport_stream_op_add_cancellation(NULL, GRPC_STATUS_UNAVAILABLE);
+ grpc_transport_stream_op_add_close(NULL, GRPC_STATUS_UNAVAILABLE,
+ grpc_transport_op_string(NULL));
+ grpc_transport_perform_stream_op(&transport, NULL, NULL, NULL);
+ grpc_transport_perform_op(&transport, NULL, NULL);
+ grpc_transport_ping(&transport, NULL);
+ grpc_transport_goaway(&transport, GRPC_STATUS_UNAVAILABLE,
+ gpr_slice_malloc(0));
+ grpc_transport_close(&transport);
+ grpc_transport_destroy(&transport, NULL);
+ GPR_ASSERT("xyz" == grpc_transport_get_peer(&transport, NULL));
+}
+
+int main(void) {
+ if (false) test_code();
+ return 0;
+}
diff --git a/test/core/iomgr/endpoint_pair_test.c b/test/core/iomgr/endpoint_pair_test.c
index a91a9a7084..6461d430eb 100644
--- a/test/core/iomgr/endpoint_pair_test.c
+++ b/test/core/iomgr/endpoint_pair_test.c
@@ -31,14 +31,12 @@
*
*/
-#include "src/core/lib/iomgr/tcp_posix.h"
-
+#include "src/core/lib/iomgr/endpoint_pair.h"
#include <grpc/grpc.h>
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
#include <grpc/support/time.h>
#include <grpc/support/useful.h>
-#include "src/core/lib/iomgr/endpoint_pair.h"
#include "test/core/iomgr/endpoint_tests.h"
#include "test/core/util/test_config.h"
diff --git a/test/core/surface/server_test.c b/test/core/surface/server_test.c
index 1d5211d225..4c62d8caad 100644
--- a/test/core/surface/server_test.c
+++ b/test/core/surface/server_test.c
@@ -1,6 +1,6 @@
/*
*
- * Copyright 2015, Google Inc.
+ * Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -42,11 +42,19 @@ void test_register_method_fail(void) {
grpc_server *server = grpc_server_create(NULL, NULL);
void *method;
void *method_old;
- method = grpc_server_register_method(server, NULL, NULL);
+ method = grpc_server_register_method(server, NULL, NULL, 0);
GPR_ASSERT(method == NULL);
- method_old = grpc_server_register_method(server, "m", "h");
+ method_old = grpc_server_register_method(server, "m", "h", 0);
GPR_ASSERT(method_old != NULL);
- method = grpc_server_register_method(server, "m", "h");
+ method = grpc_server_register_method(server, "m", "h", 0);
+ GPR_ASSERT(method == NULL);
+ method_old = grpc_server_register_method(
+ server, "m2", "h2", GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST);
+ GPR_ASSERT(method_old != NULL);
+ method = grpc_server_register_method(server, "m2", "h2", 0);
+ GPR_ASSERT(method == NULL);
+ method = grpc_server_register_method(
+ server, "m2", "h2", GRPC_INITIAL_METADATA_IDEMPOTENT_REQUEST);
GPR_ASSERT(method == NULL);
grpc_server_destroy(server);
}
diff --git a/test/core/transport/chttp2/hpack_encoder_test.c b/test/core/transport/chttp2/hpack_encoder_test.c
index 818ce09a7c..464f0d93b0 100644
--- a/test/core/transport/chttp2/hpack_encoder_test.c
+++ b/test/core/transport/chttp2/hpack_encoder_test.c
@@ -34,10 +34,12 @@
#include "src/core/ext/transport/chttp2/transport/hpack_encoder.h"
#include <stdio.h>
+#include <string.h>
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
#include <grpc/support/string_util.h>
+
#include "src/core/ext/transport/chttp2/transport/hpack_parser.h"
#include "src/core/lib/support/string.h"
#include "src/core/lib/transport/metadata.h"
@@ -93,7 +95,10 @@ static void verify(size_t window_available, int eof, size_t expect_window_used,
gpr_slice_buffer_init(&output);
- grpc_chttp2_encode_header(&g_compressor, 0xdeadbeef, &b, eof, &output);
+ grpc_transport_one_way_stats stats;
+ memset(&stats, 0, sizeof(stats));
+ grpc_chttp2_encode_header(&g_compressor, 0xdeadbeef, &b, eof, &stats,
+ &output);
merged = grpc_slice_merge(output.slices, output.count);
gpr_slice_buffer_destroy(&output);
grpc_metadata_batch_destroy(&b);
diff --git a/test/cpp/grpclb/grpclb_api_test.cc b/test/cpp/grpclb/grpclb_api_test.cc
index bc8219c1c7..92f93c869c 100644
--- a/test/cpp/grpclb/grpclb_api_test.cc
+++ b/test/cpp/grpclb/grpclb_api_test.cc
@@ -34,7 +34,7 @@
#include <gtest/gtest.h>
#include <string>
-#include "src/core/lib/client_config/lb_policies/load_balancer_api.h"
+#include "src/core/ext/lb_policy/grpclb/load_balancer_api.h"
#include "src/proto/grpc/lb/v0/load_balancer.pb.h" // C++ version
namespace grpc {
diff --git a/tools/buildgen/plugins/expand_filegroups.py b/tools/buildgen/plugins/expand_filegroups.py
index c40143ef95..0294a43271 100755
--- a/tools/buildgen/plugins/expand_filegroups.py
+++ b/tools/buildgen/plugins/expand_filegroups.py
@@ -75,11 +75,20 @@ def mako_plugin(dictionary):
todo.append(cur)
else:
skips = 0
+ assert 'plugins' not in cur
+ plugins = []
for uses in cur.get('uses', []):
+ for plugin in filegroups[uses]['plugins']:
+ if plugin not in plugins:
+ plugins.append(plugin)
for lst in FILEGROUP_LISTS:
vals = cur.get(lst, [])
vals.extend(filegroups[uses].get(lst, []))
cur[lst] = vals
+ cur_plugin_name = cur.get('plugin')
+ if cur_plugin_name:
+ plugins.append(cur_plugin_name)
+ cur['plugins'] = plugins
filegroups[cur['name']] = cur
# the above expansion can introduce duplicate filenames: contract them here
@@ -88,13 +97,20 @@ def mako_plugin(dictionary):
fg[lst] = sorted(list(set(fg.get(lst, []))))
for lib in libs:
+ assert 'plugins' not in lib
+ plugins = []
for fg_name in lib.get('filegroups', []):
fg = filegroups[fg_name]
-
+ for plugin in fg['plugins']:
+ if plugin not in plugins:
+ plugins.append(plugin)
for lst in FILEGROUP_LISTS:
vals = lib.get(lst, [])
vals.extend(fg.get(lst, []))
lib[lst] = vals
-
+ lib['plugins'] = plugins
+ if lib.get('generate_plugin_registry', False):
+ lib['src'].append('src/core/plugin_registry/%s_plugin_registry.c' %
+ lib['name'])
for lst in FILEGROUP_LISTS:
lib[lst] = sorted(list(set(lib.get(lst, []))))
diff --git a/tools/codegen/core/gen_load_balancing_proto.sh b/tools/codegen/core/gen_load_balancing_proto.sh
index 6a5363eeb3..339da0a733 100755
--- a/tools/codegen/core/gen_load_balancing_proto.sh
+++ b/tools/codegen/core/gen_load_balancing_proto.sh
@@ -82,7 +82,7 @@ fi
readonly GRPC_ROOT=$PWD
-OUTPUT_DIR="$GRPC_ROOT/src/core/lib/proto/grpc/lb/v0"
+OUTPUT_DIR="$GRPC_ROOT/src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0"
if [ $# -eq 2 ]; then
mkdir -p "$2"
if [ $? != 0 ]; then
@@ -122,7 +122,7 @@ protoc \
"$(basename $1)"
readonly PROTO_BASENAME=$(basename $1 .proto)
-sed -i "s:$PROTO_BASENAME.pb.h:src/core/lib/proto/grpc/lb/v0/$PROTO_BASENAME.pb.h:g" \
+sed -i "s:$PROTO_BASENAME.pb.h:src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/$PROTO_BASENAME.pb.h:g" \
"$OUTPUT_DIR/$PROTO_BASENAME.pb.c"
# prepend copyright
diff --git a/tools/codegen/core/gen_static_metadata.py b/tools/codegen/core/gen_static_metadata.py
index 70d41414f4..a6336a3d55 100755
--- a/tools/codegen/core/gen_static_metadata.py
+++ b/tools/codegen/core/gen_static_metadata.py
@@ -69,6 +69,7 @@ CONFIG = [
(':scheme', 'grpc'),
(':authority', ''),
(':method', 'GET'),
+ (':method', 'PUT'),
(':path', '/'),
(':path', '/index.html'),
(':status', '204'),
@@ -232,20 +233,20 @@ with open(sys.argv[0]) as my_source:
if line[0] != '#':
break
copyright.append(line)
- put_banner([H,C], [line[1:].strip() for line in copyright])
+ put_banner([H,C], [line[2:].rstrip() for line in copyright])
put_banner([H,C],
"""WARNING: Auto-generated code.
-To make changes to this file, change tools/codegen/core/gen_static_metadata.py,
-and then re-run it.
+To make changes to this file, change
+tools/codegen/core/gen_static_metadata.py, and then re-run it.
-See metadata.h for an explanation of the interface here, and metadata.c for an
-explanation of what's going on.
+See metadata.h for an explanation of the interface here, and metadata.c for
+an explanation of what's going on.
""".splitlines())
-print >>H, '#ifndef GRPC_INTERNAL_CORE_TRANSPORT_STATIC_METADATA_H'
-print >>H, '#define GRPC_INTERNAL_CORE_TRANSPORT_STATIC_METADATA_H'
+print >>H, '#ifndef GRPC_CORE_LIB_TRANSPORT_STATIC_METADATA_H'
+print >>H, '#define GRPC_CORE_LIB_TRANSPORT_STATIC_METADATA_H'
print >>H
print >>H, '#include "src/core/lib/transport/metadata.h"'
print >>H
@@ -264,13 +265,13 @@ print >>C
print >>H, '#define GRPC_STATIC_MDELEM_COUNT %d' % len(all_elems)
print >>H, 'extern grpc_mdelem grpc_static_mdelem_table[GRPC_STATIC_MDELEM_COUNT];'
-print >>H, 'extern gpr_uintptr grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT];'
+print >>H, 'extern uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT];'
for i, elem in enumerate(all_elems):
print >>H, '/* "%s": "%s" */' % elem
print >>H, '#define %s (&grpc_static_mdelem_table[%d])' % (mangle(elem).upper(), i)
print >>H
print >>C, 'grpc_mdelem grpc_static_mdelem_table[GRPC_STATIC_MDELEM_COUNT];'
-print >>C, 'gpr_uintptr grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT] = {'
+print >>C, 'uintptr_t grpc_static_mdelem_user_data[GRPC_STATIC_MDELEM_COUNT] = {'
print >>C, ' %s' % ','.join('%d' % static_userdata.get(elem, 0) for elem in all_elems)
print >>C, '};'
print >>C
@@ -285,8 +286,8 @@ def md_idx(m):
if m == m2:
return i
-print >>H, 'extern const gpr_uint8 grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT*2];'
-print >>C, 'const gpr_uint8 grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT*2] = {'
+print >>H, 'extern const uint8_t grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT*2];'
+print >>C, 'const uint8_t grpc_static_metadata_elem_indices[GRPC_STATIC_MDELEM_COUNT*2] = {'
print >>C, ','.join('%d' % str_idx(x) for x in itertools.chain.from_iterable([a,b] for a, b in all_elems))
print >>C, '};'
print >>C
@@ -297,15 +298,15 @@ print >>C, '%s' % ',\n'.join(' "%s"' % s for s in all_strs)
print >>C, '};'
print >>C
-print >>H, 'extern const gpr_uint8 grpc_static_accept_encoding_metadata[%d];' % (1 << len(COMPRESSION_ALGORITHMS))
-print >>C, 'const gpr_uint8 grpc_static_accept_encoding_metadata[%d] = {' % (1 << len(COMPRESSION_ALGORITHMS))
+print >>H, 'extern const uint8_t grpc_static_accept_encoding_metadata[%d];' % (1 << len(COMPRESSION_ALGORITHMS))
+print >>C, 'const uint8_t grpc_static_accept_encoding_metadata[%d] = {' % (1 << len(COMPRESSION_ALGORITHMS))
print >>C, '0,%s' % ','.join('%d' % md_idx(elem) for elem in compression_elems)
print >>C, '};'
print >>C
print >>H, '#define GRPC_MDELEM_ACCEPT_ENCODING_FOR_ALGORITHMS(algs) (&grpc_static_mdelem_table[grpc_static_accept_encoding_metadata[(algs)]])'
-print >>H, '#endif /* GRPC_INTERNAL_CORE_TRANSPORT_STATIC_METADATA_H */'
+print >>H, '#endif /* GRPC_CORE_LIB_TRANSPORT_STATIC_METADATA_H */'
H.close()
C.close()
diff --git a/tools/distrib/check_include_guards.py b/tools/distrib/check_include_guards.py
index 463e316885..6406fe6ae7 100755
--- a/tools/distrib/check_include_guards.py
+++ b/tools/distrib/check_include_guards.py
@@ -167,7 +167,7 @@ argp.add_argument('--precommit',
args = argp.parse_args()
KNOWN_BAD = set([
- 'src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h',
+ 'src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h',
])
diff --git a/tools/distrib/check_nanopb_output.sh b/tools/distrib/check_nanopb_output.sh
index e0a60946a9..4032ae1d9d 100755
--- a/tools/distrib/check_nanopb_output.sh
+++ b/tools/distrib/check_nanopb_output.sh
@@ -60,7 +60,7 @@ PATH="$PROTOC_PATH:$PATH" ./tools/codegen/core/gen_load_balancing_proto.sh \
$NANOPB_TMP_OUTPUT
# compare outputs to checked compiled code
-if ! diff -r $NANOPB_TMP_OUTPUT src/core/lib/proto/grpc/lb/v0; then
- echo "Outputs differ: $NANOPB_TMP_OUTPUT vs src/core/lib/proto/grpc/lb/v0"
+if ! diff -r $NANOPB_TMP_OUTPUT src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0; then
+ echo "Outputs differ: $NANOPB_TMP_OUTPUT vs src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0"
exit 2
fi
diff --git a/tools/doxygen/Doxyfile.core.internal b/tools/doxygen/Doxyfile.core.internal
index 6b6c4bcc48..1780257cfd 100644
--- a/tools/doxygen/Doxyfile.core.internal
+++ b/tools/doxygen/Doxyfile.core.internal
@@ -773,6 +773,8 @@ include/grpc/impl/codegen/grpc_types.h \
include/grpc/impl/codegen/propagation_bits.h \
include/grpc/impl/codegen/status.h \
include/grpc/status.h \
+src/core/ext/lb_policy/grpclb/load_balancer_api.h \
+src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h \
src/core/ext/transport/chttp2/transport/alpn.h \
src/core/ext/transport/chttp2/transport/bin_encoder.h \
src/core/ext/transport/chttp2/transport/chttp2_transport.h \
@@ -812,9 +814,6 @@ src/core/lib/channel/subchannel_call_holder.h \
src/core/lib/client_config/client_config.h \
src/core/lib/client_config/connector.h \
src/core/lib/client_config/initial_connect_string.h \
-src/core/lib/client_config/lb_policies/load_balancer_api.h \
-src/core/lib/client_config/lb_policies/pick_first.h \
-src/core/lib/client_config/lb_policies/round_robin.h \
src/core/lib/client_config/lb_policy.h \
src/core/lib/client_config/lb_policy_factory.h \
src/core/lib/client_config/lb_policy_registry.h \
@@ -846,9 +845,7 @@ src/core/lib/iomgr/iomgr.h \
src/core/lib/iomgr/iomgr_internal.h \
src/core/lib/iomgr/iomgr_posix.h \
src/core/lib/iomgr/pollset.h \
-src/core/lib/iomgr/pollset_posix.h \
src/core/lib/iomgr/pollset_set.h \
-src/core/lib/iomgr/pollset_set_posix.h \
src/core/lib/iomgr/pollset_set_windows.h \
src/core/lib/iomgr/pollset_windows.h \
src/core/lib/iomgr/resolve_address.h \
@@ -876,7 +873,6 @@ src/core/lib/json/json.h \
src/core/lib/json/json_common.h \
src/core/lib/json/json_reader.h \
src/core/lib/json/json_writer.h \
-src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h \
src/core/lib/security/auth_filters.h \
src/core/lib/security/b64.h \
src/core/lib/security/credentials.h \
@@ -916,6 +912,10 @@ third_party/nanopb/pb.h \
third_party/nanopb/pb_common.h \
third_party/nanopb/pb_decode.h \
third_party/nanopb/pb_encode.h \
+src/core/ext/lb_policy/grpclb/load_balancer_api.c \
+src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c \
+src/core/ext/lb_policy/pick_first/pick_first.c \
+src/core/ext/lb_policy/round_robin/round_robin.c \
src/core/ext/transport/chttp2/client/insecure/channel_create.c \
src/core/ext/transport/chttp2/client/secure/secure_channel_create.c \
src/core/ext/transport/chttp2/server/insecure/server_chttp2.c \
@@ -963,9 +963,6 @@ src/core/lib/client_config/client_config.c \
src/core/lib/client_config/connector.c \
src/core/lib/client_config/default_initial_connect_string.c \
src/core/lib/client_config/initial_connect_string.c \
-src/core/lib/client_config/lb_policies/load_balancer_api.c \
-src/core/lib/client_config/lb_policies/pick_first.c \
-src/core/lib/client_config/lb_policies/round_robin.c \
src/core/lib/client_config/lb_policy.c \
src/core/lib/client_config/lb_policy_factory.c \
src/core/lib/client_config/lb_policy_registry.c \
@@ -1029,7 +1026,6 @@ 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/proto/grpc/lb/v0/load_balancer.pb.c \
src/core/lib/security/b64.c \
src/core/lib/security/client_auth_filter.c \
src/core/lib/security/credentials.c \
@@ -1075,6 +1071,7 @@ src/core/lib/transport/transport_op_string.c \
src/core/lib/tsi/fake_transport_security.c \
src/core/lib/tsi/ssl_transport_security.c \
src/core/lib/tsi/transport_security.c \
+src/core/plugin_registry/grpc_plugin_registry.c \
third_party/nanopb/pb_common.c \
third_party/nanopb/pb_decode.c \
third_party/nanopb/pb_encode.c \
diff --git a/tools/gce/create_interop_worker.sh b/tools/gce/create_interop_worker.sh
new file mode 100755
index 0000000000..3c49c6102a
--- /dev/null
+++ b/tools/gce/create_interop_worker.sh
@@ -0,0 +1,64 @@
+#!/bin/bash
+# Copyright 2015-2016, Google Inc.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are
+# met:
+#
+# * Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# * Redistributions in binary form must reproduce the above
+# copyright notice, this list of conditions and the following disclaimer
+# in the documentation and/or other materials provided with the
+# distribution.
+# * Neither the name of Google Inc. nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+# Creates an interop worker on GCE.
+# IMPORTANT: After this script finishes, there are still some manual
+# steps needed there are hard to automatize.
+# See go/grpc-jenkins-setup for followup instructions.
+
+set -ex
+
+cd $(dirname $0)
+
+CLOUD_PROJECT=grpc-testing
+ZONE=us-east1-a # canary gateway is reachable from this zone
+
+INSTANCE_NAME="${1:-grpc-canary-interop2}"
+
+gcloud compute instances create $INSTANCE_NAME \
+ --project="$CLOUD_PROJECT" \
+ --zone "$ZONE" \
+ --machine-type n1-standard-16 \
+ --image ubuntu-15-10 \
+ --boot-disk-size 1000 \
+ --scopes https://www.googleapis.com/auth/xapi.zoo
+
+echo 'Created GCE instance, waiting 60 seconds for it to come online.'
+sleep 60
+
+gcloud compute copy-files \
+ --project="$CLOUD_PROJECT" \
+ --zone "$ZONE" \
+ jenkins_master.pub linux_worker_init.sh ${INSTANCE_NAME}:~
+
+gcloud compute ssh \
+ --project="$CLOUD_PROJECT" \
+ --zone "$ZONE" \
+ $INSTANCE_NAME --command "./linux_worker_init.sh"
diff --git a/tools/run_tests/build_python.sh b/tools/run_tests/build_python.sh
index 79a148faf1..fe84300c7b 100755
--- a/tools/run_tests/build_python.sh
+++ b/tools/run_tests/build_python.sh
@@ -40,6 +40,7 @@ export PATH=$ROOT/bins/$CONFIG:$ROOT/bins/$CONFIG/protobuf:$PATH
export CFLAGS="-I$ROOT/include -std=gnu99"
export LDFLAGS="-L$ROOT/libs/$CONFIG"
export GRPC_PYTHON_BUILD_WITH_CYTHON=1
+export GRPC_PYTHON_USE_PRECOMPILED_BINARIES=0
if [ "$CONFIG" = "gcov" ]
then
diff --git a/tools/run_tests/jobset.py b/tools/run_tests/jobset.py
index a3b246dc08..d1cfc5952f 100755
--- a/tools/run_tests/jobset.py
+++ b/tools/run_tests/jobset.py
@@ -151,7 +151,8 @@ class JobSpec(object):
def __init__(self, cmdline, shortname=None, environ=None, hash_targets=None,
cwd=None, shell=False, timeout_seconds=5*60, flake_retries=0,
- timeout_retries=0, kill_handler=None, cpu_cost=1.0):
+ timeout_retries=0, kill_handler=None, cpu_cost=1.0,
+ verbose_success=False):
"""
Arguments:
cmdline: a list of arguments to pass as the command line
@@ -176,6 +177,7 @@ class JobSpec(object):
self.timeout_retries = timeout_retries
self.kill_handler = kill_handler
self.cpu_cost = cpu_cost
+ self.verbose_success = verbose_success
def identity(self):
return '%r %r %r' % (self.cmdline, self.environ, self.hash_targets)
@@ -287,7 +289,8 @@ class Job(object):
cores = (user + sys) / real
measurement = '; cpu_cost=%.01f; estimated=%.01f' % (cores, self._spec.cpu_cost)
message('PASSED', '%s [time=%.1fsec; retries=%d:%d%s]' % (
- self._spec.shortname, elapsed, self._retries, self._timeout_retries, measurement),
+ self._spec.shortname, elapsed, self._retries, self._timeout_retries, measurement),
+ stdout() if self._spec.verbose_success else None,
do_newline=self._newline_on_success or self._travis)
self.result.state = 'PASSED'
if self._bin_hash:
diff --git a/tools/run_tests/performance/build_performance.sh b/tools/run_tests/performance/build_performance.sh
new file mode 100755
index 0000000000..00cc41ec73
--- /dev/null
+++ b/tools/run_tests/performance/build_performance.sh
@@ -0,0 +1,40 @@
+#!/bin/bash
+# Copyright 2015-2016, Google Inc.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are
+# met:
+#
+# * Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# * Redistributions in binary form must reproduce the above
+# copyright notice, this list of conditions and the following disclaimer
+# in the documentation and/or other materials provided with the
+# distribution.
+# * Neither the name of Google Inc. nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+set -ex
+
+cd $(dirname $0)/../../..
+
+#TODO(jtattermusch): add support for more languages
+
+CONFIG=${CONFIG:-opt}
+
+# build C++ qps worker & driver
+make CONFIG=${CONFIG} qps_worker qps_driver -j8
diff --git a/tools/run_tests/performance/remote_host_build.sh b/tools/run_tests/performance/remote_host_build.sh
new file mode 100755
index 0000000000..f23ea921ce
--- /dev/null
+++ b/tools/run_tests/performance/remote_host_build.sh
@@ -0,0 +1,36 @@
+#!/bin/bash
+# Copyright 2015-2016, Google Inc.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are
+# met:
+#
+# * Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# * Redistributions in binary form must reproduce the above
+# copyright notice, this list of conditions and the following disclaimer
+# in the documentation and/or other materials provided with the
+# distribution.
+# * Neither the name of Google Inc. nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+set -ex
+
+cd $(dirname $0)/../../..
+
+# execute the build script remotely
+ssh "${USER_AT_HOST}" "CONFIG=${CONFIG} ~/performance_workspace/grpc/tools/run_tests/performance/build_performance.sh"
diff --git a/tools/run_tests/performance/remote_host_prepare.sh b/tools/run_tests/performance/remote_host_prepare.sh
new file mode 100755
index 0000000000..bad2424a6b
--- /dev/null
+++ b/tools/run_tests/performance/remote_host_prepare.sh
@@ -0,0 +1,44 @@
+#!/bin/bash
+# Copyright 2015-2016, Google Inc.
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are
+# met:
+#
+# * Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# * Redistributions in binary form must reproduce the above
+# copyright notice, this list of conditions and the following disclaimer
+# in the documentation and/or other materials provided with the
+# distribution.
+# * Neither the name of Google Inc. nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+set -ex
+
+cd $(dirname $0)/../../..
+
+# cleanup after previous builds
+ssh "${USER_AT_HOST}" "rm -rf ~/performance_workspace && mkdir -p ~/performance_workspace"
+
+# TODO(jtattermusch): To be sure there are not running processes that would
+# mess with the results, be rough and reboot the slave here
+# and wait for it to come back online.
+
+# push the current sources to the slave and unpack it.
+scp ../grpc.tar "${USER_AT_HOST}:~/performance_workspace"
+ssh "${USER_AT_HOST}" "tar -xf ~/performance_workspace/grpc.tar -C ~/performance_workspace" \ No newline at end of file
diff --git a/tools/run_tests/run_performance_tests.py b/tools/run_tests/run_performance_tests.py
new file mode 100755
index 0000000000..77c0addb42
--- /dev/null
+++ b/tools/run_tests/run_performance_tests.py
@@ -0,0 +1,353 @@
+#!/usr/bin/env python2.7
+# 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.
+
+"""Run performance tests locally or remotely."""
+
+import argparse
+import jobset
+import multiprocessing
+import os
+import subprocess
+import sys
+import tempfile
+import time
+import uuid
+
+
+_ROOT = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), '../..'))
+os.chdir(_ROOT)
+
+
+_REMOTE_HOST_USERNAME = 'jenkins'
+
+
+class CXXLanguage:
+
+ def __init__(self):
+ self.safename = 'cxx'
+
+ def scenarios(self):
+ # TODO(jtattermusch): add more scenarios
+ return {
+ # Scenario 1: generic async streaming ping-pong (contentionless latency)
+ 'cpp_async_generic_streaming_ping_pong': [
+ '--rpc_type=STREAMING',
+ '--client_type=ASYNC_CLIENT',
+ '--server_type=ASYNC_GENERIC_SERVER',
+ '--outstanding_rpcs_per_channel=1',
+ '--client_channels=1',
+ '--bbuf_req_size=0',
+ '--bbuf_resp_size=0',
+ '--async_client_threads=1',
+ '--async_server_threads=1',
+ '--secure_test=true',
+ '--num_servers=1',
+ '--num_clients=1',
+ '--server_core_limit=0',
+ '--client_core_limit=0'],
+ # Scenario 5: Sync unary ping-pong with protobufs
+ 'cpp_sync_unary_ping_pong_protobuf': [
+ '--rpc_type=UNARY',
+ '--client_type=SYNC_CLIENT',
+ '--server_type=SYNC_SERVER',
+ '--outstanding_rpcs_per_channel=1',
+ '--client_channels=1',
+ '--simple_req_size=0',
+ '--simple_resp_size=0',
+ '--secure_test=true',
+ '--num_servers=1',
+ '--num_clients=1',
+ '--server_core_limit=0',
+ '--client_core_limit=0']}
+
+ def __str__(self):
+ return 'c++'
+
+
+class CSharpLanguage:
+
+ def __init__(self):
+ self.safename = str(self)
+
+ def __str__(self):
+ return 'csharp'
+
+
+class NodeLanguage:
+
+ def __init__(self):
+ pass
+ self.safename = str(self)
+
+ def __str__(self):
+ return 'node'
+
+
+_LANGUAGES = {
+ 'c++' : CXXLanguage(),
+ 'csharp' : CSharpLanguage(),
+ 'node' : NodeLanguage(),
+}
+
+
+class QpsWorkerJob:
+ """Encapsulates a qps worker server job."""
+
+ def __init__(self, spec, host_and_port):
+ self._spec = spec
+ self.host_and_port = host_and_port
+ self._job = jobset.Job(spec, bin_hash=None, newline_on_success=True, travis=True, add_env={})
+
+ def is_running(self):
+ """Polls a job and returns True if given job is still running."""
+ return self._job.state(jobset.NoCache()) == jobset._RUNNING
+
+ def kill(self):
+ return self._job.kill()
+
+
+def create_qpsworker_job(language, port=10000, remote_host=None):
+ # TODO: support more languages
+ cmd = 'bins/opt/qps_worker --driver_port=%s' % port
+ if remote_host:
+ user_at_host = '%s@%s' % (_REMOTE_HOST_USERNAME, remote_host)
+ cmd = 'ssh %s "cd ~/performance_workspace/grpc/ && %s"' % (user_at_host, cmd)
+ host_and_port='%s:%s' % (remote_host, port)
+ else:
+ host_and_port='localhost:%s' % port
+
+ jobspec = jobset.JobSpec(
+ cmdline=[cmd],
+ shortname='qps_worker',
+ timeout_seconds=15*60,
+ shell=True)
+ return QpsWorkerJob(jobspec, host_and_port)
+
+
+def create_scenario_jobspec(scenario_name, driver_args, workers, remote_host=None):
+ """Runs one scenario using QPS driver."""
+ # setting QPS_WORKERS env variable here makes sure it works with SSH too.
+ cmd = 'QPS_WORKERS="%s" bins/opt/qps_driver ' % ','.join(workers)
+ cmd += ' '.join(driver_args)
+ if remote_host:
+ user_at_host = '%s@%s' % (_REMOTE_HOST_USERNAME, remote_host)
+ cmd = 'ssh %s "cd ~/performance_workspace/grpc/ && %s"' % (user_at_host, cmd)
+
+ return jobset.JobSpec(
+ cmdline=[cmd],
+ shortname='qps_driver.%s' % scenario_name,
+ timeout_seconds=3*60,
+ shell=True,
+ verbose_success=True)
+
+
+def archive_repo():
+ """Archives local version of repo including submodules."""
+ # TODO: also archive grpc-go and grpc-java repos
+ archive_job = jobset.JobSpec(
+ cmdline=['tar', '-cf', '../grpc.tar', '../grpc/'],
+ shortname='archive_repo',
+ timeout_seconds=3*60)
+
+ jobset.message('START', 'Archiving local repository.', do_newline=True)
+ num_failures, _ = jobset.run(
+ [archive_job], newline_on_success=True, maxjobs=1)
+ if num_failures == 0:
+ jobset.message('SUCCESS',
+ 'Archive with local repository create successfully.',
+ do_newline=True)
+ else:
+ jobset.message('FAILED', 'Failed to archive local repository.',
+ do_newline=True)
+ sys.exit(1)
+
+
+def prepare_remote_hosts(hosts):
+ """Prepares remote hosts."""
+ prepare_jobs = []
+ for host in hosts:
+ user_at_host = '%s@%s' % (_REMOTE_HOST_USERNAME, host)
+ prepare_jobs.append(
+ jobset.JobSpec(
+ cmdline=['tools/run_tests/performance/remote_host_prepare.sh'],
+ shortname='remote_host_prepare.%s' % host,
+ environ = {'USER_AT_HOST': user_at_host},
+ timeout_seconds=3*60))
+ jobset.message('START', 'Preparing remote hosts.', do_newline=True)
+ num_failures, _ = jobset.run(
+ prepare_jobs, newline_on_success=True, maxjobs=10)
+ if num_failures == 0:
+ jobset.message('SUCCESS',
+ 'Remote hosts ready to start build.',
+ do_newline=True)
+ else:
+ jobset.message('FAILED', 'Failed to prepare remote hosts.',
+ do_newline=True)
+ sys.exit(1)
+
+
+def build_on_remote_hosts(hosts, build_local=False):
+ """Builds performance worker on remote hosts."""
+ build_timeout = 15*60
+ build_jobs = []
+ for host in hosts:
+ user_at_host = '%s@%s' % (_REMOTE_HOST_USERNAME, host)
+ build_jobs.append(
+ jobset.JobSpec(
+ cmdline=['tools/run_tests/performance/remote_host_build.sh'],
+ shortname='remote_host_build.%s' % host,
+ environ = {'USER_AT_HOST': user_at_host, 'CONFIG': 'opt'},
+ timeout_seconds=build_timeout))
+ if build_local:
+ # Build locally as well
+ build_jobs.append(
+ jobset.JobSpec(
+ cmdline=['tools/run_tests/performance/build_performance.sh'],
+ shortname='local_build',
+ environ = {'CONFIG': 'opt'},
+ timeout_seconds=build_timeout))
+ jobset.message('START', 'Building on remote hosts.', do_newline=True)
+ num_failures, _ = jobset.run(
+ build_jobs, newline_on_success=True, maxjobs=10)
+ if num_failures == 0:
+ jobset.message('SUCCESS',
+ 'Build on remote hosts was successful.',
+ do_newline=True)
+ else:
+ jobset.message('FAILED', 'Failed to build on remote hosts.',
+ do_newline=True)
+ sys.exit(1)
+
+
+def start_qpsworkers(worker_hosts):
+ """Starts QPS workers as background jobs."""
+ if not worker_hosts:
+ # run two workers locally
+ workers=[(None, 10000), (None, 10010)]
+ elif len(worker_hosts) == 1:
+ # run two workers on the remote host
+ workers=[(worker_hosts[0], 10000), (worker_hosts[0], 10010)]
+ else:
+ # run one worker per each remote host
+ workers=[(worker_host, 10000) for worker_host in worker_hosts]
+
+ return [create_qpsworker_job(CXXLanguage(),
+ port=worker[1],
+ remote_host=worker[0])
+ for worker in workers]
+
+
+def create_scenarios(languages, workers, remote_host=None):
+ """Create jobspecs for scenarios to run."""
+ scenarios = []
+ for language in languages:
+ for scenario_name, driver_args in language.scenarios().iteritems():
+ scenario = create_scenario_jobspec(scenario_name,
+ driver_args,
+ workers,
+ remote_host=remote_host)
+ scenarios.append(scenario)
+
+ # the very last scenario requests shutting down the workers.
+ scenarios.append(create_scenario_jobspec('quit_workers',
+ ['--quit=true'],
+ workers,
+ remote_host=remote_host))
+ return scenarios
+
+
+def finish_qps_workers(jobs):
+ """Waits for given jobs to finish and eventually kills them."""
+ retries = 0
+ while any(job.is_running() for job in jobs):
+ for job in qpsworker_jobs:
+ if job.is_running():
+ print 'QPS worker "%s" is still running.' % job.host_and_port
+ if retries > 10:
+ print 'Killing all QPS workers.'
+ for job in jobs:
+ job.kill()
+ retries += 1
+ time.sleep(3)
+ print 'All QPS workers finished.'
+
+
+argp = argparse.ArgumentParser(description='Run performance tests.')
+argp.add_argument('--remote_driver_host',
+ default=None,
+ help='Run QPS driver on given host. By default, QPS driver is run locally.')
+argp.add_argument('--remote_worker_host',
+ nargs='+',
+ default=[],
+ help='Worker hosts where to start QPS workers.')
+
+args = argp.parse_args()
+
+# Put together set of remote hosts where to run and build
+remote_hosts = set()
+if args.remote_worker_host:
+ for host in args.remote_worker_host:
+ remote_hosts.add(host)
+if args.remote_driver_host:
+ remote_hosts.add(args.remote_driver_host)
+
+if remote_hosts:
+ archive_repo()
+ prepare_remote_hosts(remote_hosts)
+
+build_local = False
+if not args.remote_driver_host:
+ build_local = True
+build_on_remote_hosts(remote_hosts, build_local=build_local)
+
+qpsworker_jobs = start_qpsworkers(args.remote_worker_host)
+
+worker_addresses = [job.host_and_port for job in qpsworker_jobs]
+
+try:
+ scenarios = create_scenarios(languages=[CXXLanguage()],
+ workers=worker_addresses,
+ remote_host=args.remote_driver_host)
+ if not scenarios:
+ raise Exception('No scenarios to run')
+
+ jobset.message('START', 'Running scenarios.', do_newline=True)
+ num_failures, _ = jobset.run(
+ scenarios, newline_on_success=True, maxjobs=1)
+ if num_failures == 0:
+ jobset.message('SUCCESS',
+ 'All scenarios finished successfully.',
+ do_newline=True)
+ else:
+ jobset.message('FAILED', 'Some of the scenarios failed.',
+ do_newline=True)
+ sys.exit(1)
+finally:
+ finish_qps_workers(qpsworker_jobs)
diff --git a/tools/run_tests/run_python.sh b/tools/run_tests/run_python.sh
index d4b7250cbb..e3be14e7c7 100755
--- a/tools/run_tests/run_python.sh
+++ b/tools/run_tests/run_python.sh
@@ -40,6 +40,7 @@ export PATH=$ROOT/bins/$CONFIG:$ROOT/bins/$CONFIG/protobuf:$PATH
export CFLAGS="-I$ROOT/include -std=c89"
export LDFLAGS="-L$ROOT/libs/$CONFIG"
export GRPC_PYTHON_BUILD_WITH_CYTHON=1
+export GRPC_PYTHON_USE_PRECOMPILED_BINARIES=0
if [ "$CONFIG" = "gcov" ]
then
diff --git a/tools/run_tests/run_tests.py b/tools/run_tests/run_tests.py
index df6dc0bcfa..37ae9da63a 100755
--- a/tools/run_tests/run_tests.py
+++ b/tools/run_tests/run_tests.py
@@ -120,7 +120,12 @@ def get_c_tests(travis, test_lang) :
def _check_compiler(compiler, supported_compilers):
if compiler not in supported_compilers:
- raise Exception('Compiler %s not supported.' % compiler)
+ raise Exception('Compiler %s not supported (on this platform).' % compiler)
+
+
+def _check_arch(arch, supported_archs):
+ if arch not in supported_archs:
+ raise Exception('Architecture %s not supported.' % arch)
def _is_use_docker_child():
@@ -473,7 +478,20 @@ class CSharpLanguage(object):
def configure(self, config, args):
self.config = config
self.args = args
- _check_compiler(self.args.compiler, ['default'])
+ if self.platform == 'windows':
+ # Explicitly choosing between x86 and x64 arch doesn't work yet
+ _check_arch(self.args.arch, ['default'])
+ self._make_options = [_windows_toolset_option(self.args.compiler),
+ _windows_arch_option(self.args.arch)]
+ else:
+ _check_compiler(self.args.compiler, ['default'])
+ if self.platform == 'mac':
+ # On Mac, official distribution of mono is 32bit.
+ # TODO(jtattermusch): EMBED_ZLIB=true currently breaks the mac build
+ self._make_options = ['EMBED_OPENSSL=true',
+ 'CFLAGS=-m32', 'LDFLAGS=-m32']
+ else:
+ self._make_options = ['EMBED_OPENSSL=true', 'EMBED_ZLIB=true']
def test_specs(self):
with open('src/csharp/tests.json') as f:
@@ -520,23 +538,16 @@ class CSharpLanguage(object):
return [['tools/run_tests/pre_build_csharp.sh']]
def make_targets(self):
- # For Windows, this target doesn't really build anything,
- # everything is build by buildall script later.
- if self.platform == 'windows':
- return []
- else:
- return ['grpc_csharp_ext']
+ return ['grpc_csharp_ext']
def make_options(self):
- if self.platform == 'mac':
- # On Mac, official distribution of mono is 32bit.
- return ['CFLAGS=-arch i386', 'LDFLAGS=-arch i386']
- else:
- return []
+ return self._make_options;
def build_steps(self):
if self.platform == 'windows':
- return [['src\\csharp\\buildall.bat']]
+ return [[_windows_build_bat(self.args.compiler),
+ 'src/csharp/Grpc.sln',
+ '/p:Configuration=%s' % _MSBUILD_CONFIG[self.config.build_config]]]
else:
return [['tools/run_tests/build_csharp.sh']]
diff --git a/tools/run_tests/sources_and_headers.json b/tools/run_tests/sources_and_headers.json
index 49a61eeb87..126b874db6 100644
--- a/tools/run_tests/sources_and_headers.json
+++ b/tools/run_tests/sources_and_headers.json
@@ -1035,6 +1035,54 @@
],
"headers": [],
"language": "c",
+ "name": "internal_api_canary_iomgr_test",
+ "src": [
+ "test/core/internal_api_canaries/iomgr.c"
+ ],
+ "third_party": false,
+ "type": "target"
+ },
+ {
+ "deps": [
+ "gpr",
+ "gpr_test_util",
+ "grpc",
+ "grpc_test_util"
+ ],
+ "headers": [],
+ "language": "c",
+ "name": "internal_api_canary_support_test",
+ "src": [
+ "test/core/internal_api_canaries/iomgr.c"
+ ],
+ "third_party": false,
+ "type": "target"
+ },
+ {
+ "deps": [
+ "gpr",
+ "gpr_test_util",
+ "grpc",
+ "grpc_test_util"
+ ],
+ "headers": [],
+ "language": "c",
+ "name": "internal_api_canary_transport_test",
+ "src": [
+ "test/core/internal_api_canaries/iomgr.c"
+ ],
+ "third_party": false,
+ "type": "target"
+ },
+ {
+ "deps": [
+ "gpr",
+ "gpr_test_util",
+ "grpc",
+ "grpc_test_util"
+ ],
+ "headers": [],
+ "language": "c",
"name": "invalid_call_argument_test",
"src": [
"test/core/end2end/invalid_call_argument_test.c"
@@ -3869,6 +3917,8 @@
"include/grpc/impl/codegen/propagation_bits.h",
"include/grpc/impl/codegen/status.h",
"include/grpc/status.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/ext/transport/chttp2/transport/alpn.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
@@ -3908,9 +3958,6 @@
"src/core/lib/client_config/client_config.h",
"src/core/lib/client_config/connector.h",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.h",
"src/core/lib/client_config/lb_policy_registry.h",
@@ -3942,9 +3989,7 @@
"src/core/lib/iomgr/iomgr_internal.h",
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.h",
"src/core/lib/iomgr/resolve_address.h",
@@ -3972,7 +4017,6 @@
"src/core/lib/json/json_common.h",
"src/core/lib/json/json_reader.h",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/security/auth_filters.h",
"src/core/lib/security/b64.h",
"src/core/lib/security/credentials.h",
@@ -4029,6 +4073,12 @@
"include/grpc/impl/codegen/propagation_bits.h",
"include/grpc/impl/codegen/status.h",
"include/grpc/status.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.c",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
+ "src/core/ext/lb_policy/pick_first/pick_first.c",
+ "src/core/ext/lb_policy/round_robin/round_robin.c",
"src/core/ext/transport/chttp2/client/insecure/channel_create.c",
"src/core/ext/transport/chttp2/client/secure/secure_channel_create.c",
"src/core/ext/transport/chttp2/server/insecure/server_chttp2.c",
@@ -4115,12 +4165,6 @@
"src/core/lib/client_config/default_initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.c",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.c",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.c",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.c",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.c",
@@ -4184,9 +4228,7 @@
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/iomgr_windows.c",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.c",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.c",
@@ -4245,8 +4287,6 @@
"src/core/lib/json/json_string.c",
"src/core/lib/json/json_writer.c",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/security/auth_filters.h",
"src/core/lib/security/b64.c",
"src/core/lib/security/b64.h",
@@ -4326,7 +4366,8 @@
"src/core/lib/tsi/ssl_types.h",
"src/core/lib/tsi/transport_security.c",
"src/core/lib/tsi/transport_security.h",
- "src/core/lib/tsi/transport_security_interface.h"
+ "src/core/lib/tsi/transport_security_interface.h",
+ "src/core/plugin_registry/grpc_plugin_registry.c"
],
"third_party": false,
"type": "lib"
@@ -4499,6 +4540,8 @@
"include/grpc/impl/codegen/propagation_bits.h",
"include/grpc/impl/codegen/status.h",
"include/grpc/status.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/ext/transport/chttp2/transport/alpn.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
@@ -4538,9 +4581,6 @@
"src/core/lib/client_config/client_config.h",
"src/core/lib/client_config/connector.h",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.h",
"src/core/lib/client_config/lb_policy_registry.h",
@@ -4572,9 +4612,7 @@
"src/core/lib/iomgr/iomgr_internal.h",
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.h",
"src/core/lib/iomgr/resolve_address.h",
@@ -4602,7 +4640,6 @@
"src/core/lib/json/json_common.h",
"src/core/lib/json/json_reader.h",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/statistics/census_interface.h",
"src/core/lib/statistics/census_rpc_stats.h",
"src/core/lib/surface/api_trace.h",
@@ -4644,6 +4681,12 @@
"include/grpc/impl/codegen/propagation_bits.h",
"include/grpc/impl/codegen/status.h",
"include/grpc/status.h",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.c",
+ "src/core/ext/lb_policy/grpclb/load_balancer_api.h",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.c",
+ "src/core/ext/lb_policy/grpclb/proto/grpc/lb/v0/load_balancer.pb.h",
+ "src/core/ext/lb_policy/pick_first/pick_first.c",
+ "src/core/ext/lb_policy/round_robin/round_robin.c",
"src/core/ext/transport/chttp2/client/insecure/channel_create.c",
"src/core/ext/transport/chttp2/server/insecure/server_chttp2.c",
"src/core/ext/transport/chttp2/transport/alpn.c",
@@ -4728,12 +4771,6 @@
"src/core/lib/client_config/default_initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.c",
"src/core/lib/client_config/initial_connect_string.h",
- "src/core/lib/client_config/lb_policies/load_balancer_api.c",
- "src/core/lib/client_config/lb_policies/load_balancer_api.h",
- "src/core/lib/client_config/lb_policies/pick_first.c",
- "src/core/lib/client_config/lb_policies/pick_first.h",
- "src/core/lib/client_config/lb_policies/round_robin.c",
- "src/core/lib/client_config/lb_policies/round_robin.h",
"src/core/lib/client_config/lb_policy.c",
"src/core/lib/client_config/lb_policy.h",
"src/core/lib/client_config/lb_policy_factory.c",
@@ -4796,9 +4833,7 @@
"src/core/lib/iomgr/iomgr_posix.h",
"src/core/lib/iomgr/iomgr_windows.c",
"src/core/lib/iomgr/pollset.h",
- "src/core/lib/iomgr/pollset_posix.h",
"src/core/lib/iomgr/pollset_set.h",
- "src/core/lib/iomgr/pollset_set_posix.h",
"src/core/lib/iomgr/pollset_set_windows.c",
"src/core/lib/iomgr/pollset_set_windows.h",
"src/core/lib/iomgr/pollset_windows.c",
@@ -4857,8 +4892,6 @@
"src/core/lib/json/json_string.c",
"src/core/lib/json/json_writer.c",
"src/core/lib/json/json_writer.h",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.c",
- "src/core/lib/proto/grpc/lb/v0/load_balancer.pb.h",
"src/core/lib/statistics/census_interface.h",
"src/core/lib/statistics/census_rpc_stats.h",
"src/core/lib/surface/alarm.c",
@@ -4907,7 +4940,8 @@
"src/core/lib/transport/transport.c",
"src/core/lib/transport/transport.h",
"src/core/lib/transport/transport_impl.h",
- "src/core/lib/transport/transport_op_string.c"
+ "src/core/lib/transport/transport_op_string.c",
+ "src/core/plugin_registry/grpc_unsecure_plugin_registry.c"
],
"third_party": false,
"type": "lib"
@@ -6464,6 +6498,7 @@
"test/core/end2end/tests/graceful_server_shutdown.c",
"test/core/end2end/tests/high_initial_seqno.c",
"test/core/end2end/tests/hpack_size.c",
+ "test/core/end2end/tests/idempotent_request.c",
"test/core/end2end/tests/invoke_large_request.c",
"test/core/end2end/tests/large_metadata.c",
"test/core/end2end/tests/max_concurrent_streams.c",
@@ -6520,6 +6555,7 @@
"test/core/end2end/tests/graceful_server_shutdown.c",
"test/core/end2end/tests/high_initial_seqno.c",
"test/core/end2end/tests/hpack_size.c",
+ "test/core/end2end/tests/idempotent_request.c",
"test/core/end2end/tests/invoke_large_request.c",
"test/core/end2end/tests/large_metadata.c",
"test/core/end2end/tests/max_concurrent_streams.c",
diff --git a/tools/run_tests/tests.json b/tools/run_tests/tests.json
index c7c3417d96..2391224072 100644
--- a/tools/run_tests/tests.json
+++ b/tools/run_tests/tests.json
@@ -4651,6 +4651,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_census_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -5443,6 +5465,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_compress_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -6218,6 +6262,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_fakesec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -6991,6 +7056,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_full_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -7681,6 +7768,22 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "linux"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_full+pipe_test",
+ "platforms": [
+ "linux"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -8337,6 +8440,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_full+trace_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -9112,6 +9237,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_oauth2_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -9805,6 +9951,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_proxy_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -10435,6 +10602,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_sockpair_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -11065,6 +11253,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_sockpair+trace_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -11716,6 +11925,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_sockpair_1byte_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -12447,6 +12677,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_ssl_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -13159,6 +13411,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_ssl_proxy_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -13815,6 +14088,26 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_uds_test",
+ "platforms": [
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -14547,6 +14840,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_census_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -15317,6 +15632,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_compress_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -16087,6 +16424,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_full_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -16761,6 +17120,22 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "linux"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_full+pipe_nosec_test",
+ "platforms": [
+ "linux"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -17395,6 +17770,28 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_full+trace_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -18086,6 +18483,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_proxy_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -18695,6 +19113,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_sockpair_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -19304,6 +19743,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_sockpair+trace_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -19934,6 +20394,27 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "windows",
+ "linux",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_sockpair_1byte_nosec_test",
+ "platforms": [
+ "windows",
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
@@ -20591,6 +21072,26 @@
},
{
"args": [
+ "idempotent_request"
+ ],
+ "ci_platforms": [
+ "linux",
+ "mac",
+ "posix"
+ ],
+ "cpu_cost": 1.0,
+ "exclude_configs": [],
+ "flaky": false,
+ "language": "c",
+ "name": "h2_uds_nosec_test",
+ "platforms": [
+ "linux",
+ "mac",
+ "posix"
+ ]
+ },
+ {
+ "args": [
"invoke_large_request"
],
"ci_platforms": [
diff --git a/vsprojects/build_vs2010.bat b/vsprojects/build_vs2010.bat
index 64b0ed5d3f..1bc3c86a92 100644
--- a/vsprojects/build_vs2010.bat
+++ b/vsprojects/build_vs2010.bat
@@ -1,5 +1,5 @@
@rem Convenience wrapper that runs specified gRPC target using msbuild
-@rem Usage: build.bat TARGET_NAME
+@rem Usage: build_vs2010.bat TARGET_NAME
setlocal
@rem Set VS variables (uses Visual Studio 2010)
diff --git a/vsprojects/build_vs2013.bat b/vsprojects/build_vs2013.bat
index be3caa9298..82c0a3ad82 100644
--- a/vsprojects/build_vs2013.bat
+++ b/vsprojects/build_vs2013.bat
@@ -1,5 +1,5 @@
@rem Convenience wrapper that runs specified gRPC target using msbuild
-@rem Usage: build.bat TARGET_NAME
+@rem Usage: build_vs2013.bat TARGET_NAME
setlocal
@rem Set VS variables (uses Visual Studio 2013)
diff --git a/vsprojects/build_vs2015.bat b/vsprojects/build_vs2015.bat
index 50485a30f3..c6e1b433a3 100644
--- a/vsprojects/build_vs2015.bat
+++ b/vsprojects/build_vs2015.bat
@@ -1,5 +1,5 @@
@rem Convenience wrapper that runs specified gRPC target using msbuild
-@rem Usage: build.bat TARGET_NAME
+@rem Usage: build_vs2015.bat TARGET_NAME
setlocal
@rem Set VS variables (uses Visual Studio 2015)
diff --git a/vsprojects/buildtests_c.sln b/vsprojects/buildtests_c.sln
index 96dc4eb107..f736c86739 100644
--- a/vsprojects/buildtests_c.sln
+++ b/vsprojects/buildtests_c.sln
@@ -696,6 +696,39 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "init_test", "vcxproj\test\i
{B23D3D1A-9438-4EDA-BEB6-9A0A03D17792} = {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}
EndProjectSection
EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "internal_api_canary_iomgr_test", "vcxproj\test\internal_api_canary_iomgr_test\internal_api_canary_iomgr_test.vcxproj", "{28AE726B-1BFB-202B-48D2-41AF9D09B9EA}"
+ ProjectSection(myProperties) = preProject
+ lib = "False"
+ EndProjectSection
+ ProjectSection(ProjectDependencies) = postProject
+ {17BCAFC0-5FDC-4C94-AEB9-95F3E220614B} = {17BCAFC0-5FDC-4C94-AEB9-95F3E220614B}
+ {29D16885-7228-4C31-81ED-5F9187C7F2A9} = {29D16885-7228-4C31-81ED-5F9187C7F2A9}
+ {EAB0A629-17A9-44DB-B5FF-E91A721FE037} = {EAB0A629-17A9-44DB-B5FF-E91A721FE037}
+ {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792} = {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "internal_api_canary_support_test", "vcxproj\test\internal_api_canary_support_test\internal_api_canary_support_test.vcxproj", "{D53575C6-713C-E6E3-FD74-E65F20916498}"
+ ProjectSection(myProperties) = preProject
+ lib = "False"
+ EndProjectSection
+ ProjectSection(ProjectDependencies) = postProject
+ {17BCAFC0-5FDC-4C94-AEB9-95F3E220614B} = {17BCAFC0-5FDC-4C94-AEB9-95F3E220614B}
+ {29D16885-7228-4C31-81ED-5F9187C7F2A9} = {29D16885-7228-4C31-81ED-5F9187C7F2A9}
+ {EAB0A629-17A9-44DB-B5FF-E91A721FE037} = {EAB0A629-17A9-44DB-B5FF-E91A721FE037}
+ {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792} = {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}
+ EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "internal_api_canary_transport_test", "vcxproj\test\internal_api_canary_transport_test\internal_api_canary_transport_test.vcxproj", "{ED24E700-964E-B426-6A6A-1944E2EF7BCB}"
+ ProjectSection(myProperties) = preProject
+ lib = "False"
+ EndProjectSection
+ ProjectSection(ProjectDependencies) = postProject
+ {17BCAFC0-5FDC-4C94-AEB9-95F3E220614B} = {17BCAFC0-5FDC-4C94-AEB9-95F3E220614B}
+ {29D16885-7228-4C31-81ED-5F9187C7F2A9} = {29D16885-7228-4C31-81ED-5F9187C7F2A9}
+ {EAB0A629-17A9-44DB-B5FF-E91A721FE037} = {EAB0A629-17A9-44DB-B5FF-E91A721FE037}
+ {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792} = {B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}
+ EndProjectSection
+EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "invalid_call_argument_test", "vcxproj\test\invalid_call_argument_test\invalid_call_argument_test.vcxproj", "{C32CA8A3-58E6-8EB9-B72F-C295547D36A6}"
ProjectSection(myProperties) = preProject
lib = "False"
@@ -2453,6 +2486,54 @@ Global
{117CA7AD-C42B-9217-6C95-42A801777BC5}.Release-DLL|Win32.Build.0 = Release|Win32
{117CA7AD-C42B-9217-6C95-42A801777BC5}.Release-DLL|x64.ActiveCfg = Release|x64
{117CA7AD-C42B-9217-6C95-42A801777BC5}.Release-DLL|x64.Build.0 = Release|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug|Win32.ActiveCfg = Debug|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug|x64.ActiveCfg = Debug|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release|Win32.ActiveCfg = Release|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release|x64.ActiveCfg = Release|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug|Win32.Build.0 = Debug|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug|x64.Build.0 = Debug|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release|Win32.Build.0 = Release|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release|x64.Build.0 = Release|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug-DLL|Win32.ActiveCfg = Debug|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug-DLL|Win32.Build.0 = Debug|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug-DLL|x64.ActiveCfg = Debug|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Debug-DLL|x64.Build.0 = Debug|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release-DLL|Win32.ActiveCfg = Release|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release-DLL|Win32.Build.0 = Release|Win32
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release-DLL|x64.ActiveCfg = Release|x64
+ {28AE726B-1BFB-202B-48D2-41AF9D09B9EA}.Release-DLL|x64.Build.0 = Release|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug|Win32.ActiveCfg = Debug|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug|x64.ActiveCfg = Debug|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release|Win32.ActiveCfg = Release|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release|x64.ActiveCfg = Release|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug|Win32.Build.0 = Debug|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug|x64.Build.0 = Debug|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release|Win32.Build.0 = Release|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release|x64.Build.0 = Release|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug-DLL|Win32.ActiveCfg = Debug|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug-DLL|Win32.Build.0 = Debug|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug-DLL|x64.ActiveCfg = Debug|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Debug-DLL|x64.Build.0 = Debug|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release-DLL|Win32.ActiveCfg = Release|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release-DLL|Win32.Build.0 = Release|Win32
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release-DLL|x64.ActiveCfg = Release|x64
+ {D53575C6-713C-E6E3-FD74-E65F20916498}.Release-DLL|x64.Build.0 = Release|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug|Win32.ActiveCfg = Debug|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug|x64.ActiveCfg = Debug|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release|Win32.ActiveCfg = Release|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release|x64.ActiveCfg = Release|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug|Win32.Build.0 = Debug|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug|x64.Build.0 = Debug|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release|Win32.Build.0 = Release|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release|x64.Build.0 = Release|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug-DLL|Win32.ActiveCfg = Debug|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug-DLL|Win32.Build.0 = Debug|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug-DLL|x64.ActiveCfg = Debug|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Debug-DLL|x64.Build.0 = Debug|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release-DLL|Win32.ActiveCfg = Release|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release-DLL|Win32.Build.0 = Release|Win32
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release-DLL|x64.ActiveCfg = Release|x64
+ {ED24E700-964E-B426-6A6A-1944E2EF7BCB}.Release-DLL|x64.Build.0 = Release|x64
{C32CA8A3-58E6-8EB9-B72F-C295547D36A6}.Debug|Win32.ActiveCfg = Debug|Win32
{C32CA8A3-58E6-8EB9-B72F-C295547D36A6}.Debug|x64.ActiveCfg = Debug|x64
{C32CA8A3-58E6-8EB9-B72F-C295547D36A6}.Release|Win32.ActiveCfg = Release|Win32
diff --git a/vsprojects/vcxproj/grpc/grpc.vcxproj b/vsprojects/vcxproj/grpc/grpc.vcxproj
index 809a822df3..8fc20626b7 100644
--- a/vsprojects/vcxproj/grpc/grpc.vcxproj
+++ b/vsprojects/vcxproj/grpc/grpc.vcxproj
@@ -282,6 +282,8 @@
<ClInclude Include="$(SolutionDir)\..\include\grpc\status.h" />
</ItemGroup>
<ItemGroup>
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.h" />
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\alpn.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\bin_encoder.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\chttp2_transport.h" />
@@ -321,9 +323,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\client_config.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\connector.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy_factory.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy_registry.h" />
@@ -355,9 +354,7 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\iomgr_internal.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\iomgr_posix.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_posix.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_posix.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_windows.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_windows.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\resolve_address.h" />
@@ -385,7 +382,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_common.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_reader.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_writer.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\security\auth_filters.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\security\b64.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\security\credentials.h" />
@@ -427,6 +423,14 @@
<ClInclude Include="$(SolutionDir)\..\third_party\nanopb\pb_encode.h" />
</ItemGroup>
<ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.c">
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.c">
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\pick_first\pick_first.c">
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\round_robin\round_robin.c">
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\client\insecure\channel_create.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\client\secure\secure_channel_create.c">
@@ -521,12 +525,6 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.c">
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.c">
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.c">
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.c">
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy_factory.c">
@@ -653,8 +651,6 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\json\json_writer.c">
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.c">
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\security\b64.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\security\client_auth_filter.c">
@@ -745,6 +741,8 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\tsi\transport_security.c">
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_plugin_registry.c">
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\third_party\nanopb\pb_common.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\third_party\nanopb\pb_decode.c">
diff --git a/vsprojects/vcxproj/grpc/grpc.vcxproj.filters b/vsprojects/vcxproj/grpc/grpc.vcxproj.filters
index 25dc242a29..c6a8114836 100644
--- a/vsprojects/vcxproj/grpc/grpc.vcxproj.filters
+++ b/vsprojects/vcxproj/grpc/grpc.vcxproj.filters
@@ -1,6 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.c">
+ <Filter>src\core\ext\lb_policy\grpclb</Filter>
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.c">
+ <Filter>src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0</Filter>
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\pick_first\pick_first.c">
+ <Filter>src\core\ext\lb_policy\pick_first</Filter>
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\round_robin\round_robin.c">
+ <Filter>src\core\ext\lb_policy\round_robin</Filter>
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\client\insecure\channel_create.c">
<Filter>src\core\ext\transport\chttp2\client\insecure</Filter>
</ClCompile>
@@ -142,15 +154,6 @@
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.c">
<Filter>src\core\lib\client_config</Filter>
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.c">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.c">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.c">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.c">
<Filter>src\core\lib\client_config</Filter>
</ClCompile>
@@ -340,9 +343,6 @@
<ClCompile Include="$(SolutionDir)\..\src\core\lib\json\json_writer.c">
<Filter>src\core\lib\json</Filter>
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.c">
- <Filter>src\core\lib\proto\grpc\lb\v0</Filter>
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\security\b64.c">
<Filter>src\core\lib\security</Filter>
</ClCompile>
@@ -478,6 +478,9 @@
<ClCompile Include="$(SolutionDir)\..\src\core\lib\tsi\transport_security.c">
<Filter>src\core\lib\tsi</Filter>
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_plugin_registry.c">
+ <Filter>src\core\plugin_registry</Filter>
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\third_party\nanopb\pb_common.c">
<Filter>third_party\nanopb</Filter>
</ClCompile>
@@ -530,6 +533,12 @@
</ClInclude>
</ItemGroup>
<ItemGroup>
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.h">
+ <Filter>src\core\ext\lb_policy\grpclb</Filter>
+ </ClInclude>
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.h">
+ <Filter>src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0</Filter>
+ </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\alpn.h">
<Filter>src\core\ext\transport\chttp2\transport</Filter>
</ClInclude>
@@ -647,15 +656,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.h">
<Filter>src\core\lib\client_config</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.h">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.h">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.h">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.h">
<Filter>src\core\lib\client_config</Filter>
</ClInclude>
@@ -749,15 +749,9 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset.h">
<Filter>src\core\lib\iomgr</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_posix.h">
- <Filter>src\core\lib\iomgr</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set.h">
<Filter>src\core\lib\iomgr</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_posix.h">
- <Filter>src\core\lib\iomgr</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_windows.h">
<Filter>src\core\lib\iomgr</Filter>
</ClInclude>
@@ -839,9 +833,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_writer.h">
<Filter>src\core\lib\json</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.h">
- <Filter>src\core\lib\proto\grpc\lb\v0</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\security\auth_filters.h">
<Filter>src\core\lib\security</Filter>
</ClInclude>
@@ -983,6 +974,30 @@
<Filter Include="src\core\ext">
<UniqueIdentifier>{3f32a58f-394f-5f13-06aa-6cc52cc2daaf}</UniqueIdentifier>
</Filter>
+ <Filter Include="src\core\ext\lb_policy">
+ <UniqueIdentifier>{030f00ff-6c54-76c8-12df-37e3008335d1}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb">
+ <UniqueIdentifier>{fe41339e-53fb-39b3-7457-7a0fbb238dbe}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto">
+ <UniqueIdentifier>{a7c27f6b-6d15-01cf-76d9-c30dddea0990}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto\grpc">
+ <UniqueIdentifier>{bc714e6d-8aba-91df-7db9-7f189f05a6ff}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto\grpc\lb">
+ <UniqueIdentifier>{adf7e553-94ef-14fd-e845-03104f00a06f}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0">
+ <UniqueIdentifier>{0406d191-8817-38c3-a562-e3541201f424}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\pick_first">
+ <UniqueIdentifier>{b63ded00-b24f-708e-333f-ce199e421875}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\round_robin">
+ <UniqueIdentifier>{2472d352-cf94-f317-646e-72b769cea846}</UniqueIdentifier>
+ </Filter>
<Filter Include="src\core\ext\transport">
<UniqueIdentifier>{e3abfd0a-064e-0f2f-c8e8-7c5a7e98142a}</UniqueIdentifier>
</Filter>
@@ -1022,9 +1037,6 @@
<Filter Include="src\core\lib\client_config">
<UniqueIdentifier>{2f3260de-be57-d18d-6882-61d115baa159}</UniqueIdentifier>
</Filter>
- <Filter Include="src\core\lib\client_config\lb_policies">
- <UniqueIdentifier>{118d2bb5-086f-54f3-11de-26d7d7f73f9d}</UniqueIdentifier>
- </Filter>
<Filter Include="src\core\lib\client_config\resolvers">
<UniqueIdentifier>{b9d8db6c-2c68-1c90-fe5e-37da90f47ae6}</UniqueIdentifier>
</Filter>
@@ -1043,18 +1055,6 @@
<Filter Include="src\core\lib\json">
<UniqueIdentifier>{cb2b0073-f2a7-5c63-d182-8874b24bdf36}</UniqueIdentifier>
</Filter>
- <Filter Include="src\core\lib\proto">
- <UniqueIdentifier>{b4b19f9a-1575-8a21-0bca-537746f858b7}</UniqueIdentifier>
- </Filter>
- <Filter Include="src\core\lib\proto\grpc">
- <UniqueIdentifier>{cbc8ce67-4a97-d533-8dc3-f949c63e2771}</UniqueIdentifier>
- </Filter>
- <Filter Include="src\core\lib\proto\grpc\lb">
- <UniqueIdentifier>{933530ae-447b-ea8d-3531-98f0556960b0}</UniqueIdentifier>
- </Filter>
- <Filter Include="src\core\lib\proto\grpc\lb\v0">
- <UniqueIdentifier>{c33f944f-37d4-42fd-abc3-61f0d4400462}</UniqueIdentifier>
- </Filter>
<Filter Include="src\core\lib\security">
<UniqueIdentifier>{c4661d64-349f-01c1-1ba8-0602f9047595}</UniqueIdentifier>
</Filter>
@@ -1070,6 +1070,9 @@
<Filter Include="src\core\lib\tsi">
<UniqueIdentifier>{95ad2811-c8d0-7a42-2a73-baf03fcbf699}</UniqueIdentifier>
</Filter>
+ <Filter Include="src\core\plugin_registry">
+ <UniqueIdentifier>{02bec99b-ff39-88d7-9dea-e0ff9f4a2701}</UniqueIdentifier>
+ </Filter>
<Filter Include="third_party">
<UniqueIdentifier>{aaab30a4-2a15-732e-c141-3fbc0f0f5a7a}</UniqueIdentifier>
</Filter>
diff --git a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj
index a5cf362629..7a2abdea6b 100644
--- a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj
+++ b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj
@@ -272,6 +272,8 @@
<ClInclude Include="$(SolutionDir)\..\include\grpc\status.h" />
</ItemGroup>
<ItemGroup>
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.h" />
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\alpn.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\bin_encoder.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\chttp2_transport.h" />
@@ -311,9 +313,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\client_config.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\connector.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy_factory.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy_registry.h" />
@@ -345,9 +344,7 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\iomgr_internal.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\iomgr_posix.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_posix.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_posix.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_windows.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_windows.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\resolve_address.h" />
@@ -375,7 +372,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_common.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_reader.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_writer.h" />
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\statistics\census_interface.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\statistics\census_rpc_stats.h" />
<ClInclude Include="$(SolutionDir)\..\src\core\lib\surface\api_trace.h" />
@@ -403,6 +399,14 @@
<ClInclude Include="$(SolutionDir)\..\third_party\nanopb\pb_encode.h" />
</ItemGroup>
<ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.c">
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.c">
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\pick_first\pick_first.c">
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\round_robin\round_robin.c">
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\client\insecure\channel_create.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\server\insecure\server_chttp2.c">
@@ -493,12 +497,6 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.c">
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.c">
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.c">
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.c">
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy_factory.c">
@@ -623,8 +621,6 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\json\json_writer.c">
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.c">
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\surface\alarm.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\surface\api_trace.c">
@@ -681,6 +677,8 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\transport\transport_op_string.c">
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_unsecure_plugin_registry.c">
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\third_party\nanopb\pb_common.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\third_party\nanopb\pb_decode.c">
diff --git a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters
index a4e6a79ff8..20b8ffd36e 100644
--- a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters
+++ b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters
@@ -1,6 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.c">
+ <Filter>src\core\ext\lb_policy\grpclb</Filter>
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.c">
+ <Filter>src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0</Filter>
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\pick_first\pick_first.c">
+ <Filter>src\core\ext\lb_policy\pick_first</Filter>
+ </ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\ext\lb_policy\round_robin\round_robin.c">
+ <Filter>src\core\ext\lb_policy\round_robin</Filter>
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\client\insecure\channel_create.c">
<Filter>src\core\ext\transport\chttp2\client\insecure</Filter>
</ClCompile>
@@ -136,15 +148,6 @@
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.c">
<Filter>src\core\lib\client_config</Filter>
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.c">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.c">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.c">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.c">
<Filter>src\core\lib\client_config</Filter>
</ClCompile>
@@ -331,9 +334,6 @@
<ClCompile Include="$(SolutionDir)\..\src\core\lib\json\json_writer.c">
<Filter>src\core\lib\json</Filter>
</ClCompile>
- <ClCompile Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.c">
- <Filter>src\core\lib\proto\grpc\lb\v0</Filter>
- </ClCompile>
<ClCompile Include="$(SolutionDir)\..\src\core\lib\surface\alarm.c">
<Filter>src\core\lib\surface</Filter>
</ClCompile>
@@ -418,6 +418,9 @@
<ClCompile Include="$(SolutionDir)\..\src\core\lib\transport\transport_op_string.c">
<Filter>src\core\lib\transport</Filter>
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_unsecure_plugin_registry.c">
+ <Filter>src\core\plugin_registry</Filter>
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\third_party\nanopb\pb_common.c">
<Filter>third_party\nanopb</Filter>
</ClCompile>
@@ -467,6 +470,12 @@
</ClInclude>
</ItemGroup>
<ItemGroup>
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\load_balancer_api.h">
+ <Filter>src\core\ext\lb_policy\grpclb</Filter>
+ </ClInclude>
+ <ClInclude Include="$(SolutionDir)\..\src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0\load_balancer.pb.h">
+ <Filter>src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0</Filter>
+ </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\ext\transport\chttp2\transport\alpn.h">
<Filter>src\core\ext\transport\chttp2\transport</Filter>
</ClInclude>
@@ -584,15 +593,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\initial_connect_string.h">
<Filter>src\core\lib\client_config</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\load_balancer_api.h">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\pick_first.h">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policies\round_robin.h">
- <Filter>src\core\lib\client_config\lb_policies</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\client_config\lb_policy.h">
<Filter>src\core\lib\client_config</Filter>
</ClInclude>
@@ -686,15 +686,9 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset.h">
<Filter>src\core\lib\iomgr</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_posix.h">
- <Filter>src\core\lib\iomgr</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set.h">
<Filter>src\core\lib\iomgr</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_posix.h">
- <Filter>src\core\lib\iomgr</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\iomgr\pollset_set_windows.h">
<Filter>src\core\lib\iomgr</Filter>
</ClInclude>
@@ -776,9 +770,6 @@
<ClInclude Include="$(SolutionDir)\..\src\core\lib\json\json_writer.h">
<Filter>src\core\lib\json</Filter>
</ClInclude>
- <ClInclude Include="$(SolutionDir)\..\src\core\lib\proto\grpc\lb\v0\load_balancer.pb.h">
- <Filter>src\core\lib\proto\grpc\lb\v0</Filter>
- </ClInclude>
<ClInclude Include="$(SolutionDir)\..\src\core\lib\statistics\census_interface.h">
<Filter>src\core\lib\statistics</Filter>
</ClInclude>
@@ -878,6 +869,30 @@
<Filter Include="src\core\ext">
<UniqueIdentifier>{82f86e8c-00a4-f566-d235-670fc629798d}</UniqueIdentifier>
</Filter>
+ <Filter Include="src\core\ext\lb_policy">
+ <UniqueIdentifier>{a23781d2-27e4-7cb0-12cd-59782ecb21ce}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb">
+ <UniqueIdentifier>{25a465c8-d1e8-6248-c005-bb2062206472}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto">
+ <UniqueIdentifier>{40fc2615-d244-0d36-4486-ba6f0fa468bb}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto\grpc">
+ <UniqueIdentifier>{1d129f24-a399-12ef-68de-023aff7dde52}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto\grpc\lb">
+ <UniqueIdentifier>{21858d9d-30b5-8847-5882-6b47df0fa293}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\grpclb\proto\grpc\lb\v0">
+ <UniqueIdentifier>{1795a20b-3e7c-e27d-eae1-96582fa9a958}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\pick_first">
+ <UniqueIdentifier>{e27f9ecf-97bb-1a2e-3135-a41f732dcf55}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="src\core\ext\lb_policy\round_robin">
+ <UniqueIdentifier>{e5fc1091-5d60-404f-775b-686ef4b3266f}</UniqueIdentifier>
+ </Filter>
<Filter Include="src\core\ext\transport">
<UniqueIdentifier>{967c89fe-c97c-27e2-aac0-9ba5854cb5fa}</UniqueIdentifier>
</Filter>
@@ -911,9 +926,6 @@
<Filter Include="src\core\lib\client_config">
<UniqueIdentifier>{29ca2974-89e4-1a74-3e4d-0d63e2f77566}</UniqueIdentifier>
</Filter>
- <Filter Include="src\core\lib\client_config\lb_policies">
- <UniqueIdentifier>{6c7e36d4-6117-e0cd-c886-b9eb3c994927}</UniqueIdentifier>
- </Filter>
<Filter Include="src\core\lib\client_config\resolvers">
<UniqueIdentifier>{2d959ef9-9703-dc92-a56f-9fe136dadfb9}</UniqueIdentifier>
</Filter>
@@ -932,18 +944,6 @@
<Filter Include="src\core\lib\json">
<UniqueIdentifier>{681cdaeb-c47f-8853-d985-bf13c2873947}</UniqueIdentifier>
</Filter>
- <Filter Include="src\core\lib\proto">
- <UniqueIdentifier>{4bfbd6c6-f6a8-c6b3-5186-b788f4e11e23}</UniqueIdentifier>
- </Filter>
- <Filter Include="src\core\lib\proto\grpc">
- <UniqueIdentifier>{60f3ab7d-ea44-348f-671e-77fdebbd18bb}</UniqueIdentifier>
- </Filter>
- <Filter Include="src\core\lib\proto\grpc\lb">
- <UniqueIdentifier>{bcd33510-32e7-c2fb-e11d-a3655f97bc84}</UniqueIdentifier>
- </Filter>
- <Filter Include="src\core\lib\proto\grpc\lb\v0">
- <UniqueIdentifier>{bb9b8c80-9eff-5ab6-5b29-c2d54f0fc192}</UniqueIdentifier>
- </Filter>
<Filter Include="src\core\lib\statistics">
<UniqueIdentifier>{d0ab6d54-ae25-fc49-3656-91d9db57366a}</UniqueIdentifier>
</Filter>
@@ -953,6 +953,9 @@
<Filter Include="src\core\lib\transport">
<UniqueIdentifier>{6c3394d1-27e9-003e-19ed-8116d210f7cc}</UniqueIdentifier>
</Filter>
+ <Filter Include="src\core\plugin_registry">
+ <UniqueIdentifier>{babf0a90-e934-f599-5475-e6937d9580fe}</UniqueIdentifier>
+ </Filter>
<Filter Include="third_party">
<UniqueIdentifier>{025c051e-8eba-125b-67f9-173f95176eb2}</UniqueIdentifier>
</Filter>
diff --git a/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj b/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj
index 568a0515aa..d54d21b66e 100644
--- a/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj
+++ b/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj
@@ -185,6 +185,8 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\hpack_size.c">
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\idempotent_request.c">
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\invoke_large_request.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\large_metadata.c">
diff --git a/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj.filters b/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj.filters
index ecc23e868d..99622e228d 100644
--- a/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj.filters
+++ b/vsprojects/vcxproj/test/end2end/tests/end2end_nosec_tests/end2end_nosec_tests.vcxproj.filters
@@ -52,6 +52,9 @@
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\hpack_size.c">
<Filter>test\core\end2end\tests</Filter>
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\idempotent_request.c">
+ <Filter>test\core\end2end\tests</Filter>
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\invoke_large_request.c">
<Filter>test\core\end2end\tests</Filter>
</ClCompile>
diff --git a/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj b/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj
index 3e0092ef87..c0b21c9ae1 100644
--- a/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj
+++ b/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj
@@ -187,6 +187,8 @@
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\hpack_size.c">
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\idempotent_request.c">
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\invoke_large_request.c">
</ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\large_metadata.c">
diff --git a/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj.filters b/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj.filters
index c3aabc48a0..791589863e 100644
--- a/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj.filters
+++ b/vsprojects/vcxproj/test/end2end/tests/end2end_tests/end2end_tests.vcxproj.filters
@@ -55,6 +55,9 @@
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\hpack_size.c">
<Filter>test\core\end2end\tests</Filter>
</ClCompile>
+ <ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\idempotent_request.c">
+ <Filter>test\core\end2end\tests</Filter>
+ </ClCompile>
<ClCompile Include="$(SolutionDir)\..\test\core\end2end\tests\invoke_large_request.c">
<Filter>test\core\end2end\tests</Filter>
</ClCompile>
diff --git a/vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj b/vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj
new file mode 100644
index 0000000000..11d89a01c1
--- /dev/null
+++ b/vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\1.0.204.1.props')" />
+ <ItemGroup Label="ProjectConfigurations">
+ <ProjectConfiguration Include="Debug|Win32">
+ <Configuration>Debug</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Debug|x64">
+ <Configuration>Debug</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|Win32">
+ <Configuration>Release</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|x64">
+ <Configuration>Release</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ </ItemGroup>
+ <PropertyGroup Label="Globals">
+ <ProjectGuid>{28AE726B-1BFB-202B-48D2-41AF9D09B9EA}</ProjectGuid>
+ <IgnoreWarnIntDirInTempDetected>true</IgnoreWarnIntDirInTempDetected>
+ <IntDir>$(SolutionDir)IntDir\$(MSBuildProjectName)\</IntDir>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '10.0'" Label="Configuration">
+ <PlatformToolset>v100</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '11.0'" Label="Configuration">
+ <PlatformToolset>v110</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '12.0'" Label="Configuration">
+ <PlatformToolset>v120</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '14.0'" Label="Configuration">
+ <PlatformToolset>v140</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Debug'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>true</UseDebugLibraries>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Release'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>false</UseDebugLibraries>
+ <WholeProgramOptimization>true</WholeProgramOptimization>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+ <ImportGroup Label="ExtensionSettings">
+ </ImportGroup>
+ <ImportGroup Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ <Import Project="$(SolutionDir)\..\vsprojects\global.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\openssl.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\winsock.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\zlib.props" />
+ </ImportGroup>
+ <PropertyGroup Label="UserMacros" />
+ <PropertyGroup Condition="'$(Configuration)'=='Debug'">
+ <TargetName>internal_api_canary_iomgr_test</TargetName>
+ <Linkage-grpc_dependencies_zlib>static</Linkage-grpc_dependencies_zlib>
+ <Configuration-grpc_dependencies_zlib>Debug</Configuration-grpc_dependencies_zlib>
+ <Linkage-grpc_dependencies_openssl>static</Linkage-grpc_dependencies_openssl>
+ <Configuration-grpc_dependencies_openssl>Debug</Configuration-grpc_dependencies_openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Release'">
+ <TargetName>internal_api_canary_iomgr_test</TargetName>
+ <Linkage-grpc_dependencies_zlib>static</Linkage-grpc_dependencies_zlib>
+ <Configuration-grpc_dependencies_zlib>Release</Configuration-grpc_dependencies_zlib>
+ <Linkage-grpc_dependencies_openssl>static</Linkage-grpc_dependencies_openssl>
+ <Configuration-grpc_dependencies_openssl>Release</Configuration-grpc_dependencies_openssl>
+ </PropertyGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>Disabled</Optimization>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>Disabled</Optimization>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>MaxSpeed</Optimization>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <OptimizeReferences>true</OptimizeReferences>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>MaxSpeed</Optimization>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <OptimizeReferences>true</OptimizeReferences>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\test\core\internal_api_canaries\iomgr.c">
+ </ClCompile>
+ </ItemGroup>
+ <ItemGroup>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\grpc_test_util\grpc_test_util.vcxproj">
+ <Project>{17BCAFC0-5FDC-4C94-AEB9-95F3E220614B}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\grpc\grpc.vcxproj">
+ <Project>{29D16885-7228-4C31-81ED-5F9187C7F2A9}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\gpr_test_util\gpr_test_util.vcxproj">
+ <Project>{EAB0A629-17A9-44DB-B5FF-E91A721FE037}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\gpr\gpr.vcxproj">
+ <Project>{B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}</Project>
+ </ProjectReference>
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="packages.config" />
+ </ItemGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+ <ImportGroup Label="ExtensionTargets">
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies\grpc.dependencies.zlib.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies\grpc.dependencies.zlib.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies\grpc.dependencies.openssl.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies\grpc.dependencies.openssl.targets')" />
+ </ImportGroup>
+ <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
+ <PropertyGroup>
+ <ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
+ </PropertyGroup>
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets')" />
+ </Target>
+</Project>
+
diff --git a/vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj.filters b/vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj.filters
new file mode 100644
index 0000000000..f1ee82d1f4
--- /dev/null
+++ b/vsprojects/vcxproj/test/internal_api_canary_iomgr_test/internal_api_canary_iomgr_test.vcxproj.filters
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\test\core\internal_api_canaries\iomgr.c">
+ <Filter>test\core\internal_api_canaries</Filter>
+ </ClCompile>
+ </ItemGroup>
+
+ <ItemGroup>
+ <Filter Include="test">
+ <UniqueIdentifier>{881986d1-d1fe-b377-cf26-b3377af95009}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="test\core">
+ <UniqueIdentifier>{4f9a544e-5680-18ee-30d7-38179bf82cee}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="test\core\internal_api_canaries">
+ <UniqueIdentifier>{6ab29f78-ec9d-d63a-8e8f-0d7552b3edd4}</UniqueIdentifier>
+ </Filter>
+ </ItemGroup>
+</Project>
+
diff --git a/vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj b/vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj
new file mode 100644
index 0000000000..59092dc2b3
--- /dev/null
+++ b/vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\1.0.204.1.props')" />
+ <ItemGroup Label="ProjectConfigurations">
+ <ProjectConfiguration Include="Debug|Win32">
+ <Configuration>Debug</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Debug|x64">
+ <Configuration>Debug</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|Win32">
+ <Configuration>Release</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|x64">
+ <Configuration>Release</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ </ItemGroup>
+ <PropertyGroup Label="Globals">
+ <ProjectGuid>{D53575C6-713C-E6E3-FD74-E65F20916498}</ProjectGuid>
+ <IgnoreWarnIntDirInTempDetected>true</IgnoreWarnIntDirInTempDetected>
+ <IntDir>$(SolutionDir)IntDir\$(MSBuildProjectName)\</IntDir>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '10.0'" Label="Configuration">
+ <PlatformToolset>v100</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '11.0'" Label="Configuration">
+ <PlatformToolset>v110</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '12.0'" Label="Configuration">
+ <PlatformToolset>v120</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '14.0'" Label="Configuration">
+ <PlatformToolset>v140</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Debug'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>true</UseDebugLibraries>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Release'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>false</UseDebugLibraries>
+ <WholeProgramOptimization>true</WholeProgramOptimization>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+ <ImportGroup Label="ExtensionSettings">
+ </ImportGroup>
+ <ImportGroup Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ <Import Project="$(SolutionDir)\..\vsprojects\global.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\openssl.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\winsock.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\zlib.props" />
+ </ImportGroup>
+ <PropertyGroup Label="UserMacros" />
+ <PropertyGroup Condition="'$(Configuration)'=='Debug'">
+ <TargetName>internal_api_canary_support_test</TargetName>
+ <Linkage-grpc_dependencies_zlib>static</Linkage-grpc_dependencies_zlib>
+ <Configuration-grpc_dependencies_zlib>Debug</Configuration-grpc_dependencies_zlib>
+ <Linkage-grpc_dependencies_openssl>static</Linkage-grpc_dependencies_openssl>
+ <Configuration-grpc_dependencies_openssl>Debug</Configuration-grpc_dependencies_openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Release'">
+ <TargetName>internal_api_canary_support_test</TargetName>
+ <Linkage-grpc_dependencies_zlib>static</Linkage-grpc_dependencies_zlib>
+ <Configuration-grpc_dependencies_zlib>Release</Configuration-grpc_dependencies_zlib>
+ <Linkage-grpc_dependencies_openssl>static</Linkage-grpc_dependencies_openssl>
+ <Configuration-grpc_dependencies_openssl>Release</Configuration-grpc_dependencies_openssl>
+ </PropertyGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>Disabled</Optimization>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>Disabled</Optimization>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>MaxSpeed</Optimization>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <OptimizeReferences>true</OptimizeReferences>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>MaxSpeed</Optimization>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <OptimizeReferences>true</OptimizeReferences>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\test\core\internal_api_canaries\iomgr.c">
+ </ClCompile>
+ </ItemGroup>
+ <ItemGroup>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\grpc_test_util\grpc_test_util.vcxproj">
+ <Project>{17BCAFC0-5FDC-4C94-AEB9-95F3E220614B}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\grpc\grpc.vcxproj">
+ <Project>{29D16885-7228-4C31-81ED-5F9187C7F2A9}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\gpr_test_util\gpr_test_util.vcxproj">
+ <Project>{EAB0A629-17A9-44DB-B5FF-E91A721FE037}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\gpr\gpr.vcxproj">
+ <Project>{B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}</Project>
+ </ProjectReference>
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="packages.config" />
+ </ItemGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+ <ImportGroup Label="ExtensionTargets">
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies\grpc.dependencies.zlib.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies\grpc.dependencies.zlib.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies\grpc.dependencies.openssl.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies\grpc.dependencies.openssl.targets')" />
+ </ImportGroup>
+ <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
+ <PropertyGroup>
+ <ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
+ </PropertyGroup>
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets')" />
+ </Target>
+</Project>
+
diff --git a/vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj.filters b/vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj.filters
new file mode 100644
index 0000000000..f7f4e3200e
--- /dev/null
+++ b/vsprojects/vcxproj/test/internal_api_canary_support_test/internal_api_canary_support_test.vcxproj.filters
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\test\core\internal_api_canaries\iomgr.c">
+ <Filter>test\core\internal_api_canaries</Filter>
+ </ClCompile>
+ </ItemGroup>
+
+ <ItemGroup>
+ <Filter Include="test">
+ <UniqueIdentifier>{a6c31cba-af9d-78ea-8980-8b77c9fc4485}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="test\core">
+ <UniqueIdentifier>{d84283b8-4529-6c09-18bf-20a69f14f7ab}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="test\core\internal_api_canaries">
+ <UniqueIdentifier>{ea379f93-9285-7180-0d69-24a56da2b201}</UniqueIdentifier>
+ </Filter>
+ </ItemGroup>
+</Project>
+
diff --git a/vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj b/vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj
new file mode 100644
index 0000000000..110f7e3b04
--- /dev/null
+++ b/vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\1.0.204.1.props')" />
+ <ItemGroup Label="ProjectConfigurations">
+ <ProjectConfiguration Include="Debug|Win32">
+ <Configuration>Debug</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Debug|x64">
+ <Configuration>Debug</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|Win32">
+ <Configuration>Release</Configuration>
+ <Platform>Win32</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|x64">
+ <Configuration>Release</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ </ItemGroup>
+ <PropertyGroup Label="Globals">
+ <ProjectGuid>{ED24E700-964E-B426-6A6A-1944E2EF7BCB}</ProjectGuid>
+ <IgnoreWarnIntDirInTempDetected>true</IgnoreWarnIntDirInTempDetected>
+ <IntDir>$(SolutionDir)IntDir\$(MSBuildProjectName)\</IntDir>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '10.0'" Label="Configuration">
+ <PlatformToolset>v100</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '11.0'" Label="Configuration">
+ <PlatformToolset>v110</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '12.0'" Label="Configuration">
+ <PlatformToolset>v120</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(VisualStudioVersion)' == '14.0'" Label="Configuration">
+ <PlatformToolset>v140</PlatformToolset>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Debug'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>true</UseDebugLibraries>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Release'" Label="Configuration">
+ <ConfigurationType>Application</ConfigurationType>
+ <UseDebugLibraries>false</UseDebugLibraries>
+ <WholeProgramOptimization>true</WholeProgramOptimization>
+ <CharacterSet>Unicode</CharacterSet>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+ <ImportGroup Label="ExtensionSettings">
+ </ImportGroup>
+ <ImportGroup Label="PropertySheets">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+ <Import Project="$(SolutionDir)\..\vsprojects\global.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\openssl.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\winsock.props" />
+ <Import Project="$(SolutionDir)\..\vsprojects\zlib.props" />
+ </ImportGroup>
+ <PropertyGroup Label="UserMacros" />
+ <PropertyGroup Condition="'$(Configuration)'=='Debug'">
+ <TargetName>internal_api_canary_transport_test</TargetName>
+ <Linkage-grpc_dependencies_zlib>static</Linkage-grpc_dependencies_zlib>
+ <Configuration-grpc_dependencies_zlib>Debug</Configuration-grpc_dependencies_zlib>
+ <Linkage-grpc_dependencies_openssl>static</Linkage-grpc_dependencies_openssl>
+ <Configuration-grpc_dependencies_openssl>Debug</Configuration-grpc_dependencies_openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)'=='Release'">
+ <TargetName>internal_api_canary_transport_test</TargetName>
+ <Linkage-grpc_dependencies_zlib>static</Linkage-grpc_dependencies_zlib>
+ <Configuration-grpc_dependencies_zlib>Release</Configuration-grpc_dependencies_zlib>
+ <Linkage-grpc_dependencies_openssl>static</Linkage-grpc_dependencies_openssl>
+ <Configuration-grpc_dependencies_openssl>Release</Configuration-grpc_dependencies_openssl>
+ </PropertyGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>Disabled</Optimization>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>Disabled</Optimization>
+ <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>MaxSpeed</Optimization>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <OptimizeReferences>true</OptimizeReferences>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <PrecompiledHeader>NotUsing</PrecompiledHeader>
+ <WarningLevel>Level3</WarningLevel>
+ <Optimization>MaxSpeed</Optimization>
+ <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <FunctionLevelLinking>true</FunctionLevelLinking>
+ <IntrinsicFunctions>true</IntrinsicFunctions>
+ <SDLCheck>true</SDLCheck>
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <DebugInformationFormat Condition="$(Jenkins)">None</DebugInformationFormat>
+ <MinimalRebuild Condition="$(Jenkins)">false</MinimalRebuild>
+ </ClCompile>
+ <Link>
+ <SubSystem>Console</SubSystem>
+ <GenerateDebugInformation Condition="!$(Jenkins)">true</GenerateDebugInformation>
+ <GenerateDebugInformation Condition="$(Jenkins)">false</GenerateDebugInformation>
+ <EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <OptimizeReferences>true</OptimizeReferences>
+ </Link>
+ </ItemDefinitionGroup>
+
+ <ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\test\core\internal_api_canaries\iomgr.c">
+ </ClCompile>
+ </ItemGroup>
+ <ItemGroup>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\grpc_test_util\grpc_test_util.vcxproj">
+ <Project>{17BCAFC0-5FDC-4C94-AEB9-95F3E220614B}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\grpc\grpc.vcxproj">
+ <Project>{29D16885-7228-4C31-81ED-5F9187C7F2A9}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\gpr_test_util\gpr_test_util.vcxproj">
+ <Project>{EAB0A629-17A9-44DB-B5FF-E91A721FE037}</Project>
+ </ProjectReference>
+ <ProjectReference Include="$(SolutionDir)\..\vsprojects\vcxproj\.\gpr\gpr.vcxproj">
+ <Project>{B23D3D1A-9438-4EDA-BEB6-9A0A03D17792}</Project>
+ </ProjectReference>
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="packages.config" />
+ </ItemGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+ <ImportGroup Label="ExtensionTargets">
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies\grpc.dependencies.zlib.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies\grpc.dependencies.zlib.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies\grpc.dependencies.openssl.targets')" />
+ <Import Project="$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets" Condition="Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies\grpc.dependencies.openssl.targets')" />
+ </ImportGroup>
+ <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
+ <PropertyGroup>
+ <ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
+ </PropertyGroup>
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.redist.1.2.8.10\build\native\grpc.dependencies.zlib.redist.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.zlib.1.2.8.10\build\native\grpc.dependencies.zlib.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.redist.1.0.204.1\build\native\grpc.dependencies.openssl.redist.targets')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.props')" />
+ <Error Condition="!Exists('$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\..\vsprojects\packages\grpc.dependencies.openssl.1.0.204.1\build\native\grpc.dependencies.openssl.targets')" />
+ </Target>
+</Project>
+
diff --git a/vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj.filters b/vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj.filters
new file mode 100644
index 0000000000..1e0b4c5557
--- /dev/null
+++ b/vsprojects/vcxproj/test/internal_api_canary_transport_test/internal_api_canary_transport_test.vcxproj.filters
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <ClCompile Include="$(SolutionDir)\..\test\core\internal_api_canaries\iomgr.c">
+ <Filter>test\core\internal_api_canaries</Filter>
+ </ClCompile>
+ </ItemGroup>
+
+ <ItemGroup>
+ <Filter Include="test">
+ <UniqueIdentifier>{38e59e26-aad9-60fd-a1a7-c8fd9b606e2f}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="test\core">
+ <UniqueIdentifier>{79aad60f-59b8-09e2-2cad-5b5e083ac008}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="test\core\internal_api_canaries">
+ <UniqueIdentifier>{e4f0214e-e3ec-b5b8-c00b-2932b5ec2422}</UniqueIdentifier>
+ </Filter>
+ </ItemGroup>
+</Project>
+