Merge branch 'master' into CsmMeshIdChange

pull/37801/head
Yash Tibrewal 1 month ago
commit d0f149e023
  1. 30
      .clang-format
  2. 192
      BUILD
  3. 6
      BUILDING.md
  4. 1835
      CMakeLists.txt
  5. 10
      Makefile
  6. 1
      PYTHON-MANIFEST.in
  7. 15
      Package.swift
  8. 12
      WORKSPACE
  9. 25
      bazel/experiments.bzl
  10. 7
      bazel/grpc_build_system.bzl
  11. 8
      bazel/grpc_deps.bzl
  12. 3
      bazel/internal_python_rules.bzl
  13. 1
      black.toml
  14. 974
      build_autogenerated.yaml
  15. 7
      build_handwritten.yaml
  16. 14
      config.m4
  17. 16
      config.w32
  18. 24
      examples/android/binder/java/io/grpc/binder/cpp/README.md
  19. 25
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/AndroidManifest.xml
  20. 51
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/BUILD
  21. 15
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/ButtonPressHandler.java
  22. 26
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/MainActivity.java
  23. 73
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/native.cc
  24. 24
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/res/layout/activity_main.xml
  25. 5
      examples/android/binder/java/io/grpc/binder/cpp/exampleclient/res/values/strings.xml
  26. 21
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest.xml
  27. 10
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/AndroidManifest_endpoint.xml
  28. 61
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/BUILD
  29. 13
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ButtonPressHandler.java
  30. 26
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/ExportedEndpointService.java
  31. 27
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/MainActivity.java
  32. 83
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/native.cc
  33. 24
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/layout/activity_main.xml
  34. 5
      examples/android/binder/java/io/grpc/binder/cpp/exampleserver/res/values/strings.xml
  35. 2
      examples/android/helloworld/app/CMakeLists.txt
  36. 2
      examples/cpp/auth/CMakeLists.txt
  37. 4
      examples/cpp/auth/ssl_client.cc
  38. 4
      examples/cpp/auth/ssl_server.cc
  39. 2
      examples/cpp/cancellation/CMakeLists.txt
  40. 4
      examples/cpp/cancellation/client.cc
  41. 4
      examples/cpp/cancellation/server.cc
  42. 2
      examples/cpp/cmake/common.cmake
  43. 2
      examples/cpp/compression/CMakeLists.txt
  44. 4
      examples/cpp/compression/greeter_client.cc
  45. 4
      examples/cpp/compression/greeter_server.cc
  46. 7
      examples/cpp/csm/csm_greeter_client.cc
  47. 15
      examples/cpp/csm/csm_greeter_server.cc
  48. 2
      examples/cpp/csm/observability/BUILD
  49. 2
      examples/cpp/csm/observability/Dockerfile.server
  50. 7
      examples/cpp/csm/observability/csm_greeter_client.cc
  51. 19
      examples/cpp/csm/observability/csm_greeter_server.cc
  52. 2
      examples/cpp/deadline/CMakeLists.txt
  53. 4
      examples/cpp/deadline/client.cc
  54. 4
      examples/cpp/deadline/server.cc
  55. 4
      examples/cpp/debugging/crashing_greeter_client.cc
  56. 10
      examples/cpp/debugging/greeter_callback_server_admin.cc
  57. 2
      examples/cpp/error_details/CMakeLists.txt
  58. 5
      examples/cpp/error_details/greeter_client.cc
  59. 9
      examples/cpp/error_details/greeter_server.cc
  60. 2
      examples/cpp/error_handling/CMakeLists.txt
  61. 4
      examples/cpp/error_handling/greeter_client.cc
  62. 8
      examples/cpp/error_handling/greeter_server.cc
  63. 2
      examples/cpp/flow_control/CMakeLists.txt
  64. 8
      examples/cpp/flow_control/client_flow_control_client.cc
  65. 8
      examples/cpp/flow_control/client_flow_control_server.cc
  66. 8
      examples/cpp/flow_control/server_flow_control_client.cc
  67. 10
      examples/cpp/flow_control/server_flow_control_server.cc
  68. 6
      examples/cpp/gcp_observability/helloworld/greeter_client.cc
  69. 10
      examples/cpp/gcp_observability/helloworld/greeter_server.cc
  70. 2
      examples/cpp/generic_api/CMakeLists.txt
  71. 6
      examples/cpp/generic_api/greeter_client.cc
  72. 6
      examples/cpp/generic_api/greeter_server.cc
  73. 2
      examples/cpp/health/CMakeLists.txt
  74. 5
      examples/cpp/health/health_client.cc
  75. 8
      examples/cpp/health/health_server.cc
  76. 2
      examples/cpp/helloworld/CMakeLists.txt
  77. 2
      examples/cpp/helloworld/cmake_externalproject/CMakeLists.txt
  78. 4
      examples/cpp/helloworld/greeter_async_client.cc
  79. 4
      examples/cpp/helloworld/greeter_async_client2.cc
  80. 4
      examples/cpp/helloworld/greeter_async_server.cc
  81. 4
      examples/cpp/helloworld/greeter_callback_client.cc
  82. 8
      examples/cpp/helloworld/greeter_callback_server.cc
  83. 4
      examples/cpp/helloworld/greeter_client.cc
  84. 8
      examples/cpp/helloworld/greeter_server.cc
  85. 4
      examples/cpp/helloworld/xds_greeter_client.cc
  86. 12
      examples/cpp/helloworld/xds_greeter_server.cc
  87. 2
      examples/cpp/interceptors/CMakeLists.txt
  88. 4
      examples/cpp/interceptors/caching_interceptor.h
  89. 4
      examples/cpp/interceptors/client.cc
  90. 6
      examples/cpp/interceptors/server.cc
  91. 2
      examples/cpp/keepalive/CMakeLists.txt
  92. 4
      examples/cpp/keepalive/greeter_callback_client.cc
  93. 8
      examples/cpp/keepalive/greeter_callback_server.cc
  94. 2
      examples/cpp/load_balancing/CMakeLists.txt
  95. 4
      examples/cpp/load_balancing/greeter_client.cc
  96. 4
      examples/cpp/load_balancing/greeter_server.cc
  97. 2
      examples/cpp/metadata/CMakeLists.txt
  98. 4
      examples/cpp/metadata/greeter_client.cc
  99. 4
      examples/cpp/metadata/greeter_server.cc
  100. 2
      examples/cpp/multiplex/CMakeLists.txt
  101. Some files were not shown because too many files have changed in this diff Show More

@ -8,36 +8,6 @@ IncludeCategories:
# ruby.h is even more first if it's included
- Regex: '^<ruby/ruby.h>'
Priority: -200
# Some platforms (namely msys) need wchar to be included BEFORE
# anything else, especially strsafe.h.
- Regex: '^<wchar.h>'
Priority: 5
# use priority 100+ for grpc headers so they sort last
# 'system' headers - include things that have " in the names to make them
# stand out and get fixed
- Regex: '^(<|")grpc'
Priority: 100
# similary using include/ to get system headers should stand out and get
# fixed
- Regex: '^"include/'
Priority: 100
# source headers go last
- Regex: '^"(src|test)/'
Priority: 101
# not-grpc headers follow
# first, non system headers that are included like <> - these are all
# local carveouts, and get sorted below c++ but before non grpc "" files
- Regex: '^<(openssl/|uv\.h|ares\.h|address_sorting/|gmock/|gtest/|zlib|zconf|benchmark/|google/)'
Priority: 30
# first C system headers - they have a . in the filename
- Regex: '^<.*\.'
Priority: 10
# then C++ system headers - no ., the only thing that will match now
- Regex: '^<'
Priority: 20
# finally other "" includes go between system headers and our headers
- Regex: '^"'
Priority: 40
---
Language: ObjC
BasedOnStyle: Google

192
BUILD

@ -19,6 +19,7 @@ load("@bazel_skylib//rules:common_settings.bzl", "bool_flag")
load(
"//bazel:grpc_build_system.bzl",
"grpc_cc_library",
"grpc_cc_proto_library",
"grpc_clang_cl_settings",
"grpc_filegroup",
"grpc_generate_one_off_targets",
@ -74,17 +75,6 @@ config_setting(
flag_values = {":disable_grpc_rls": "true"},
)
# When gRPC is build as shared library, binder transport code might still
# get included even when user's code does not depend on it. In that case
# --define=grpc_no_binder=true can be used to disable binder transport
# related code to reduce binary size.
# For users using build system other than bazel, they can define
# GRPC_NO_BINDER to achieve the same effect.
config_setting(
name = "grpc_no_binder_define",
values = {"define": "grpc_no_binder=true"},
)
config_setting(
name = "android",
values = {"crosstool_top": "//external:android/crosstool"},
@ -135,15 +125,6 @@ selects.config_setting_group(
],
)
selects.config_setting_group(
name = "grpc_no_binder",
match_any = [
":grpc_no_binder_define",
# We do not need binder on ios.
":ios",
],
)
selects.config_setting_group(
name = "grpc_no_rls",
match_any = [
@ -624,6 +605,7 @@ GRPC_XDS_TARGETS = [
"//src/core:grpc_resolver_c2p",
"//src/core:grpc_xds_server_config_fetcher",
"//src/core:grpc_stateful_session_filter",
"//src/core:xds_http_proxy_mapper",
# Not xDS-specific but currently only used by xDS.
"//src/core:channel_creds_registry_init",
@ -855,7 +837,6 @@ grpc_cc_library(
"//src/core:grpc_lb_policy_weighted_target",
"//src/core:grpc_channel_idle_filter",
"//src/core:grpc_message_size_filter",
"//src/core:grpc_resolver_binder",
"grpc_resolver_dns_ares",
"grpc_resolver_fake",
"//src/core:grpc_resolver_dns_native",
@ -941,12 +922,6 @@ grpc_cc_library(
"grpc++_xds_server",
],
},
{
"grpc_no_binder": [],
"//conditions:default": [
"grpc++_binder",
],
},
],
tags = ["nofixdeps"],
visibility = ["@grpc:public"],
@ -1077,112 +1052,6 @@ grpc_cc_library(
],
)
grpc_cc_library(
name = "grpc++_binder",
srcs = [
"//src/core:ext/transport/binder/client/binder_connector.cc",
"//src/core:ext/transport/binder/client/channel_create.cc",
"//src/core:ext/transport/binder/client/channel_create_impl.cc",
"//src/core:ext/transport/binder/client/connection_id_generator.cc",
"//src/core:ext/transport/binder/client/endpoint_binder_pool.cc",
"//src/core:ext/transport/binder/client/jni_utils.cc",
"//src/core:ext/transport/binder/client/security_policy_setting.cc",
"//src/core:ext/transport/binder/security_policy/binder_security_policy.cc",
"//src/core:ext/transport/binder/server/binder_server.cc",
"//src/core:ext/transport/binder/server/binder_server_credentials.cc",
"//src/core:ext/transport/binder/transport/binder_transport.cc",
"//src/core:ext/transport/binder/utils/ndk_binder.cc",
"//src/core:ext/transport/binder/utils/transport_stream_receiver_impl.cc",
"//src/core:ext/transport/binder/wire_format/binder_android.cc",
"//src/core:ext/transport/binder/wire_format/binder_constants.cc",
"//src/core:ext/transport/binder/wire_format/transaction.cc",
"//src/core:ext/transport/binder/wire_format/wire_reader_impl.cc",
"//src/core:ext/transport/binder/wire_format/wire_writer.cc",
],
hdrs = [
"//src/core:ext/transport/binder/client/binder_connector.h",
"//src/core:ext/transport/binder/client/channel_create_impl.h",
"//src/core:ext/transport/binder/client/connection_id_generator.h",
"//src/core:ext/transport/binder/client/endpoint_binder_pool.h",
"//src/core:ext/transport/binder/client/jni_utils.h",
"//src/core:ext/transport/binder/client/security_policy_setting.h",
"//src/core:ext/transport/binder/server/binder_server.h",
"//src/core:ext/transport/binder/transport/binder_stream.h",
"//src/core:ext/transport/binder/transport/binder_transport.h",
"//src/core:ext/transport/binder/utils/binder_auto_utils.h",
"//src/core:ext/transport/binder/utils/ndk_binder.h",
"//src/core:ext/transport/binder/utils/transport_stream_receiver.h",
"//src/core:ext/transport/binder/utils/transport_stream_receiver_impl.h",
"//src/core:ext/transport/binder/wire_format/binder.h",
"//src/core:ext/transport/binder/wire_format/binder_android.h",
"//src/core:ext/transport/binder/wire_format/binder_constants.h",
"//src/core:ext/transport/binder/wire_format/transaction.h",
"//src/core:ext/transport/binder/wire_format/wire_reader.h",
"//src/core:ext/transport/binder/wire_format/wire_reader_impl.h",
"//src/core:ext/transport/binder/wire_format/wire_writer.h",
],
defines = select({
"grpc_no_binder": ["GRPC_NO_BINDER"],
"//conditions:default": [],
}),
external_deps = [
"absl/base:core_headers",
"absl/cleanup",
"absl/container:flat_hash_map",
"absl/functional:any_invocable",
"absl/hash",
"absl/log:check",
"absl/log:log",
"absl/memory",
"absl/meta:type_traits",
"absl/status",
"absl/status:statusor",
"absl/strings",
"absl/synchronization",
"absl/time",
"absl/types:variant",
],
language = "c++",
public_hdrs = [
"include/grpcpp/security/binder_security_policy.h",
"include/grpcpp/create_channel_binder.h",
"include/grpcpp/security/binder_credentials.h",
],
tags = ["nofixdeps"],
deps = [
"channel",
"channel_create",
"config",
"debug_location",
"exec_ctx",
"gpr",
"gpr_platform",
"grpc",
"grpc++_base",
"grpc_base",
"grpc_client_channel",
"grpc_public_hdrs",
"orphanable",
"ref_counted_ptr",
"server",
"//src/core:arena",
"//src/core:channel_args",
"//src/core:channel_args_preconditioning",
"//src/core:channel_stack_type",
"//src/core:default_event_engine",
"//src/core:error_utils",
"//src/core:iomgr_fwd",
"//src/core:iomgr_port",
"//src/core:metadata_batch",
"//src/core:notification",
"//src/core:slice",
"//src/core:slice_refcount",
"//src/core:status_helper",
"//src/core:subchannel_connector",
"//src/core:transport_fwd",
],
)
grpc_cc_library(
name = "grpc++_xds_client",
srcs = [
@ -2043,6 +1912,7 @@ grpc_cc_library(
"//src/core:arena_promise",
"//src/core:atomic_utils",
"//src/core:bitset",
"//src/core:blackboard",
"//src/core:call_destination",
"//src/core:call_filters",
"//src/core:call_final_info",
@ -2960,6 +2830,18 @@ grpc_cc_library(
],
)
grpc_cc_library(
name = "generic_stub",
hdrs = [
"include/grpcpp/generic/generic_stub.h",
],
language = "c++",
visibility = ["@grpc:public"],
deps = [
"generic_stub_internal",
],
)
grpc_cc_library(
name = "generic_stub_callback",
hdrs = [
@ -2972,6 +2854,18 @@ grpc_cc_library(
],
)
grpc_cc_library(
name = "async_generic_service",
hdrs = [
"include/grpcpp/generic/async_generic_service.h",
],
language = "c++",
visibility = ["@grpc:public"],
deps = [
"grpc++_public_hdrs",
],
)
grpc_cc_library(
name = "callback_generic_service",
hdrs = [
@ -3780,6 +3674,7 @@ grpc_cc_library(
"//src/core:arena",
"//src/core:arena_promise",
"//src/core:backend_metric_parser",
"//src/core:blackboard",
"//src/core:call_destination",
"//src/core:call_filters",
"//src/core:call_spine",
@ -4360,6 +4255,7 @@ grpc_cc_library(
"//src/core:experiments",
"//src/core:grpc_message_size_filter",
"//src/core:latch",
"//src/core:latent_see",
"//src/core:map",
"//src/core:metadata_batch",
"//src/core:percent_encoding",
@ -4462,6 +4358,7 @@ grpc_cc_library(
"//src/core:default_event_engine",
"//src/core:dual_ref_counted",
"//src/core:env",
"//src/core:grpc_backend_metric_data",
"//src/core:json",
"//src/core:per_cpu",
"//src/core:ref_counted",
@ -4469,6 +4366,7 @@ grpc_cc_library(
"//src/core:time",
"//src/core:upb_utils",
"//src/core:useful",
"//src/core:xds_backend_metric_propagation",
],
)
@ -4758,6 +4656,7 @@ grpc_cc_library(
name = "grpc_transport_chttp2",
srcs = [
"//src/core:ext/transport/chttp2/transport/bin_decoder.cc",
"//src/core:ext/transport/chttp2/transport/call_tracer_wrapper.cc",
"//src/core:ext/transport/chttp2/transport/chttp2_transport.cc",
"//src/core:ext/transport/chttp2/transport/frame_data.cc",
"//src/core:ext/transport/chttp2/transport/frame_goaway.cc",
@ -4771,6 +4670,7 @@ grpc_cc_library(
],
hdrs = [
"//src/core:ext/transport/chttp2/transport/bin_decoder.h",
"//src/core:ext/transport/chttp2/transport/call_tracer_wrapper.h",
"//src/core:ext/transport/chttp2/transport/chttp2_transport.h",
"//src/core:ext/transport/chttp2/transport/frame_data.h",
"//src/core:ext/transport/chttp2/transport/frame_goaway.h",
@ -4779,6 +4679,7 @@ grpc_cc_library(
"//src/core:ext/transport/chttp2/transport/frame_settings.h",
"//src/core:ext/transport/chttp2/transport/frame_window_update.h",
"//src/core:ext/transport/chttp2/transport/internal.h",
"//src/core:ext/transport/chttp2/transport/stream_lists.h",
],
external_deps = [
"absl/base:core_headers",
@ -4956,11 +4857,21 @@ grpc_upb_proto_reflection_library(
deps = ["@envoy_api//envoy/config/cluster/v3:pkg"],
)
grpc_cc_proto_library(
name = "envoy_config_core_cc_proto",
deps = ["@envoy_api//envoy/config/core/v3:pkg"],
)
grpc_upb_proto_library(
name = "envoy_config_core_upb",
deps = ["@envoy_api//envoy/config/core/v3:pkg"],
)
grpc_upb_proto_reflection_library(
name = "envoy_config_core_upbdefs",
deps = ["@envoy_api//envoy/config/core/v3:pkg"],
)
grpc_upb_proto_library(
name = "envoy_config_endpoint_upb",
deps = ["@envoy_api//envoy/config/endpoint/v3:pkg"],
@ -5116,6 +5027,16 @@ grpc_upb_proto_reflection_library(
deps = ["@envoy_api//envoy/extensions/transport_sockets/tls/v3:pkg"],
)
grpc_upb_proto_library(
name = "envoy_extensions_transport_sockets_http_11_proxy_upb",
deps = ["@envoy_api//envoy/extensions/transport_sockets/http_11_proxy/v3:pkg"],
)
grpc_upb_proto_reflection_library(
name = "envoy_extensions_transport_sockets_http_11_proxy_upbdefs",
deps = ["@envoy_api//envoy/extensions/transport_sockets/http_11_proxy/v3:pkg"],
)
grpc_upb_proto_library(
name = "envoy_extensions_upstreams_http_upb",
deps = ["@envoy_api//envoy/extensions/upstreams/http/v3:pkg"],
@ -5126,6 +5047,11 @@ grpc_upb_proto_reflection_library(
deps = ["@envoy_api//envoy/extensions/upstreams/http/v3:pkg"],
)
grpc_cc_proto_library(
name = "envoy_service_discovery_cc_proto",
deps = ["@envoy_api//envoy/service/discovery/v3:pkg"],
)
grpc_upb_proto_library(
name = "envoy_service_discovery_upb",
deps = ["@envoy_api//envoy/service/discovery/v3:pkg"],

@ -55,7 +55,7 @@ installed by `brew` is being used:
## Windows
To prepare for cmake + Microsoft Visual C++ compiler build
- Install Visual Studio 2019 or later (Visual C++ compiler will be used).
- Install Visual Studio 2022 or later (Visual C++ compiler will be used).
- Install [Git](https://git-scm.com/).
- Install [CMake](https://cmake.org/download/).
- Install [nasm](https://www.nasm.us/) and add it to `PATH` (`choco install nasm`) - *required by boringssl*
@ -132,7 +132,7 @@ $ make
If you want to build shared libraries (`.so` files), run `cmake` with `-DBUILD_SHARED_LIBS=ON`.
### Windows, Using Visual Studio 2019 or later
### Windows, Using Visual Studio 2022 or later
When using the "Visual Studio" generator,
cmake will generate a solution (`grpc.sln`) that contains a VS project for
@ -143,7 +143,7 @@ you will be able to browse and build the code.
> @rem Run from grpc directory after cloning the repo with --recursive or updating submodules.
> md .build
> cd .build
> cmake .. -G "Visual Studio 16 2019"
> cmake .. -G "Visual Studio 17 2022"
> cmake --build . --config Release
```

1835
CMakeLists.txt generated

File diff suppressed because it is too large Load Diff

10
Makefile generated

@ -711,6 +711,7 @@ LIBGRPC_SRC = \
src/core/ext/transport/chttp2/server/chttp2_server.cc \
src/core/ext/transport/chttp2/transport/bin_decoder.cc \
src/core/ext/transport/chttp2/transport/bin_encoder.cc \
src/core/ext/transport/chttp2/transport/call_tracer_wrapper.cc \
src/core/ext/transport/chttp2/transport/chttp2_transport.cc \
src/core/ext/transport/chttp2/transport/decode_huff.cc \
src/core/ext/transport/chttp2/transport/flow_control.cc \
@ -817,6 +818,7 @@ LIBGRPC_SRC = \
src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/pick_first/v3/pick_first.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/ring_hash/v3/ring_hash.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/cert.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/common.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/secret.upb_minitable.c \
@ -978,6 +980,7 @@ LIBGRPC_SRC = \
src/core/ext/upbdefs-gen/envoy/extensions/filters/http/stateful_session/v3/stateful_session.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/http/stateful_session/cookie/v3/cookie.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/cert.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/common.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/secret.upbdefs.c \
@ -1057,11 +1060,13 @@ LIBGRPC_SRC = \
src/core/ext/upbdefs-gen/xds/type/v3/cel.upbdefs.c \
src/core/ext/upbdefs-gen/xds/type/v3/range.upbdefs.c \
src/core/ext/upbdefs-gen/xds/type/v3/typed_struct.upbdefs.c \
src/core/filter/blackboard.cc \
src/core/handshaker/endpoint_info/endpoint_info_handshaker.cc \
src/core/handshaker/handshaker.cc \
src/core/handshaker/handshaker_registry.cc \
src/core/handshaker/http_connect/http_connect_handshaker.cc \
src/core/handshaker/http_connect/http_proxy_mapper.cc \
src/core/handshaker/http_connect/xds_http_proxy_mapper.cc \
src/core/handshaker/proxy_mapper_registry.cc \
src/core/handshaker/security/secure_endpoint.cc \
src/core/handshaker/security/security_handshaker.cc \
@ -1353,7 +1358,6 @@ LIBGRPC_SRC = \
src/core/load_balancing/xds/xds_wrr_locality.cc \
src/core/plugin_registry/grpc_plugin_registry.cc \
src/core/plugin_registry/grpc_plugin_registry_extra.cc \
src/core/resolver/binder/binder_resolver.cc \
src/core/resolver/dns/c_ares/dns_resolver_ares.cc \
src/core/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
src/core/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
@ -1517,6 +1521,7 @@ LIBGRPC_SRC = \
src/core/xds/grpc/xds_transport_grpc.cc \
src/core/xds/xds_client/lrs_client.cc \
src/core/xds/xds_client/xds_api.cc \
src/core/xds/xds_client/xds_backend_metric_propagation.cc \
src/core/xds/xds_client/xds_bootstrap.cc \
src/core/xds/xds_client/xds_client.cc \
third_party/abseil-cpp/absl/base/internal/cycleclock.cc \
@ -1542,9 +1547,12 @@ LIBGRPC_SRC = \
third_party/abseil-cpp/absl/crc/internal/crc_non_temporal_memcpy.cc \
third_party/abseil-cpp/absl/crc/internal/crc_x86_arm_combined.cc \
third_party/abseil-cpp/absl/debugging/internal/address_is_readable.cc \
third_party/abseil-cpp/absl/debugging/internal/decode_rust_punycode.cc \
third_party/abseil-cpp/absl/debugging/internal/demangle.cc \
third_party/abseil-cpp/absl/debugging/internal/demangle_rust.cc \
third_party/abseil-cpp/absl/debugging/internal/elf_mem_image.cc \
third_party/abseil-cpp/absl/debugging/internal/examine_stack.cc \
third_party/abseil-cpp/absl/debugging/internal/utf8_for_code_point.cc \
third_party/abseil-cpp/absl/debugging/internal/vdso_support.cc \
third_party/abseil-cpp/absl/debugging/stacktrace.cc \
third_party/abseil-cpp/absl/debugging/symbolize.cc \

@ -17,6 +17,7 @@ include src/python/grpcio/_parallel_compile_patch.py
include src/python/grpcio/_spawn_patch.py
include src/python/grpcio/commands.py
include src/python/grpcio/grpc_version.py
include src/python/grpcio/python_version.py
include src/python/grpcio/grpc_core_dependencies.py
include src/python/grpcio/precompiled.py
include src/python/grpcio/support.py

15
Package.swift generated

@ -210,6 +210,8 @@ let package = Package(
"src/core/ext/transport/chttp2/transport/bin_decoder.h",
"src/core/ext/transport/chttp2/transport/bin_encoder.cc",
"src/core/ext/transport/chttp2/transport/bin_encoder.h",
"src/core/ext/transport/chttp2/transport/call_tracer_wrapper.cc",
"src/core/ext/transport/chttp2/transport/call_tracer_wrapper.h",
"src/core/ext/transport/chttp2/transport/chttp2_transport.cc",
"src/core/ext/transport/chttp2/transport/chttp2_transport.h",
"src/core/ext/transport/chttp2/transport/context_list_entry.h",
@ -256,6 +258,7 @@ let package = Package(
"src/core/ext/transport/chttp2/transport/ping_rate_policy.cc",
"src/core/ext/transport/chttp2/transport/ping_rate_policy.h",
"src/core/ext/transport/chttp2/transport/stream_lists.cc",
"src/core/ext/transport/chttp2/transport/stream_lists.h",
"src/core/ext/transport/chttp2/transport/varint.cc",
"src/core/ext/transport/chttp2/transport/varint.h",
"src/core/ext/transport/chttp2/transport/write_size_policy.cc",
@ -502,6 +505,9 @@ let package = Package(
"src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb.h",
"src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb_minitable.c",
"src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb_minitable.h",
"src/core/ext/upb-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upb.h",
"src/core/ext/upb-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upb_minitable.c",
"src/core/ext/upb-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upb_minitable.h",
"src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/cert.upb.h",
"src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/cert.upb_minitable.c",
"src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/cert.upb_minitable.h",
@ -911,6 +917,8 @@ let package = Package(
"src/core/ext/upbdefs-gen/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upbdefs.h",
"src/core/ext/upbdefs-gen/envoy/extensions/http/stateful_session/cookie/v3/cookie.upbdefs.c",
"src/core/ext/upbdefs-gen/envoy/extensions/http/stateful_session/cookie/v3/cookie.upbdefs.h",
"src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upbdefs.c",
"src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upbdefs.h",
"src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/cert.upbdefs.c",
"src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/cert.upbdefs.h",
"src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/common.upbdefs.c",
@ -1069,6 +1077,8 @@ let package = Package(
"src/core/ext/upbdefs-gen/xds/type/v3/range.upbdefs.h",
"src/core/ext/upbdefs-gen/xds/type/v3/typed_struct.upbdefs.c",
"src/core/ext/upbdefs-gen/xds/type/v3/typed_struct.upbdefs.h",
"src/core/filter/blackboard.cc",
"src/core/filter/blackboard.h",
"src/core/handshaker/endpoint_info/endpoint_info_handshaker.cc",
"src/core/handshaker/endpoint_info/endpoint_info_handshaker.h",
"src/core/handshaker/handshaker.cc",
@ -1080,6 +1090,8 @@ let package = Package(
"src/core/handshaker/http_connect/http_connect_handshaker.h",
"src/core/handshaker/http_connect/http_proxy_mapper.cc",
"src/core/handshaker/http_connect/http_proxy_mapper.h",
"src/core/handshaker/http_connect/xds_http_proxy_mapper.cc",
"src/core/handshaker/http_connect/xds_http_proxy_mapper.h",
"src/core/handshaker/proxy_mapper.h",
"src/core/handshaker/proxy_mapper_registry.cc",
"src/core/handshaker/proxy_mapper_registry.h",
@ -1697,7 +1709,6 @@ let package = Package(
"src/core/load_balancing/xds/xds_wrr_locality.cc",
"src/core/plugin_registry/grpc_plugin_registry.cc",
"src/core/plugin_registry/grpc_plugin_registry_extra.cc",
"src/core/resolver/binder/binder_resolver.cc",
"src/core/resolver/dns/c_ares/dns_resolver_ares.cc",
"src/core/resolver/dns/c_ares/dns_resolver_ares.h",
"src/core/resolver/dns/c_ares/grpc_ares_ev_driver.h",
@ -2035,6 +2046,8 @@ let package = Package(
"src/core/xds/xds_client/lrs_client.h",
"src/core/xds/xds_client/xds_api.cc",
"src/core/xds/xds_client/xds_api.h",
"src/core/xds/xds_client/xds_backend_metric_propagation.cc",
"src/core/xds/xds_client/xds_backend_metric_propagation.h",
"src/core/xds/xds_client/xds_bootstrap.cc",
"src/core/xds/xds_client/xds_bootstrap.h",
"src/core/xds/xds_client/xds_channel_args.h",

@ -56,16 +56,6 @@ android_ndk_repository(name = "androidndk")
# here, because the toolchain rule fails when $ANDROID_NDK_HOME is not set.
# Use `--extra_toolchains=@androidndk//:all` to manually register it when building for Android.
# Prevents bazel's '...' expansion from including the following folder.
# This is required because the BUILD file in the following folder
# will trigger bazel failure when Android SDK is not configured.
# The targets in the following folder need to be included in APK and will
# be invoked by binder transport implementation through JNI.
local_repository(
name = "binder_transport_android_helper",
path = "src/core/ext/transport/binder/java",
)
# Prevents bazel's '...' expansion from including the following folder.
# This is required to avoid triggering "Unable to find package for @rules_fuzzing//fuzzing:cc_defs.bzl"
# error.
@ -89,7 +79,7 @@ load("@com_google_protobuf//bazel:system_python.bzl", "system_python")
system_python(
name = "system_python",
minimum_python_version = "3.7",
minimum_python_version = "3.8",
)
load("@system_python//:pip.bzl", system_pip_parse = "pip_parse")

@ -38,7 +38,6 @@ EXPERIMENT_ENABLES = {
"time_caching_in_party": "time_caching_in_party",
"trace_record_callops": "trace_record_callops",
"unconstrained_max_quota_buffer_size": "unconstrained_max_quota_buffer_size",
"work_serializer_clears_time_cache": "work_serializer_clears_time_cache",
"work_serializer_dispatch": "work_serializer_dispatch",
}
@ -136,57 +135,53 @@ EXPERIMENTS = {
},
"off": {
"core_end2end_test": [
"event_engine_client",
"local_connector_secure",
"work_serializer_dispatch",
],
"cpp_end2end_test": [
"work_serializer_dispatch",
],
"endpoint_test": [
"tcp_frame_size_tuning",
"tcp_rcv_lowat",
],
"event_engine_client_test": [
"event_engine_client",
],
"flow_control_test": [
"multiping",
"tcp_frame_size_tuning",
"tcp_rcv_lowat",
],
"lb_unit_test": [
"work_serializer_dispatch",
],
"resource_quota_test": [
"free_large_allocator",
"unconstrained_max_quota_buffer_size",
],
"xds_end2end_test": [
"work_serializer_dispatch",
],
},
"on": {
"cancel_ares_query_test": [
"event_engine_dns",
],
"core_end2end_test": [
"event_engine_client",
"event_engine_listener",
"work_serializer_dispatch",
],
"cpp_end2end_test": [
"work_serializer_dispatch",
],
"cpp_lb_end2end_test": [
"pick_first_new",
],
"event_engine_client_test": [
"event_engine_client",
],
"event_engine_listener_test": [
"event_engine_listener",
],
"lb_unit_test": [
"pick_first_new",
"work_serializer_dispatch",
],
"resolver_component_tests_runner_invoker": [
"event_engine_dns",
],
"xds_end2end_test": [
"pick_first_new",
"work_serializer_dispatch",
],
},
},

@ -29,6 +29,7 @@ Contains macros used throughout the repo.
load("@build_bazel_rules_apple//apple:ios.bzl", "ios_unit_test")
load("@build_bazel_rules_apple//apple/testing/default_runner:ios_test_runner.bzl", "ios_test_runner")
load("@com_google_protobuf//bazel:cc_proto_library.bzl", "cc_proto_library")
load("@com_google_protobuf//bazel:upb_proto_library.bzl", "upb_proto_library", "upb_proto_reflection_library")
load("//bazel:cc_grpc_library.bzl", "cc_grpc_library")
load("//bazel:copts.bzl", "GRPC_DEFAULT_COPTS")
@ -122,6 +123,7 @@ def _update_visibility(visibility):
"iomgr_internal_errqueue": PRIVATE,
"iomgr_buffer_list": PRIVATE,
"json_reader_legacy": PRIVATE,
"latent_see": PRIVATE,
"otel_plugin": PRIVATE,
"public": PUBLIC,
"ref_counted_ptr": PRIVATE,
@ -725,7 +727,7 @@ def grpc_package(name, visibility = "private", features = []):
features: The features to enable.
"""
if visibility == "tests":
visibility = ["//test:__subpackages__"]
visibility = ["//test:__subpackages__", "//src/proto/grpc/testing:__subpackages__"]
elif visibility == "public":
visibility = ["//visibility:public"]
elif visibility == "private":
@ -793,6 +795,9 @@ def grpc_objc_library(
visibility = visibility,
)
def grpc_cc_proto_library(name, deps):
cc_proto_library(name = name, deps = deps)
def grpc_upb_proto_library(name, deps):
upb_proto_library(name = name, deps = deps)

@ -143,11 +143,11 @@ def grpc_deps():
if "com_google_absl" not in native.existing_rules():
http_archive(
name = "com_google_absl",
sha256 = "338420448b140f0dfd1a1ea3c3ce71b3bc172071f24f4d9a57d59b45037da440",
strip_prefix = "abseil-cpp-20240116.0",
sha256 = "f50e5ac311a81382da7fa75b97310e4b9006474f9560ac46f54a9967f07d4ae3",
strip_prefix = "abseil-cpp-20240722.0",
urls = [
"https://storage.googleapis.com/grpc-bazel-mirror/github.com/abseil/abseil-cpp/archive/20240116.0.tar.gz",
"https://github.com/abseil/abseil-cpp/archive/20240116.0.tar.gz",
"https://storage.googleapis.com/grpc-bazel-mirror/github.com/abseil/abseil-cpp/archive/20240722.0.tar.gz",
"https://github.com/abseil/abseil-cpp/archive/20240722.0.tar.gz",
],
)

@ -14,7 +14,6 @@
"""Python-related rules intended only for use internal to the repo."""
load("//bazel:gevent_test.bzl", "py_grpc_gevent_test")
load("//bazel:logging_threshold_test.bzl", "py_grpc_logging_threshold_test")
def internal_py_grpc_test(name, **kwargs):
"""Runs a test under all supported environments.
@ -29,7 +28,6 @@ def internal_py_grpc_test(name, **kwargs):
**kwargs
)
py_grpc_gevent_test(name, **kwargs)
py_grpc_logging_threshold_test(name, **kwargs)
suite_kwargs = {}
if "visibility" in kwargs:
@ -40,7 +38,6 @@ def internal_py_grpc_test(name, **kwargs):
tests = [
name + ".native",
name + ".gevent",
name + ".logging_threshold",
],
**suite_kwargs
)

@ -15,6 +15,7 @@ extend-exclude = '''
| test/cpp/naming/resolver_component_tests_runner.py # AUTO-GENERATED
# AUTO-GENERATED from a template:
| grpc_version.py
| python_version.py
| src/python/grpcio/grpc_core_dependencies.py
| src/python/grpcio/grpc/_grpcio_metadata.py
# AUTO-GENERATED BY make_grpcio_tools.py

File diff suppressed because it is too large Load Diff

@ -16,6 +16,13 @@ settings:
csharp_major_version: 2
g_stands_for: groovy
protobuf_version: 3.28.1
supported_python_versions:
- '3.8'
- '3.9'
- '3.10'
- '3.11'
- '3.12'
- '3.13'
version: 1.68.0-dev
configs:
asan:

14
config.m4 generated

@ -86,6 +86,7 @@ if test "$PHP_GRPC" != "no"; then
src/core/ext/transport/chttp2/server/chttp2_server.cc \
src/core/ext/transport/chttp2/transport/bin_decoder.cc \
src/core/ext/transport/chttp2/transport/bin_encoder.cc \
src/core/ext/transport/chttp2/transport/call_tracer_wrapper.cc \
src/core/ext/transport/chttp2/transport/chttp2_transport.cc \
src/core/ext/transport/chttp2/transport/decode_huff.cc \
src/core/ext/transport/chttp2/transport/flow_control.cc \
@ -192,6 +193,7 @@ if test "$PHP_GRPC" != "no"; then
src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/pick_first/v3/pick_first.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/ring_hash/v3/ring_hash.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/cert.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/common.upb_minitable.c \
src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3/secret.upb_minitable.c \
@ -353,6 +355,7 @@ if test "$PHP_GRPC" != "no"; then
src/core/ext/upbdefs-gen/envoy/extensions/filters/http/stateful_session/v3/stateful_session.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/http/stateful_session/cookie/v3/cookie.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/http_11_proxy/v3/upstream_http_11_connect.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/cert.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/common.upbdefs.c \
src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3/secret.upbdefs.c \
@ -432,11 +435,13 @@ if test "$PHP_GRPC" != "no"; then
src/core/ext/upbdefs-gen/xds/type/v3/cel.upbdefs.c \
src/core/ext/upbdefs-gen/xds/type/v3/range.upbdefs.c \
src/core/ext/upbdefs-gen/xds/type/v3/typed_struct.upbdefs.c \
src/core/filter/blackboard.cc \
src/core/handshaker/endpoint_info/endpoint_info_handshaker.cc \
src/core/handshaker/handshaker.cc \
src/core/handshaker/handshaker_registry.cc \
src/core/handshaker/http_connect/http_connect_handshaker.cc \
src/core/handshaker/http_connect/http_proxy_mapper.cc \
src/core/handshaker/http_connect/xds_http_proxy_mapper.cc \
src/core/handshaker/proxy_mapper_registry.cc \
src/core/handshaker/security/secure_endpoint.cc \
src/core/handshaker/security/security_handshaker.cc \
@ -728,7 +733,6 @@ if test "$PHP_GRPC" != "no"; then
src/core/load_balancing/xds/xds_wrr_locality.cc \
src/core/plugin_registry/grpc_plugin_registry.cc \
src/core/plugin_registry/grpc_plugin_registry_extra.cc \
src/core/resolver/binder/binder_resolver.cc \
src/core/resolver/dns/c_ares/dns_resolver_ares.cc \
src/core/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc \
src/core/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc \
@ -892,6 +896,7 @@ if test "$PHP_GRPC" != "no"; then
src/core/xds/grpc/xds_transport_grpc.cc \
src/core/xds/xds_client/lrs_client.cc \
src/core/xds/xds_client/xds_api.cc \
src/core/xds/xds_client/xds_backend_metric_propagation.cc \
src/core/xds/xds_client/xds_bootstrap.cc \
src/core/xds/xds_client/xds_client.cc \
src/php/ext/grpc/byte_buffer.c \
@ -927,9 +932,12 @@ if test "$PHP_GRPC" != "no"; then
third_party/abseil-cpp/absl/crc/internal/crc_non_temporal_memcpy.cc \
third_party/abseil-cpp/absl/crc/internal/crc_x86_arm_combined.cc \
third_party/abseil-cpp/absl/debugging/internal/address_is_readable.cc \
third_party/abseil-cpp/absl/debugging/internal/decode_rust_punycode.cc \
third_party/abseil-cpp/absl/debugging/internal/demangle.cc \
third_party/abseil-cpp/absl/debugging/internal/demangle_rust.cc \
third_party/abseil-cpp/absl/debugging/internal/elf_mem_image.cc \
third_party/abseil-cpp/absl/debugging/internal/examine_stack.cc \
third_party/abseil-cpp/absl/debugging/internal/utf8_for_code_point.cc \
third_party/abseil-cpp/absl/debugging/internal/vdso_support.cc \
third_party/abseil-cpp/absl/debugging/stacktrace.cc \
third_party/abseil-cpp/absl/debugging/symbolize.cc \
@ -1453,6 +1461,7 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/pick_first/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/ring_hash/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/extensions/load_balancing_policies/wrr_locality/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/extensions/transport_sockets/http_11_proxy/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/extensions/transport_sockets/tls/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/extensions/upstreams/http/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upb-gen/envoy/service/discovery/v3)
@ -1505,6 +1514,7 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/extensions/filters/http/stateful_session/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/extensions/filters/network/http_connection_manager/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/extensions/http/stateful_session/cookie/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/http_11_proxy/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/extensions/transport_sockets/tls/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/extensions/upstreams/http/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/envoy/service/discovery/v3)
@ -1527,6 +1537,7 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/xds/core/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/xds/type/matcher/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/upbdefs-gen/xds/type/v3)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/filter)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/handshaker)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/handshaker/endpoint_info)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/handshaker/http_connect)
@ -1594,7 +1605,6 @@ if test "$PHP_GRPC" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/src/core/load_balancing/xds)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/plugin_registry)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/resolver)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/resolver/binder)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/resolver/dns)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/resolver/dns/c_ares)
PHP_ADD_BUILD_DIR($ext_builddir/src/core/resolver/dns/event_engine)

16
config.w32 generated

@ -51,6 +51,7 @@ if (PHP_GRPC != "no") {
"src\\core\\ext\\transport\\chttp2\\server\\chttp2_server.cc " +
"src\\core\\ext\\transport\\chttp2\\transport\\bin_decoder.cc " +
"src\\core\\ext\\transport\\chttp2\\transport\\bin_encoder.cc " +
"src\\core\\ext\\transport\\chttp2\\transport\\call_tracer_wrapper.cc " +
"src\\core\\ext\\transport\\chttp2\\transport\\chttp2_transport.cc " +
"src\\core\\ext\\transport\\chttp2\\transport\\decode_huff.cc " +
"src\\core\\ext\\transport\\chttp2\\transport\\flow_control.cc " +
@ -157,6 +158,7 @@ if (PHP_GRPC != "no") {
"src\\core\\ext\\upb-gen\\envoy\\extensions\\load_balancing_policies\\pick_first\\v3\\pick_first.upb_minitable.c " +
"src\\core\\ext\\upb-gen\\envoy\\extensions\\load_balancing_policies\\ring_hash\\v3\\ring_hash.upb_minitable.c " +
"src\\core\\ext\\upb-gen\\envoy\\extensions\\load_balancing_policies\\wrr_locality\\v3\\wrr_locality.upb_minitable.c " +
"src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\http_11_proxy\\v3\\upstream_http_11_connect.upb_minitable.c " +
"src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\tls\\v3\\cert.upb_minitable.c " +
"src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\tls\\v3\\common.upb_minitable.c " +
"src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\tls\\v3\\secret.upb_minitable.c " +
@ -318,6 +320,7 @@ if (PHP_GRPC != "no") {
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\filters\\http\\stateful_session\\v3\\stateful_session.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\filters\\network\\http_connection_manager\\v3\\http_connection_manager.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\http\\stateful_session\\cookie\\v3\\cookie.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\http_11_proxy\\v3\\upstream_http_11_connect.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\tls\\v3\\cert.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\tls\\v3\\common.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\tls\\v3\\secret.upbdefs.c " +
@ -397,11 +400,13 @@ if (PHP_GRPC != "no") {
"src\\core\\ext\\upbdefs-gen\\xds\\type\\v3\\cel.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\xds\\type\\v3\\range.upbdefs.c " +
"src\\core\\ext\\upbdefs-gen\\xds\\type\\v3\\typed_struct.upbdefs.c " +
"src\\core\\filter\\blackboard.cc " +
"src\\core\\handshaker\\endpoint_info\\endpoint_info_handshaker.cc " +
"src\\core\\handshaker\\handshaker.cc " +
"src\\core\\handshaker\\handshaker_registry.cc " +
"src\\core\\handshaker\\http_connect\\http_connect_handshaker.cc " +
"src\\core\\handshaker\\http_connect\\http_proxy_mapper.cc " +
"src\\core\\handshaker\\http_connect\\xds_http_proxy_mapper.cc " +
"src\\core\\handshaker\\proxy_mapper_registry.cc " +
"src\\core\\handshaker\\security\\secure_endpoint.cc " +
"src\\core\\handshaker\\security\\security_handshaker.cc " +
@ -693,7 +698,6 @@ if (PHP_GRPC != "no") {
"src\\core\\load_balancing\\xds\\xds_wrr_locality.cc " +
"src\\core\\plugin_registry\\grpc_plugin_registry.cc " +
"src\\core\\plugin_registry\\grpc_plugin_registry_extra.cc " +
"src\\core\\resolver\\binder\\binder_resolver.cc " +
"src\\core\\resolver\\dns\\c_ares\\dns_resolver_ares.cc " +
"src\\core\\resolver\\dns\\c_ares\\grpc_ares_ev_driver_posix.cc " +
"src\\core\\resolver\\dns\\c_ares\\grpc_ares_ev_driver_windows.cc " +
@ -857,6 +861,7 @@ if (PHP_GRPC != "no") {
"src\\core\\xds\\grpc\\xds_transport_grpc.cc " +
"src\\core\\xds\\xds_client\\lrs_client.cc " +
"src\\core\\xds\\xds_client\\xds_api.cc " +
"src\\core\\xds\\xds_client\\xds_backend_metric_propagation.cc " +
"src\\core\\xds\\xds_client\\xds_bootstrap.cc " +
"src\\core\\xds\\xds_client\\xds_client.cc " +
"src\\php\\ext\\grpc\\byte_buffer.c " +
@ -892,9 +897,12 @@ if (PHP_GRPC != "no") {
"third_party\\abseil-cpp\\absl\\crc\\internal\\crc_non_temporal_memcpy.cc " +
"third_party\\abseil-cpp\\absl\\crc\\internal\\crc_x86_arm_combined.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\address_is_readable.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\decode_rust_punycode.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\demangle.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\demangle_rust.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\elf_mem_image.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\examine_stack.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\utf8_for_code_point.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\internal\\vdso_support.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\stacktrace.cc " +
"third_party\\abseil-cpp\\absl\\debugging\\symbolize.cc " +
@ -1493,6 +1501,8 @@ if (PHP_GRPC != "no") {
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\load_balancing_policies\\wrr_locality");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\load_balancing_policies\\wrr_locality\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\http_11_proxy");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\http_11_proxy\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\tls");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\transport_sockets\\tls\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upb-gen\\envoy\\extensions\\upstreams");
@ -1616,6 +1626,8 @@ if (PHP_GRPC != "no") {
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\http\\stateful_session\\cookie");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\http\\stateful_session\\cookie\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\http_11_proxy");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\http_11_proxy\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\tls");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\transport_sockets\\tls\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\envoy\\extensions\\upstreams");
@ -1665,6 +1677,7 @@ if (PHP_GRPC != "no") {
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\xds\\type\\matcher");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\xds\\type\\matcher\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\ext\\upbdefs-gen\\xds\\type\\v3");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\filter");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\handshaker");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\handshaker\\endpoint_info");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\handshaker\\http_connect");
@ -1734,7 +1747,6 @@ if (PHP_GRPC != "no") {
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\load_balancing\\xds");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\plugin_registry");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\resolver");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\resolver\\binder");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\resolver\\dns");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\resolver\\dns\\c_ares");
FSO.CreateFolder(base_dir+"\\ext\\grpc\\src\\core\\resolver\\dns\\event_engine");

@ -1,24 +0,0 @@
# gRPC-core BinderTransport example apps
## Build Instruction
1. Install Android SDK and NDK. Only NDK version >= 25 is supported. We tested against SDK Platform `33` and NDK `26.2.11394342`.
2. Make sure Bazel is at least `7.0`. Use `export OVERRIDE_BAZEL_VERSION=7.3.1` to selected a supported version listed in `bazel/supported_versions.txt` if necessary.
3. Point environment variables to install locations of SDK and NDK
```
export ANDROID_HOME=$HOME/android-sdk
export ANDROID_NDK_HOME=$HOME/android-sdk/ndk/26.2.11394342
```
4. To build a fat APK that supports `x86_64`, `armv7`, and `arm64`:
```
bazel build \
--extra_toolchains=@androidndk//:all \
--android_platforms=//bazel/platforms/android:x86_64,//bazel/platforms/android:armeabi-v7a,//bazel/platforms/android:arm64-v8a \
--copt=-Wno-unknown-warning-option \
//examples/android/binder/java/io/grpc/binder/cpp/exampleserver:app \
//examples/android/binder/java/io/grpc/binder/cpp/exampleclient:app
```
5. `adb install
bazel-bin/examples/android/binder/java/io/grpc/binder/cpp/exampleclient/app.apk`
6. `adb install
bazel-bin/examples/android/binder/java/io/grpc/binder/cpp/exampleserver/app.apk`

@ -1,25 +0,0 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="io.grpc.binder.cpp.exampleclient"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="29"
android:targetSdkVersion="30" />
<queries>
<package android:name="io.grpc.binder.cpp.exampleserver" />
</queries>
<application
android:label="gRPC BinderTransport Client Cpp">
<activity
android:name=".MainActivity"
android:label="gRPC BinderTransport Client Cpp" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>

@ -1,51 +0,0 @@
# Copyright 2021 gRPC authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
cc_library(
name = "jni_lib",
srcs = ["native.cc"],
linkopts = [
"-ldl",
"-llog",
"-lm",
"-Wl,--no-undefined",
],
deps = [
"//:grpc++",
"//examples/protos:helloworld_cc_grpc",
],
alwayslink = True,
)
android_library(
name = "activity",
srcs = [
"ButtonPressHandler.java",
"MainActivity.java",
],
manifest = "AndroidManifest.xml",
resource_files = glob(["res/**"]),
deps = [
":jni_lib",
"@binder_transport_android_helper//io/grpc/binder/cpp:connection_helper",
],
)
android_binary(
name = "app",
manifest = "AndroidManifest.xml",
deps = [
":activity",
],
)

@ -1,15 +0,0 @@
package io.grpc.binder.cpp.exampleclient;
import android.app.Application;
public class ButtonPressHandler {
static {
System.loadLibrary("app");
}
public native String native_entry(Application application);
public String onPressed(Application application) {
return native_entry(application);
}
}

@ -1,26 +0,0 @@
package io.grpc.binder.cpp.exampleclient;
import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
import android.widget.Button;
import android.widget.TextView;
/** Main class for the example app. */
public class MainActivity extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Log.v("Example", "hello, world");
setContentView(R.layout.activity_main);
Button clickMeButton = findViewById(R.id.clickMeButton);
TextView exampleTextView = findViewById(R.id.exampleTextView);
ButtonPressHandler h = new ButtonPressHandler();
clickMeButton.setOnClickListener(
v -> exampleTextView.setText(h.onPressed(getApplication())));
}
}

@ -1,73 +0,0 @@
// Copyright 2021 gRPC authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#include <android/log.h>
#include <jni.h>
#include "examples/protos/helloworld.grpc.pb.h"
#include "examples/protos/helloworld.pb.h"
#include <grpcpp/create_channel_binder.h>
#include <grpcpp/security/binder_security_policy.h>
extern "C" JNIEXPORT jstring JNICALL
Java_io_grpc_binder_cpp_exampleclient_ButtonPressHandler_native_1entry(
JNIEnv* env, jobject /*this*/, jobject application) {
// Lower the gRPC logging level, here it is just for demo and debugging
// purpose.
setenv("GRPC_VERBOSITY", "INFO", true);
if (grpc::experimental::InitializeBinderChannelJavaClass(env)) {
__android_log_print(ANDROID_LOG_INFO, "DemoClient",
"InitializeBinderChannelJavaClass succeed");
} else {
__android_log_print(ANDROID_LOG_INFO, "DemoClient",
"InitializeBinderChannelJavaClass failed");
}
static bool first = true;
static std::shared_ptr<grpc::Channel> channel;
if (first) {
first = false;
JavaVM* jvm;
{
jint result = env->GetJavaVM(&jvm);
assert(result == 0);
}
grpc::ChannelArguments ch_args;
// This is not required since "grpc.io.action.BIND" is already the default.
ch_args.SetString("grpc.binder.custom_android_intent_action_name",
"grpc.io.action.BIND");
channel = grpc::experimental::CreateCustomBinderChannel(
env, application, "io.grpc.binder.cpp.exampleserver",
"io.grpc.binder.cpp.exampleserver.ExportedEndpointService",
std::make_shared<
grpc::experimental::binder::SameSignatureSecurityPolicy>(
jvm, application),
ch_args);
return env->NewStringUTF("Clicked 1 time, channel created");
} else {
auto stub = helloworld::Greeter::NewStub(channel);
grpc::ClientContext context;
helloworld::HelloRequest request;
helloworld::HelloReply response;
request.set_name("BinderTransportClient");
grpc::Status status = stub->SayHello(&context, request, &response);
if (status.ok()) {
return env->NewStringUTF(response.message().c_str());
}
return env->NewStringUTF(
std::string("Clicked more than 1 time. Status not ok " +
std::to_string(status.error_code()))
.c_str());
}
}

@ -1,24 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:padding="16dp"
android:orientation="vertical"
android:gravity="center_vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="@+id/exampleTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:textSize="32dp"
android:text="@string/thinking_face"/>
<Button
android:id="@+id/clickMeButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="16dp"
android:text="@string/click_me_button"/>
</LinearLayout>

@ -1,5 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="click_me_button">Run example</string>
<string name="thinking_face">🤔</string>
</resources>

@ -1,21 +0,0 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="io.grpc.binder.cpp.exampleserver"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="29"
android:targetSdkVersion="30" />
<application
android:label="gRPC BinderTransport Server Cpp">
<activity
android:name=".MainActivity"
android:label="gRPC BinderTransport Server Cpp" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>

@ -1,10 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="io.grpc.binder.cpp.exampleserver">
<uses-sdk android:minSdkVersion="29" android:targetSdkVersion="30"/>
<application>
<service
android:name=".ExportedEndpointService"
android:exported="true"/>
</application>
</manifest>

@ -1,61 +0,0 @@
# Copyright 2021 gRPC authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
cc_library(
name = "jni_lib",
srcs = ["native.cc"],
linkopts = [
"-ldl",
"-llog",
"-lm",
"-Wl,--no-undefined",
],
deps = [
"//:grpc++",
"//examples/protos:helloworld_cc_grpc",
],
alwayslink = True,
)
android_library(
name = "activity",
srcs = [
"ButtonPressHandler.java",
"MainActivity.java",
],
manifest = "AndroidManifest.xml",
resource_files = glob(["res/**"]),
deps = [
":endpoint",
":jni_lib",
],
)
android_library(
name = "endpoint",
srcs = ["ExportedEndpointService.java"],
exports_manifest = True,
manifest = "AndroidManifest_endpoint.xml",
deps = [
"@binder_transport_android_helper//io/grpc/binder/cpp:connection_helper",
],
)
android_binary(
name = "app",
manifest = "AndroidManifest.xml",
deps = [
":activity",
],
)

@ -1,13 +0,0 @@
package io.grpc.binder.cpp.exampleserver;
import android.app.Application;
public class ButtonPressHandler {
static {
System.loadLibrary("app");
}
public String onPressed(Application application) {
return "Server Button Pressed";
}
}

@ -1,26 +0,0 @@
package io.grpc.binder.cpp.exampleserver;
import android.app.Service;
import android.content.Intent;
import android.os.IBinder;
import android.content.Context;
import io.grpc.binder.cpp.GrpcCppServerBuilder;
/** Exposes gRPC services running in the main process */
public final class ExportedEndpointService extends Service {
static {
System.loadLibrary("app");
}
public ExportedEndpointService() {
init_grpc_server(this);
}
@Override
public IBinder onBind(Intent intent) {
// The argument should match the URI passed into grpc::ServerBuilder::AddListeningPort
return GrpcCppServerBuilder.GetEndpointBinder("binder:example.service");
}
public native void init_grpc_server(Context context);
}

@ -1,27 +0,0 @@
package io.grpc.binder.cpp.exampleserver;
import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
import android.widget.Button;
import android.widget.TextView;
import io.grpc.binder.cpp.exampleserver.R;
/** Main class for the example app. */
public class MainActivity extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Log.v("Example", "hello, world");
setContentView(R.layout.activity_main);
Button clickMeButton = findViewById(R.id.clickMeButton);
TextView exampleTextView = findViewById(R.id.exampleTextView);
ButtonPressHandler h = new ButtonPressHandler();
clickMeButton.setOnClickListener(
v -> exampleTextView.setText(h.onPressed(getApplication())));
}
}

@ -1,83 +0,0 @@
// Copyright 2021 gRPC authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#include <android/log.h>
#include <jni.h>
#include "examples/protos/helloworld.grpc.pb.h"
#include "examples/protos/helloworld.pb.h"
#include <grpcpp/create_channel_binder.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/security/binder_credentials.h>
#include <grpcpp/security/binder_security_policy.h>
namespace {
class GreeterService : public helloworld::Greeter::Service {
public:
grpc::Status SayHello(grpc::ServerContext*,
const helloworld::HelloRequest* request,
helloworld::HelloReply* response) override {
__android_log_print(ANDROID_LOG_INFO, "DemoServer", "Line number %d",
__LINE__);
__android_log_print(ANDROID_LOG_INFO, "DemoServer", "Got hello request: %s",
request->name().c_str());
response->set_message("Hi, " + request->name());
return grpc::Status::OK;
}
};
} // namespace
extern "C" JNIEXPORT void JNICALL
Java_io_grpc_binder_cpp_exampleserver_ExportedEndpointService_init_1grpc_1server(
JNIEnv* env, jobject /*this*/, jobject context) {
// Lower the gRPC logging level, here it is just for demo and debugging
// purpose.
setenv("GRPC_VERBOSITY", "INFO", true);
__android_log_print(ANDROID_LOG_INFO, "DemoServer", "Line number %d",
__LINE__);
static std::unique_ptr<grpc::Server> server = nullptr;
if (server != nullptr) {
// Already initiated
return;
}
if (grpc::experimental::InitializeBinderChannelJavaClass(env)) {
__android_log_print(ANDROID_LOG_INFO, "DemoServer",
"InitializeBinderChannelJavaClass succeed");
} else {
__android_log_print(ANDROID_LOG_INFO, "DemoServer",
"InitializeBinderChannelJavaClass failed");
}
static GreeterService service;
grpc::ServerBuilder server_builder;
server_builder.RegisterService(&service);
JavaVM* jvm;
{
jint result = env->GetJavaVM(&jvm);
assert(result == 0);
}
server_builder.AddListeningPort(
"binder:example.service",
grpc::experimental::BinderServerCredentials(
std::make_shared<
grpc::experimental::binder::SameSignatureSecurityPolicy>(
jvm, context)));
server = server_builder.BuildAndStart();
}

@ -1,24 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:padding="16dp"
android:orientation="vertical"
android:gravity="center_vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="@+id/exampleTextView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:textSize="32dp"
android:text="@string/thinking_face"/>
<Button
android:id="@+id/clickMeButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginTop="16dp"
android:text="@string/click_me_button"/>
</LinearLayout>

@ -1,5 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="click_me_button">Run example</string>
<string name="thinking_face">🤔</string>
</resources>

@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
set(helloworld_PROTOBUF_PROTOC_EXECUTABLE "/usr/local/bin/protoc" CACHE STRING "Protoc binary on host")
set(helloworld_GRPC_CPP_PLUGIN_EXECUTABLE "/usr/local/bin/grpc_cpp_plugin" CACHE STRING "gRPC CPP plugin binary on host")

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building keyvaluestore.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(Cancellation C CXX)

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -26,8 +28,6 @@
#include "absl/flags/parse.h"
#include "helper.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -21,8 +23,6 @@
#include "absl/strings/str_format.h"
#include "helper.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building keyvaluestore.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(Cancellation C CXX)

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -23,8 +25,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_cat.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -21,8 +23,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building route_guide.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
if(MSVC)
add_definitions(-D_WIN32_WINNT=0x600)

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(Compression C CXX)

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,9 @@
*
*/
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/support/string_ref.h>
#include <sys/types.h>
#include <chrono>
@ -34,10 +37,6 @@
#include "opentelemetry/exporters/prometheus/exporter_options.h"
#include "opentelemetry/sdk/metrics/meter_provider.h"
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/support/string_ref.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,13 @@
*
*/
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/xds_server_builder.h>
#include <iostream>
#include <memory>
#include <string>
@ -27,14 +34,6 @@
#include "opentelemetry/exporters/prometheus/exporter_factory.h"
#include "opentelemetry/exporters/prometheus/exporter_options.h"
#include "opentelemetry/sdk/metrics/meter_provider.h"
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/xds_server_builder.h>
#include "src/core/util/gethostname.h"
#ifdef BAZEL_BUILD

@ -44,6 +44,8 @@ cc_binary(
"@com_google_absl//absl/flags:flag",
"@com_google_absl//absl/flags:parse",
"@com_google_absl//absl/log",
"@com_google_absl//absl/log:globals",
"@com_google_absl//absl/log:initialize",
"@io_opentelemetry_cpp//exporters/prometheus:prometheus_exporter",
"@io_opentelemetry_cpp//sdk/src/metrics",
],

@ -27,6 +27,8 @@ RUN cp -rL /workdir/bazel-bin/examples/cpp/csm/observability/csm_greeter_server
FROM python:3.9-slim-bookworm
ENV GRPC_TRACE="xds_client,xds_resolver,xds_cluster_manager_lb,cds_lb,xds_cluster_resolver_lb,priority_lb,xds_cluster_impl_lb,weighted_target_lb,xds_server_config_fetcher,ring_hash_lb,outlier_detection_lb,xds_wrr_locality_lb,xds_override_host_lb"
RUN apt-get update \
&& apt-get -y upgrade \
&& apt-get -y autoremove \

@ -16,6 +16,9 @@
*
*/
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/support/string_ref.h>
#include <sys/types.h>
#include <chrono>
@ -32,10 +35,6 @@
#include "opentelemetry/exporters/prometheus/exporter_options.h"
#include "opentelemetry/sdk/metrics/meter_provider.h"
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/support/string_ref.h>
ABSL_FLAG(std::string, target, "xds:///helloworld:50051", "Target string");
ABSL_FLAG(std::string, prometheus_endpoint, "localhost:9464",
"Prometheus exporter endpoint");

@ -16,12 +16,21 @@
*
*/
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/xds_server_builder.h>
#include <iostream>
#include <memory>
#include <string>
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include "absl/log/globals.h"
#include "absl/log/initialize.h"
#include "absl/log/log.h"
#include "absl/strings/str_cat.h"
#include "examples/cpp/otel/util.h"
@ -29,19 +38,15 @@
#include "opentelemetry/exporters/prometheus/exporter_options.h"
#include "opentelemetry/sdk/metrics/meter_provider.h"
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/csm_observability.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/xds_server_builder.h>
ABSL_FLAG(int32_t, port, 50051, "Server port for service.");
ABSL_FLAG(std::string, prometheus_endpoint, "localhost:9464",
"Prometheus exporter endpoint");
int main(int argc, char** argv) {
absl::ParseCommandLine(argc, argv);
absl::SetStderrThreshold(absl::LogSeverityAtLeast::kInfo);
absl::SetGlobalVLogLevel(2);
absl::InitializeLog();
opentelemetry::exporter::metrics::PrometheusExporterOptions opts;
// default was "localhost:9464" which causes connection issue across GKE pods
opts.url = "0.0.0.0:9464";

@ -16,7 +16,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building this example.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(Deadline C CXX)

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -23,8 +25,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_cat.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <chrono>
#include <condition_variable>
#include <iostream>
@ -25,8 +27,6 @@
#include "absl/strings/match.h"
#include "absl/strings/str_format.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -19,8 +21,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -20,11 +25,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(ErrorDetails C CXX)

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -22,12 +24,9 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#include "google/rpc/error_details.pb.h"
#include "src/proto/grpc/status/status.pb.h"
#else
#include "error_details.pb.h"

@ -12,6 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -22,14 +26,9 @@
#include "absl/strings/str_format.h"
#include "absl/synchronization/mutex.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#include "google/rpc/error_details.pb.h"
#include "src/proto/grpc/status/status.pb.h"
#else
#include "error_details.pb.h"

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(ErrorHandling C CXX)

@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -22,8 +24,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -22,10 +26,6 @@
#include "absl/strings/str_format.h"
#include "absl/synchronization/mutex.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building example.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(HelloWorld C CXX)

@ -16,6 +16,10 @@
*
*/
#include <grpc/grpc.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <cstddef>
#include <ostream>
#include <string>
@ -23,10 +27,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpc/grpc.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,10 @@
*
*/
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <cstddef>
#include <cstdint>
#include <iostream>
@ -25,10 +29,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,16 +16,16 @@
*
*/
#include <grpc/grpc.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <string>
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpc/grpc.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -15,6 +15,11 @@
* limitations under the License.
*
*/
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/support/status.h>
#include <cstddef>
#include <iostream>
#include <memory>
@ -24,11 +29,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_cat.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/support/status.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,9 @@
//
//
#include <grpcpp/ext/gcp_observability.h>
#include <grpcpp/grpcpp.h>
#include <chrono>
#include <iostream>
#include <memory>
@ -25,9 +28,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/ext/gcp_observability.h>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,11 @@
//
//
#include <grpcpp/ext/gcp_observability.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <chrono>
#include <csignal>
#include <iostream>
@ -27,11 +32,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/gcp_observability.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(GenericAPI C CXX)

@ -12,6 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/generic/generic_stub.h>
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -22,9 +25,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/generic/generic_stub.h>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -12,6 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -22,9 +25,6 @@
#include "absl/strings/str_format.h"
#include "absl/synchronization/mutex.h"
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(HelloWorld C CXX)

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -25,11 +27,8 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#include "src/proto/grpc/health/v1/health.grpc.pb.h"
#else
#include "health.grpc.pb.h"

@ -16,6 +16,10 @@
*
*/
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -24,10 +28,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(HelloWorld C CXX)

@ -20,7 +20,7 @@
# including the "helloworld" project itself.
# See https://blog.kitware.com/cmake-superbuilds-git-submodules/
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
# Project
project(HelloWorld-SuperBuild C CXX)

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -24,8 +26,6 @@
#include "absl/flags/parse.h"
#include "absl/log/check.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -25,8 +27,6 @@
#include "absl/flags/parse.h"
#include "absl/log/check.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -26,8 +28,6 @@
#include "absl/log/check.h"
#include "absl/strings/str_format.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -25,8 +27,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,10 @@
*
*/
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -24,10 +28,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -23,8 +25,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,10 @@
*
*/
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -24,10 +28,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
@ -23,8 +25,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,12 @@
*
*/
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/xds_server_builder.h>
#include <iostream>
#include <memory>
#include <string>
@ -25,12 +31,6 @@
#include "absl/log/log.h"
#include "absl/strings/str_cat.h"
#include <grpcpp/ext/admin_services.h>
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <grpcpp/xds_server_builder.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building keyvaluestore.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(KeyValueStore C CXX)

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/support/client_interceptor.h>
#include <map>
#include "absl/log/check.h"
#include <grpcpp/support/client_interceptor.h>
#ifdef BAZEL_BUILD
#include "examples/protos/keyvaluestore.grpc.pb.h"
#else

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -25,8 +27,6 @@
#include "caching_interceptor.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/keyvaluestore.grpc.pb.h"
#else

@ -16,14 +16,14 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <grpcpp/support/server_interceptor.h>
#include <iostream>
#include <memory>
#include <string>
#include <vector>
#include <grpcpp/grpcpp.h>
#include <grpcpp/support/server_interceptor.h>
#ifdef BAZEL_BUILD
#include "examples/protos/keyvaluestore.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(HelloWorld C CXX)

@ -16,6 +16,8 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <condition_variable>
#include <iostream>
#include <memory>
@ -26,8 +28,6 @@
#include "absl/flags/flag.h"
#include "absl/flags/parse.h"
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,6 +16,10 @@
*
*/
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#include <iostream>
#include <memory>
#include <string>
@ -24,10 +28,6 @@
#include "absl/flags/parse.h"
#include "absl/strings/str_format.h"
#include <grpcpp/ext/proto_server_reflection_plugin.h>
#include <grpcpp/grpcpp.h>
#include <grpcpp/health_check_service_interface.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(LoadBalancing C CXX)

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(Metadata C CXX)

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -16,12 +16,12 @@
*
*/
#include <grpcpp/grpcpp.h>
#include <iostream>
#include <memory>
#include <string>
#include <grpcpp/grpcpp.h>
#ifdef BAZEL_BUILD
#include "examples/protos/helloworld.grpc.pb.h"
#else

@ -17,7 +17,7 @@
# See cmake_externalproject/CMakeLists.txt for all-in-one cmake build
# that automatically builds all the dependencies before building helloworld.
cmake_minimum_required(VERSION 3.8)
cmake_minimum_required(VERSION 3.16)
project(Multiplex C CXX)

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save