async-grpc-xds 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (239) hide show
  1. checksums.yaml +7 -0
  2. checksums.yaml.gz.sig +0 -0
  3. data/fixtures/async/grpc/test_interface.rb +79 -0
  4. data/fixtures/async/grpc/test_message.rb +56 -0
  5. data/lib/async/grpc/xds/ads_stream.rb +70 -0
  6. data/lib/async/grpc/xds/client.rb +255 -0
  7. data/lib/async/grpc/xds/context.rb +201 -0
  8. data/lib/async/grpc/xds/control_plane.rb +143 -0
  9. data/lib/async/grpc/xds/discovery_client.rb +356 -0
  10. data/lib/async/grpc/xds/health_checker.rb +88 -0
  11. data/lib/async/grpc/xds/load_balancer.rb +196 -0
  12. data/lib/async/grpc/xds/resource_builder.rb +138 -0
  13. data/lib/async/grpc/xds/resource_cache.rb +55 -0
  14. data/lib/async/grpc/xds/resources.rb +270 -0
  15. data/lib/async/grpc/xds/server.rb +34 -0
  16. data/lib/async/grpc/xds/service.rb +117 -0
  17. data/lib/async/grpc/xds/version.rb +12 -0
  18. data/lib/async/grpc/xds.rb +42 -0
  19. data/lib/envoy/annotations/deprecation_pb.rb +19 -0
  20. data/lib/envoy/config/cluster/v3/circuit_breaker_pb.rb +31 -0
  21. data/lib/envoy/config/cluster/v3/cluster_pb.rb +80 -0
  22. data/lib/envoy/config/cluster/v3/filter_pb.rb +28 -0
  23. data/lib/envoy/config/cluster/v3/outlier_detection_pb.rb +29 -0
  24. data/lib/envoy/config/core/v3/address_pb.rb +38 -0
  25. data/lib/envoy/config/core/v3/backoff_pb.rb +27 -0
  26. data/lib/envoy/config/core/v3/base_pb.rb +68 -0
  27. data/lib/envoy/config/core/v3/cel_pb.rb +24 -0
  28. data/lib/envoy/config/core/v3/config_source_pb.rb +42 -0
  29. data/lib/envoy/config/core/v3/event_service_config_pb.rb +27 -0
  30. data/lib/envoy/config/core/v3/extension_pb.rb +26 -0
  31. data/lib/envoy/config/core/v3/grpc_method_list_pb.rb +27 -0
  32. data/lib/envoy/config/core/v3/grpc_service_pb.rb +45 -0
  33. data/lib/envoy/config/core/v3/health_check_pb.rb +47 -0
  34. data/lib/envoy/config/core/v3/http_service_pb.rb +27 -0
  35. data/lib/envoy/config/core/v3/http_uri_pb.rb +27 -0
  36. data/lib/envoy/config/core/v3/protocol_pb.rb +51 -0
  37. data/lib/envoy/config/core/v3/proxy_protocol_pb.rb +31 -0
  38. data/lib/envoy/config/core/v3/resolver_pb.rb +27 -0
  39. data/lib/envoy/config/core/v3/socket_cmsg_headers_pb.rb +25 -0
  40. data/lib/envoy/config/core/v3/socket_option_pb.rb +31 -0
  41. data/lib/envoy/config/core/v3/substitution_format_string_pb.rb +30 -0
  42. data/lib/envoy/config/core/v3/udp_socket_config_pb.rb +26 -0
  43. data/lib/envoy/config/endpoint/v3/endpoint_components_pb.rb +40 -0
  44. data/lib/envoy/config/endpoint/v3/endpoint_pb.rb +32 -0
  45. data/lib/envoy/config/endpoint/v3/load_report_pb.rb +36 -0
  46. data/lib/envoy/service/discovery/v3/ads_pb.rb +26 -0
  47. data/lib/envoy/service/discovery/v3/aggregated_discovery_service.rb +64 -0
  48. data/lib/envoy/service/discovery/v3/discovery_pb.rb +42 -0
  49. data/lib/envoy/type/matcher/v3/address_pb.rb +25 -0
  50. data/lib/envoy/type/matcher/v3/filter_state_pb.rb +27 -0
  51. data/lib/envoy/type/matcher/v3/http_inputs_pb.rb +29 -0
  52. data/lib/envoy/type/matcher/v3/metadata_pb.rb +28 -0
  53. data/lib/envoy/type/matcher/v3/node_pb.rb +27 -0
  54. data/lib/envoy/type/matcher/v3/number_pb.rb +27 -0
  55. data/lib/envoy/type/matcher/v3/path_pb.rb +27 -0
  56. data/lib/envoy/type/matcher/v3/regex_pb.rb +30 -0
  57. data/lib/envoy/type/matcher/v3/status_code_input_pb.rb +25 -0
  58. data/lib/envoy/type/matcher/v3/string_pb.rb +29 -0
  59. data/lib/envoy/type/matcher/v3/struct_pb.rb +28 -0
  60. data/lib/envoy/type/matcher/v3/value_pb.rb +31 -0
  61. data/lib/envoy/type/metadata/v3/metadata_pb.rb +32 -0
  62. data/lib/envoy/type/v3/hash_policy_pb.rb +26 -0
  63. data/lib/envoy/type/v3/http_pb.rb +22 -0
  64. data/lib/envoy/type/v3/http_status_pb.rb +25 -0
  65. data/lib/envoy/type/v3/percent_pb.rb +26 -0
  66. data/lib/envoy/type/v3/range_pb.rb +25 -0
  67. data/lib/envoy/type/v3/ratelimit_strategy_pb.rb +28 -0
  68. data/lib/envoy/type/v3/ratelimit_unit_pb.rb +22 -0
  69. data/lib/envoy/type/v3/semantic_version_pb.rb +23 -0
  70. data/lib/envoy/type/v3/token_bucket_pb.rb +26 -0
  71. data/lib/envoy.rb +83 -0
  72. data/lib/google/protobuf/any_pb.rb +18 -0
  73. data/lib/google/protobuf/duration_pb.rb +18 -0
  74. data/lib/google/protobuf/empty_pb.rb +18 -0
  75. data/lib/google/protobuf/struct_pb.rb +21 -0
  76. data/lib/google/protobuf/timestamp_pb.rb +18 -0
  77. data/lib/google/protobuf/wrappers_pb.rb +26 -0
  78. data/lib/google/rpc/status_pb.rb +20 -0
  79. data/lib/udpa/annotations/migrate_pb.rb +22 -0
  80. data/lib/udpa/annotations/security_pb.rb +23 -0
  81. data/lib/udpa/annotations/sensitive_pb.rb +19 -0
  82. data/lib/udpa/annotations/status_pb.rb +21 -0
  83. data/lib/udpa/annotations/versioning_pb.rb +20 -0
  84. data/lib/validate/validate_pb.rb +43 -0
  85. data/lib/xds/annotations/v3/status_pb.rb +26 -0
  86. data/lib/xds/core/v3/authority_pb.rb +23 -0
  87. data/lib/xds/core/v3/cidr_pb.rb +24 -0
  88. data/lib/xds/core/v3/collection_entry_pb.rb +26 -0
  89. data/lib/xds/core/v3/context_params_pb.rb +22 -0
  90. data/lib/xds/core/v3/extension_pb.rb +23 -0
  91. data/lib/xds/core/v3/resource_locator_pb.rb +26 -0
  92. data/lib/xds/core/v3/resource_name_pb.rb +24 -0
  93. data/lib/xds/core/v3/resource_pb.rb +24 -0
  94. data/lib/xds/type/matcher/v3/domain_pb.rb +27 -0
  95. data/lib/xds/type/matcher/v3/http_inputs_pb.rb +22 -0
  96. data/lib/xds/type/matcher/v3/ip_pb.rb +28 -0
  97. data/lib/xds/type/matcher/v3/matcher_pb.rb +34 -0
  98. data/lib/xds/type/matcher/v3/range_pb.rb +31 -0
  99. data/lib/xds/type/matcher/v3/regex_pb.rb +25 -0
  100. data/lib/xds/type/matcher/v3/string_pb.rb +27 -0
  101. data/license.md +21 -0
  102. data/plan.md +156 -0
  103. data/proto/envoy/annotations/deprecation.proto +34 -0
  104. data/proto/envoy/annotations/resource.proto +19 -0
  105. data/proto/envoy/config/README.md +3 -0
  106. data/proto/envoy/config/cluster/v3/BUILD +18 -0
  107. data/proto/envoy/config/cluster/v3/circuit_breaker.proto +121 -0
  108. data/proto/envoy/config/cluster/v3/cluster.proto +1407 -0
  109. data/proto/envoy/config/cluster/v3/filter.proto +40 -0
  110. data/proto/envoy/config/cluster/v3/outlier_detection.proto +180 -0
  111. data/proto/envoy/config/core/v3/BUILD +16 -0
  112. data/proto/envoy/config/core/v3/address.proto +214 -0
  113. data/proto/envoy/config/core/v3/backoff.proto +37 -0
  114. data/proto/envoy/config/core/v3/base.proto +662 -0
  115. data/proto/envoy/config/core/v3/cel.proto +63 -0
  116. data/proto/envoy/config/core/v3/config_source.proto +283 -0
  117. data/proto/envoy/config/core/v3/event_service_config.proto +29 -0
  118. data/proto/envoy/config/core/v3/extension.proto +32 -0
  119. data/proto/envoy/config/core/v3/grpc_method_list.proto +33 -0
  120. data/proto/envoy/config/core/v3/grpc_service.proto +355 -0
  121. data/proto/envoy/config/core/v3/health_check.proto +443 -0
  122. data/proto/envoy/config/core/v3/http_service.proto +35 -0
  123. data/proto/envoy/config/core/v3/http_uri.proto +58 -0
  124. data/proto/envoy/config/core/v3/protocol.proto +807 -0
  125. data/proto/envoy/config/core/v3/proxy_protocol.proto +114 -0
  126. data/proto/envoy/config/core/v3/resolver.proto +36 -0
  127. data/proto/envoy/config/core/v3/socket_cmsg_headers.proto +28 -0
  128. data/proto/envoy/config/core/v3/socket_option.proto +108 -0
  129. data/proto/envoy/config/core/v3/substitution_format_string.proto +136 -0
  130. data/proto/envoy/config/core/v3/udp_socket_config.proto +32 -0
  131. data/proto/envoy/config/endpoint/v3/BUILD +16 -0
  132. data/proto/envoy/config/endpoint/v3/endpoint.proto +137 -0
  133. data/proto/envoy/config/endpoint/v3/endpoint_components.proto +229 -0
  134. data/proto/envoy/config/endpoint/v3/load_report.proto +220 -0
  135. data/proto/envoy/config/listener/v3/BUILD +18 -0
  136. data/proto/envoy/config/listener/v3/api_listener.proto +34 -0
  137. data/proto/envoy/config/listener/v3/listener.proto +455 -0
  138. data/proto/envoy/config/listener/v3/listener_components.proto +353 -0
  139. data/proto/envoy/config/listener/v3/quic_config.proto +108 -0
  140. data/proto/envoy/config/listener/v3/udp_listener_config.proto +52 -0
  141. data/proto/envoy/config/route/v3/BUILD +19 -0
  142. data/proto/envoy/config/route/v3/route.proto +172 -0
  143. data/proto/envoy/config/route/v3/route_components.proto +2918 -0
  144. data/proto/envoy/config/route/v3/scoped_route.proto +133 -0
  145. data/proto/envoy/extensions/transport_sockets/tls/v3/BUILD +14 -0
  146. data/proto/envoy/extensions/transport_sockets/tls/v3/cert.proto +12 -0
  147. data/proto/envoy/extensions/transport_sockets/tls/v3/common.proto +597 -0
  148. data/proto/envoy/extensions/transport_sockets/tls/v3/secret.proto +61 -0
  149. data/proto/envoy/extensions/transport_sockets/tls/v3/tls.proto +366 -0
  150. data/proto/envoy/extensions/transport_sockets/tls/v3/tls_spiffe_validator_config.proto +67 -0
  151. data/proto/envoy/service/README.md +3 -0
  152. data/proto/envoy/service/discovery/v3/BUILD +13 -0
  153. data/proto/envoy/service/discovery/v3/ads.proto +44 -0
  154. data/proto/envoy/service/discovery/v3/discovery.proto +443 -0
  155. data/proto/envoy/type/BUILD +9 -0
  156. data/proto/envoy/type/hash_policy.proto +28 -0
  157. data/proto/envoy/type/http.proto +24 -0
  158. data/proto/envoy/type/http_status.proto +140 -0
  159. data/proto/envoy/type/matcher/v3/address.proto +22 -0
  160. data/proto/envoy/type/matcher/v3/filter_state.proto +33 -0
  161. data/proto/envoy/type/matcher/v3/http_inputs.proto +71 -0
  162. data/proto/envoy/type/matcher/v3/metadata.proto +110 -0
  163. data/proto/envoy/type/matcher/v3/node.proto +29 -0
  164. data/proto/envoy/type/matcher/v3/number.proto +33 -0
  165. data/proto/envoy/type/matcher/v3/path.proto +31 -0
  166. data/proto/envoy/type/matcher/v3/regex.proto +97 -0
  167. data/proto/envoy/type/matcher/v3/status_code_input.proto +23 -0
  168. data/proto/envoy/type/matcher/v3/string.proto +94 -0
  169. data/proto/envoy/type/matcher/v3/struct.proto +91 -0
  170. data/proto/envoy/type/matcher/v3/value.proto +80 -0
  171. data/proto/envoy/type/metadata/v3/metadata.proto +117 -0
  172. data/proto/envoy/type/percent.proto +52 -0
  173. data/proto/envoy/type/range.proto +43 -0
  174. data/proto/envoy/type/semantic_version.proto +24 -0
  175. data/proto/envoy/type/token_bucket.proto +36 -0
  176. data/proto/envoy/type/v3/BUILD +12 -0
  177. data/proto/envoy/type/v3/hash_policy.proto +43 -0
  178. data/proto/envoy/type/v3/http.proto +24 -0
  179. data/proto/envoy/type/v3/http_status.proto +199 -0
  180. data/proto/envoy/type/v3/percent.proto +57 -0
  181. data/proto/envoy/type/v3/range.proto +50 -0
  182. data/proto/envoy/type/v3/ratelimit_strategy.proto +79 -0
  183. data/proto/envoy/type/v3/ratelimit_unit.proto +37 -0
  184. data/proto/envoy/type/v3/semantic_version.proto +27 -0
  185. data/proto/envoy/type/v3/token_bucket.proto +39 -0
  186. data/proto/google/protobuf/any.proto +162 -0
  187. data/proto/google/protobuf/duration.proto +115 -0
  188. data/proto/google/protobuf/empty.proto +51 -0
  189. data/proto/google/protobuf/struct.proto +95 -0
  190. data/proto/google/protobuf/timestamp.proto +145 -0
  191. data/proto/google/protobuf/wrappers.proto +157 -0
  192. data/proto/google/rpc/status.proto +47 -0
  193. data/proto/readme.md +70 -0
  194. data/proto/udpa/annotations/migrate.proto +49 -0
  195. data/proto/udpa/annotations/security.proto +31 -0
  196. data/proto/udpa/annotations/sensitive.proto +14 -0
  197. data/proto/udpa/annotations/status.proto +34 -0
  198. data/proto/udpa/annotations/versioning.proto +17 -0
  199. data/proto/validate/validate.proto +862 -0
  200. data/proto/xds/annotations/v3/migrate.proto +46 -0
  201. data/proto/xds/annotations/v3/security.proto +30 -0
  202. data/proto/xds/annotations/v3/sensitive.proto +16 -0
  203. data/proto/xds/annotations/v3/status.proto +59 -0
  204. data/proto/xds/annotations/v3/versioning.proto +20 -0
  205. data/proto/xds/core/v3/authority.proto +22 -0
  206. data/proto/xds/core/v3/cidr.proto +25 -0
  207. data/proto/xds/core/v3/collection_entry.proto +55 -0
  208. data/proto/xds/core/v3/context_params.proto +23 -0
  209. data/proto/xds/core/v3/extension.proto +26 -0
  210. data/proto/xds/core/v3/resource.proto +29 -0
  211. data/proto/xds/core/v3/resource_locator.proto +118 -0
  212. data/proto/xds/core/v3/resource_name.proto +42 -0
  213. data/proto/xds/type/matcher/v3/cel.proto +37 -0
  214. data/proto/xds/type/matcher/v3/domain.proto +46 -0
  215. data/proto/xds/type/matcher/v3/http_inputs.proto +23 -0
  216. data/proto/xds/type/matcher/v3/ip.proto +53 -0
  217. data/proto/xds/type/matcher/v3/matcher.proto +144 -0
  218. data/proto/xds/type/matcher/v3/range.proto +69 -0
  219. data/proto/xds/type/matcher/v3/regex.proto +46 -0
  220. data/proto/xds/type/matcher/v3/string.proto +71 -0
  221. data/proto/xds/type/v3/cel.proto +77 -0
  222. data/proto/xds/type/v3/range.proto +40 -0
  223. data/proto/xds/type/v3/typed_struct.proto +44 -0
  224. data/readme.md +37 -0
  225. data/releases.md +5 -0
  226. data/xds/Dockerfile.backend +24 -0
  227. data/xds/Dockerfile.control-plane +22 -0
  228. data/xds/backend_server.rb +68 -0
  229. data/xds/docker-compose.yaml +89 -0
  230. data/xds/go.mod +22 -0
  231. data/xds/go.sum +82 -0
  232. data/xds/readme.md +122 -0
  233. data/xds/test/async/grpc/xds/client.rb +294 -0
  234. data/xds/test/async/grpc/xds/control_plane.rb +94 -0
  235. data/xds/test_server.go +355 -0
  236. data/xds/update_protos.sh +123 -0
  237. data.tar.gz.sig +0 -0
  238. metadata +386 -0
  239. metadata.gz.sig +2 -0
@@ -0,0 +1,355 @@
1
+ syntax = "proto3";
2
+
3
+ package envoy.config.core.v3;
4
+
5
+ import "envoy/config/core/v3/base.proto";
6
+
7
+ import "google/protobuf/any.proto";
8
+ import "google/protobuf/duration.proto";
9
+ import "google/protobuf/empty.proto";
10
+ import "google/protobuf/struct.proto";
11
+ import "google/protobuf/wrappers.proto";
12
+
13
+ import "udpa/annotations/sensitive.proto";
14
+ import "udpa/annotations/status.proto";
15
+ import "udpa/annotations/versioning.proto";
16
+ import "validate/validate.proto";
17
+
18
+ option java_package = "io.envoyproxy.envoy.config.core.v3";
19
+ option java_outer_classname = "GrpcServiceProto";
20
+ option java_multiple_files = true;
21
+ option go_package = "github.com/envoyproxy/go-control-plane/envoy/config/core/v3;corev3";
22
+ option (udpa.annotations.file_status).package_version_status = ACTIVE;
23
+
24
+ // [#protodoc-title: gRPC services]
25
+
26
+ // gRPC service configuration. This is used by :ref:`ApiConfigSource
27
+ // <envoy_v3_api_msg_config.core.v3.ApiConfigSource>` and filter configurations.
28
+ // [#next-free-field: 7]
29
+ message GrpcService {
30
+ option (udpa.annotations.versioning).previous_message_type = "envoy.api.v2.core.GrpcService";
31
+
32
+ // [#next-free-field: 6]
33
+ message EnvoyGrpc {
34
+ option (udpa.annotations.versioning).previous_message_type =
35
+ "envoy.api.v2.core.GrpcService.EnvoyGrpc";
36
+
37
+ // The name of the upstream gRPC cluster. SSL credentials will be supplied
38
+ // in the :ref:`Cluster <envoy_v3_api_msg_config.cluster.v3.Cluster>` :ref:`transport_socket
39
+ // <envoy_v3_api_field_config.cluster.v3.Cluster.transport_socket>`.
40
+ string cluster_name = 1 [(validate.rules).string = {min_len: 1}];
41
+
42
+ // The ``:authority`` header in the grpc request. If this field is not set, the authority header value will be ``cluster_name``.
43
+ // Note that this authority does not override the SNI. The SNI is provided by the transport socket of the cluster.
44
+ string authority = 2
45
+ [(validate.rules).string =
46
+ {min_len: 0 max_bytes: 16384 well_known_regex: HTTP_HEADER_VALUE strict: false}];
47
+
48
+ // Specifies the retry backoff policy for re-establishing long‑lived xDS gRPC streams.
49
+ //
50
+ // This field is optional. If ``retry_back_off.max_interval`` is not provided, it will be set to
51
+ // ten times the configured ``retry_back_off.base_interval``.
52
+ //
53
+ // .. note::
54
+ //
55
+ // This field is only honored for management‑plane xDS gRPC streams created from
56
+ // :ref:`ApiConfigSource <envoy_v3_api_msg_config.core.v3.ApiConfigSource>` that use
57
+ // ``envoy_grpc``. Data‑plane gRPC clients (for example external authorization or external
58
+ // processing filters) must use :ref:`GrpcService.retry_policy
59
+ // <envoy_v3_api_field_config.core.v3.GrpcService.retry_policy>` instead.
60
+ //
61
+ // If not set, xDS gRPC streams default to a base interval of 500ms and a maximum interval of 30s.
62
+ RetryPolicy retry_policy = 3;
63
+
64
+ // Maximum gRPC message size that is allowed to be received.
65
+ // If a message over this limit is received, the gRPC stream is terminated with the RESOURCE_EXHAUSTED error.
66
+ // This limit is applied to individual messages in the streaming response and not the total size of streaming response.
67
+ // Defaults to 0, which means unlimited.
68
+ google.protobuf.UInt32Value max_receive_message_length = 4;
69
+
70
+ // This provides gRPC client level control over envoy generated headers.
71
+ // If false, the header will be sent but it can be overridden by per stream option.
72
+ // If true, the header will be removed and can not be overridden by per stream option.
73
+ // Default to false.
74
+ bool skip_envoy_headers = 5;
75
+ }
76
+
77
+ // [#next-free-field: 11]
78
+ message GoogleGrpc {
79
+ option (udpa.annotations.versioning).previous_message_type =
80
+ "envoy.api.v2.core.GrpcService.GoogleGrpc";
81
+
82
+ // See https://grpc.io/grpc/cpp/structgrpc_1_1_ssl_credentials_options.html.
83
+ message SslCredentials {
84
+ option (udpa.annotations.versioning).previous_message_type =
85
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.SslCredentials";
86
+
87
+ // PEM encoded server root certificates.
88
+ DataSource root_certs = 1;
89
+
90
+ // PEM encoded client private key.
91
+ DataSource private_key = 2 [(udpa.annotations.sensitive) = true];
92
+
93
+ // PEM encoded client certificate chain.
94
+ DataSource cert_chain = 3;
95
+ }
96
+
97
+ // Local channel credentials. Only UDS is supported for now.
98
+ // See https://github.com/grpc/grpc/pull/15909.
99
+ message GoogleLocalCredentials {
100
+ option (udpa.annotations.versioning).previous_message_type =
101
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.GoogleLocalCredentials";
102
+ }
103
+
104
+ // See https://grpc.io/docs/guides/auth.html#credential-types to understand Channel and Call
105
+ // credential types.
106
+ message ChannelCredentials {
107
+ option (udpa.annotations.versioning).previous_message_type =
108
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.ChannelCredentials";
109
+
110
+ oneof credential_specifier {
111
+ option (validate.required) = true;
112
+
113
+ SslCredentials ssl_credentials = 1;
114
+
115
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#a6beb3ac70ff94bd2ebbd89b8f21d1f61
116
+ google.protobuf.Empty google_default = 2;
117
+
118
+ GoogleLocalCredentials local_credentials = 3;
119
+ }
120
+ }
121
+
122
+ // [#next-free-field: 8]
123
+ message CallCredentials {
124
+ option (udpa.annotations.versioning).previous_message_type =
125
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.CallCredentials";
126
+
127
+ message ServiceAccountJWTAccessCredentials {
128
+ option (udpa.annotations.versioning).previous_message_type =
129
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.CallCredentials."
130
+ "ServiceAccountJWTAccessCredentials";
131
+
132
+ string json_key = 1;
133
+
134
+ uint64 token_lifetime_seconds = 2;
135
+ }
136
+
137
+ message GoogleIAMCredentials {
138
+ option (udpa.annotations.versioning).previous_message_type =
139
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.CallCredentials.GoogleIAMCredentials";
140
+
141
+ string authorization_token = 1;
142
+
143
+ string authority_selector = 2;
144
+ }
145
+
146
+ message MetadataCredentialsFromPlugin {
147
+ option (udpa.annotations.versioning).previous_message_type =
148
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.CallCredentials."
149
+ "MetadataCredentialsFromPlugin";
150
+
151
+ reserved 2;
152
+
153
+ reserved "config";
154
+
155
+ string name = 1;
156
+
157
+ // [#extension-category: envoy.grpc_credentials]
158
+ oneof config_type {
159
+ google.protobuf.Any typed_config = 3;
160
+ }
161
+ }
162
+
163
+ // Security token service configuration that allows Google gRPC to
164
+ // fetch security token from an OAuth 2.0 authorization server.
165
+ // See https://tools.ietf.org/html/draft-ietf-oauth-token-exchange-16 and
166
+ // https://github.com/grpc/grpc/pull/19587.
167
+ // [#next-free-field: 10]
168
+ message StsService {
169
+ option (udpa.annotations.versioning).previous_message_type =
170
+ "envoy.api.v2.core.GrpcService.GoogleGrpc.CallCredentials.StsService";
171
+
172
+ // URI of the token exchange service that handles token exchange requests.
173
+ // [#comment:TODO(asraa): Add URI validation when implemented. Tracked by
174
+ // https://github.com/bufbuild/protoc-gen-validate/issues/303]
175
+ string token_exchange_service_uri = 1;
176
+
177
+ // Location of the target service or resource where the client
178
+ // intends to use the requested security token.
179
+ string resource = 2;
180
+
181
+ // Logical name of the target service where the client intends to
182
+ // use the requested security token.
183
+ string audience = 3;
184
+
185
+ // The desired scope of the requested security token in the
186
+ // context of the service or resource where the token will be used.
187
+ string scope = 4;
188
+
189
+ // Type of the requested security token.
190
+ string requested_token_type = 5;
191
+
192
+ // The path of subject token, a security token that represents the
193
+ // identity of the party on behalf of whom the request is being made.
194
+ string subject_token_path = 6 [(validate.rules).string = {min_len: 1}];
195
+
196
+ // Type of the subject token.
197
+ string subject_token_type = 7 [(validate.rules).string = {min_len: 1}];
198
+
199
+ // The path of actor token, a security token that represents the identity
200
+ // of the acting party. The acting party is authorized to use the
201
+ // requested security token and act on behalf of the subject.
202
+ string actor_token_path = 8;
203
+
204
+ // Type of the actor token.
205
+ string actor_token_type = 9;
206
+ }
207
+
208
+ oneof credential_specifier {
209
+ option (validate.required) = true;
210
+
211
+ // Access token credentials.
212
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#ad3a80da696ffdaea943f0f858d7a360d.
213
+ string access_token = 1;
214
+
215
+ // Google Compute Engine credentials.
216
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#a6beb3ac70ff94bd2ebbd89b8f21d1f61
217
+ google.protobuf.Empty google_compute_engine = 2;
218
+
219
+ // Google refresh token credentials.
220
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#a96901c997b91bc6513b08491e0dca37c.
221
+ string google_refresh_token = 3;
222
+
223
+ // Service Account JWT Access credentials.
224
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#a92a9f959d6102461f66ee973d8e9d3aa.
225
+ ServiceAccountJWTAccessCredentials service_account_jwt_access = 4;
226
+
227
+ // Google IAM credentials.
228
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#a9fc1fc101b41e680d47028166e76f9d0.
229
+ GoogleIAMCredentials google_iam = 5;
230
+
231
+ // Custom authenticator credentials.
232
+ // https://grpc.io/grpc/cpp/namespacegrpc.html#a823c6a4b19ffc71fb33e90154ee2ad07.
233
+ // https://grpc.io/docs/guides/auth.html#extending-grpc-to-support-other-authentication-mechanisms.
234
+ MetadataCredentialsFromPlugin from_plugin = 6;
235
+
236
+ // Custom security token service which implements OAuth 2.0 token exchange.
237
+ // https://tools.ietf.org/html/draft-ietf-oauth-token-exchange-16
238
+ // See https://github.com/grpc/grpc/pull/19587.
239
+ StsService sts_service = 7;
240
+ }
241
+ }
242
+
243
+ // Channel arguments.
244
+ message ChannelArgs {
245
+ message Value {
246
+ // Pointer values are not supported, since they don't make any sense when
247
+ // delivered via the API.
248
+ oneof value_specifier {
249
+ option (validate.required) = true;
250
+
251
+ string string_value = 1;
252
+
253
+ int64 int_value = 2;
254
+ }
255
+ }
256
+
257
+ // See grpc_types.h GRPC_ARG #defines for keys that work here.
258
+ map<string, Value> args = 1;
259
+ }
260
+
261
+ // The target URI when using the `Google C++ gRPC client
262
+ // <https://github.com/grpc/grpc>`_.
263
+ string target_uri = 1 [(validate.rules).string = {min_len: 1}];
264
+
265
+ // The channel credentials to use. See `channel credentials
266
+ // <https://grpc.io/docs/guides/auth.html#credential-types>`_.
267
+ // Ignored if ``channel_credentials_plugin`` is set.
268
+ ChannelCredentials channel_credentials = 2;
269
+
270
+ // A list of channel credentials plugins.
271
+ // The data plane will iterate over the list in order and stop at the first credential type
272
+ // that it supports. This provides a mechanism for starting to use new credential types that
273
+ // are not yet supported by all data planes.
274
+ // [#not-implemented-hide:]
275
+ repeated google.protobuf.Any channel_credentials_plugin = 9;
276
+
277
+ // The call credentials to use. See `channel credentials
278
+ // <https://grpc.io/docs/guides/auth.html#credential-types>`_.
279
+ // Ignored if ``call_credentials_plugin`` is set.
280
+ repeated CallCredentials call_credentials = 3;
281
+
282
+ // A list of call credentials plugins. All supported plugins will be used.
283
+ // Unsupported plugin types will be ignored.
284
+ // [#not-implemented-hide:]
285
+ repeated google.protobuf.Any call_credentials_plugin = 10;
286
+
287
+ // The human readable prefix to use when emitting statistics for the gRPC
288
+ // service.
289
+ //
290
+ // .. csv-table::
291
+ // :header: Name, Type, Description
292
+ // :widths: 1, 1, 2
293
+ //
294
+ // streams_total, Counter, Total number of streams opened
295
+ // streams_closed_<gRPC status code>, Counter, Total streams closed with <gRPC status code>
296
+ string stat_prefix = 4 [(validate.rules).string = {min_len: 1}];
297
+
298
+ // The name of the Google gRPC credentials factory to use. This must have been registered with
299
+ // Envoy. If this is empty, a default credentials factory will be used that sets up channel
300
+ // credentials based on other configuration parameters.
301
+ string credentials_factory_name = 5;
302
+
303
+ // Additional configuration for site-specific customizations of the Google
304
+ // gRPC library.
305
+ google.protobuf.Struct config = 6;
306
+
307
+ // How many bytes each stream can buffer internally.
308
+ // If not set an implementation defined default is applied (1MiB).
309
+ google.protobuf.UInt32Value per_stream_buffer_limit_bytes = 7;
310
+
311
+ // Custom channels args.
312
+ ChannelArgs channel_args = 8;
313
+ }
314
+
315
+ reserved 4;
316
+
317
+ oneof target_specifier {
318
+ option (validate.required) = true;
319
+
320
+ // Envoy's in-built gRPC client.
321
+ // See the :ref:`gRPC services overview <arch_overview_grpc_services>`
322
+ // documentation for discussion on gRPC client selection.
323
+ EnvoyGrpc envoy_grpc = 1;
324
+
325
+ // `Google C++ gRPC client <https://github.com/grpc/grpc>`_
326
+ // See the :ref:`gRPC services overview <arch_overview_grpc_services>`
327
+ // documentation for discussion on gRPC client selection.
328
+ GoogleGrpc google_grpc = 2;
329
+ }
330
+
331
+ // The timeout for the gRPC request. This is the timeout for a specific
332
+ // request.
333
+ google.protobuf.Duration timeout = 3;
334
+
335
+ // Additional metadata to include in streams initiated to the GrpcService. This can be used for
336
+ // scenarios in which additional ad hoc authorization headers (e.g. ``x-foo-bar: baz-key``) are to
337
+ // be injected. For more information, including details on header value syntax, see the
338
+ // documentation on :ref:`custom request headers
339
+ // <config_http_conn_man_headers_custom_request_headers>`.
340
+ repeated HeaderValue initial_metadata = 5;
341
+
342
+ // Optional default retry policy for RPCs or streams initiated toward this gRPC service.
343
+ //
344
+ // If an async stream does not have a retry policy configured in its per‑stream options, this
345
+ // policy is used as the default.
346
+ //
347
+ // .. note::
348
+ //
349
+ // This field is only applied by Envoy gRPC (``envoy_grpc``) clients. Google gRPC
350
+ // (``google_grpc``) clients currently ignore this field.
351
+ //
352
+ // If not specified, no default retry policy is applied at the client level and retries only occur
353
+ // when explicitly configured in per‑stream options.
354
+ RetryPolicy retry_policy = 6;
355
+ }