grpc 1.58.3 → 1.59.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Makefile +48 -33
- data/include/grpc/event_engine/event_engine.h +6 -10
- data/include/grpc/impl/channel_arg_names.h +4 -0
- data/include/grpc/support/port_platform.h +74 -1
- data/src/core/ext/filters/channel_idle/channel_idle_filter.cc +22 -9
- data/src/core/ext/filters/client_channel/client_channel.cc +422 -56
- data/src/core/ext/filters/client_channel/client_channel.h +52 -8
- data/src/core/ext/filters/client_channel/client_channel_plugin.cc +15 -1
- data/src/core/ext/filters/client_channel/dynamic_filters.h +2 -0
- data/src/core/ext/filters/client_channel/{http_proxy.cc → http_proxy_mapper.cc} +1 -1
- data/src/core/ext/filters/client_channel/{http_proxy.h → http_proxy_mapper.h} +3 -3
- data/src/core/ext/filters/client_channel/lb_policy/endpoint_list.cc +188 -0
- data/src/core/ext/filters/client_channel/lb_policy/endpoint_list.h +214 -0
- data/src/core/ext/filters/client_channel/lb_policy/grpclb/grpclb.cc +17 -4
- data/src/core/ext/filters/client_channel/lb_policy/health_check_client.cc +41 -6
- data/src/core/ext/filters/client_channel/lb_policy/health_check_client_internal.h +5 -3
- data/src/core/ext/filters/client_channel/lb_policy/outlier_detection/outlier_detection.cc +32 -103
- data/src/core/ext/filters/client_channel/lb_policy/outlier_detection/outlier_detection.h +0 -7
- data/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc +416 -139
- data/src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.h +16 -0
- data/src/core/ext/filters/client_channel/lb_policy/ring_hash/ring_hash.cc +434 -459
- data/src/core/ext/filters/client_channel/lb_policy/round_robin/round_robin.cc +410 -26
- data/src/core/ext/filters/client_channel/lb_policy/subchannel_list.h +14 -46
- data/src/core/ext/filters/client_channel/lb_policy/weighted_round_robin/weighted_round_robin.cc +851 -57
- data/src/core/ext/filters/client_channel/lb_policy/xds/cds.cc +16 -10
- data/src/core/ext/filters/client_channel/lb_policy/xds/xds_cluster_resolver.cc +47 -32
- data/src/core/ext/filters/client_channel/lb_policy/xds/xds_override_host.cc +55 -3
- data/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc +105 -175
- data/src/core/ext/filters/client_channel/resolver/dns/c_ares/grpc_ares_wrapper.cc +14 -7
- data/src/core/ext/filters/client_channel/resolver/fake/fake_resolver.cc +24 -6
- data/src/core/ext/filters/client_channel/resolver/fake/fake_resolver.h +36 -2
- data/src/core/ext/filters/client_channel/resolver/xds/xds_resolver.cc +54 -44
- data/src/core/ext/filters/client_channel/subchannel.cc +33 -0
- data/src/core/ext/filters/client_channel/subchannel.h +9 -0
- data/src/core/ext/transport/chttp2/server/chttp2_server.cc +1 -1
- data/src/core/ext/transport/chttp2/transport/chttp2_transport.cc +11 -6
- data/src/core/ext/transport/chttp2/transport/flow_control.cc +28 -22
- data/src/core/ext/transport/chttp2/transport/flow_control.h +27 -4
- data/src/core/ext/transport/chttp2/transport/frame_data.h +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_goaway.h +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_ping.cc +9 -0
- data/src/core/ext/transport/chttp2/transport/frame_ping.h +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_rst_stream.cc +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_rst_stream.h +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_settings.cc +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_settings.h +1 -1
- data/src/core/ext/transport/chttp2/transport/frame_window_update.h +1 -1
- data/src/core/ext/transport/chttp2/transport/hpack_encoder.cc +1 -1
- data/src/core/ext/transport/chttp2/transport/hpack_parser.cc +34 -36
- data/src/core/ext/transport/chttp2/transport/hpack_parser.h +3 -3
- data/src/core/ext/transport/chttp2/transport/internal.h +66 -47
- data/src/core/ext/transport/chttp2/transport/{frame.h → legacy_frame.h} +3 -3
- data/src/core/ext/transport/chttp2/transport/parsing.cc +4 -2
- data/src/core/ext/transport/chttp2/transport/ping_abuse_policy.cc +10 -0
- data/src/core/ext/transport/chttp2/transport/ping_abuse_policy.h +4 -0
- data/src/core/ext/transport/chttp2/transport/stream_lists.cc +1 -1
- data/src/core/ext/transport/chttp2/transport/writing.cc +2 -1
- data/src/core/ext/transport/inproc/inproc_transport.cc +9 -0
- data/src/core/ext/upb-generated/envoy/admin/v3/certs.upb.c +16 -18
- data/src/core/ext/upb-generated/envoy/admin/v3/certs.upb.h +75 -83
- data/src/core/ext/upb-generated/envoy/admin/v3/clusters.upb.c +27 -29
- data/src/core/ext/upb-generated/envoy/admin/v3/clusters.upb.h +102 -110
- data/src/core/ext/upb-generated/envoy/admin/v3/config_dump.upb.c +16 -18
- data/src/core/ext/upb-generated/envoy/admin/v3/config_dump.upb.h +73 -81
- data/src/core/ext/upb-generated/envoy/admin/v3/config_dump_shared.upb.c +65 -67
- data/src/core/ext/upb-generated/envoy/admin/v3/config_dump_shared.upb.h +294 -302
- data/src/core/ext/upb-generated/envoy/admin/v3/init_dump.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/admin/v3/init_dump.upb.h +20 -28
- data/src/core/ext/upb-generated/envoy/admin/v3/listeners.upb.c +5 -7
- data/src/core/ext/upb-generated/envoy/admin/v3/listeners.upb.h +24 -32
- data/src/core/ext/upb-generated/envoy/admin/v3/memory.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/admin/v3/memory.upb.h +19 -27
- data/src/core/ext/upb-generated/envoy/admin/v3/metrics.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/admin/v3/metrics.upb.h +10 -18
- data/src/core/ext/upb-generated/envoy/admin/v3/mutex_stats.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/admin/v3/mutex_stats.upb.h +10 -18
- data/src/core/ext/upb-generated/envoy/admin/v3/server_info.upb.c +42 -44
- data/src/core/ext/upb-generated/envoy/admin/v3/server_info.upb.h +141 -149
- data/src/core/ext/upb-generated/envoy/admin/v3/tap.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/admin/v3/tap.upb.h +8 -16
- data/src/core/ext/upb-generated/envoy/annotations/deprecation.upb.c +5 -7
- data/src/core/ext/upb-generated/envoy/annotations/deprecation.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/annotations/resource.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/annotations/resource.upb.h +4 -12
- data/src/core/ext/upb-generated/envoy/config/accesslog/v3/accesslog.upb.c +36 -38
- data/src/core/ext/upb-generated/envoy/config/accesslog/v3/accesslog.upb.h +157 -165
- data/src/core/ext/upb-generated/envoy/config/bootstrap/v3/bootstrap.upb.c +87 -89
- data/src/core/ext/upb-generated/envoy/config/bootstrap/v3/bootstrap.upb.h +372 -380
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/circuit_breaker.upb.c +13 -15
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/circuit_breaker.upb.h +55 -63
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/cluster.upb.c +111 -113
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/cluster.upb.h +441 -449
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/filter.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/filter.upb.h +8 -16
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/outlier_detection.upb.c +23 -25
- data/src/core/ext/upb-generated/envoy/config/cluster/v3/outlier_detection.upb.h +88 -96
- data/src/core/ext/upb-generated/envoy/config/common/matcher/v3/matcher.upb.c +40 -42
- data/src/core/ext/upb-generated/envoy/config/common/matcher/v3/matcher.upb.h +180 -188
- data/src/core/ext/upb-generated/envoy/config/core/v3/address.upb.c +26 -28
- data/src/core/ext/upb-generated/envoy/config/core/v3/address.upb.h +108 -116
- data/src/core/ext/upb-generated/envoy/config/core/v3/backoff.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/config/core/v3/backoff.upb.h +9 -17
- data/src/core/ext/upb-generated/envoy/config/core/v3/base.upb.c +65 -67
- data/src/core/ext/upb-generated/envoy/config/core/v3/base.upb.h +245 -253
- data/src/core/ext/upb-generated/envoy/config/core/v3/config_source.upb.c +27 -29
- data/src/core/ext/upb-generated/envoy/config/core/v3/config_source.upb.h +119 -127
- data/src/core/ext/upb-generated/envoy/config/core/v3/event_service_config.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/config/core/v3/event_service_config.upb.h +6 -14
- data/src/core/ext/upb-generated/envoy/config/core/v3/extension.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/config/core/v3/extension.upb.h +8 -16
- data/src/core/ext/upb-generated/envoy/config/core/v3/grpc_method_list.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/config/core/v3/grpc_method_list.upb.h +20 -28
- data/src/core/ext/upb-generated/envoy/config/core/v3/grpc_service.upb.c +49 -51
- data/src/core/ext/upb-generated/envoy/config/core/v3/grpc_service.upb.h +184 -192
- data/src/core/ext/upb-generated/envoy/config/core/v3/health_check.upb.c +49 -51
- data/src/core/ext/upb-generated/envoy/config/core/v3/health_check.upb.h +225 -233
- data/src/core/ext/upb-generated/envoy/config/core/v3/http_uri.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/config/core/v3/http_uri.upb.h +13 -21
- data/src/core/ext/upb-generated/envoy/config/core/v3/protocol.upb.c +63 -65
- data/src/core/ext/upb-generated/envoy/config/core/v3/protocol.upb.h +246 -254
- data/src/core/ext/upb-generated/envoy/config/core/v3/proxy_protocol.upb.c +5 -7
- data/src/core/ext/upb-generated/envoy/config/core/v3/proxy_protocol.upb.h +19 -27
- data/src/core/ext/upb-generated/envoy/config/core/v3/resolver.upb.c +5 -7
- data/src/core/ext/upb-generated/envoy/config/core/v3/resolver.upb.h +19 -27
- data/src/core/ext/upb-generated/envoy/config/core/v3/socket_option.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/config/core/v3/socket_option.upb.h +30 -38
- data/src/core/ext/upb-generated/envoy/config/core/v3/substitution_format_string.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/config/core/v3/substitution_format_string.upb.h +28 -36
- data/src/core/ext/upb-generated/envoy/config/core/v3/udp_socket_config.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/config/core/v3/udp_socket_config.upb.h +9 -17
- data/src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint.upb.c +12 -14
- data/src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint.upb.h +48 -56
- data/src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint_components.upb.c +23 -25
- data/src/core/ext/upb-generated/envoy/config/endpoint/v3/endpoint_components.upb.h +92 -100
- data/src/core/ext/upb-generated/envoy/config/endpoint/v3/load_report.upb.c +27 -29
- data/src/core/ext/upb-generated/envoy/config/endpoint/v3/load_report.upb.h +108 -116
- data/src/core/ext/upb-generated/envoy/config/listener/v3/api_listener.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/config/listener/v3/api_listener.upb.h +5 -13
- data/src/core/ext/upb-generated/envoy/config/listener/v3/listener.upb.c +38 -40
- data/src/core/ext/upb-generated/envoy/config/listener/v3/listener.upb.h +167 -175
- data/src/core/ext/upb-generated/envoy/config/listener/v3/listener_components.upb.c +34 -36
- data/src/core/ext/upb-generated/envoy/config/listener/v3/listener_components.upb.h +162 -170
- data/src/core/ext/upb-generated/envoy/config/listener/v3/quic_config.upb.c +10 -12
- data/src/core/ext/upb-generated/envoy/config/listener/v3/quic_config.upb.h +37 -45
- data/src/core/ext/upb-generated/envoy/config/listener/v3/udp_listener_config.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/config/listener/v3/udp_listener_config.upb.h +13 -21
- data/src/core/ext/upb-generated/envoy/config/metrics/v3/metrics_service.upb.c +6 -8
- data/src/core/ext/upb-generated/envoy/config/metrics/v3/metrics_service.upb.h +18 -26
- data/src/core/ext/upb-generated/envoy/config/metrics/v3/stats.upb.c +22 -24
- data/src/core/ext/upb-generated/envoy/config/metrics/v3/stats.upb.h +97 -105
- data/src/core/ext/upb-generated/envoy/config/overload/v3/overload.upb.c +24 -26
- data/src/core/ext/upb-generated/envoy/config/overload/v3/overload.upb.h +111 -119
- data/src/core/ext/upb-generated/envoy/config/rbac/v3/rbac.upb.c +43 -45
- data/src/core/ext/upb-generated/envoy/config/rbac/v3/rbac.upb.h +183 -191
- data/src/core/ext/upb-generated/envoy/config/route/v3/route.upb.c +20 -22
- data/src/core/ext/upb-generated/envoy/config/route/v3/route.upb.h +102 -110
- data/src/core/ext/upb-generated/envoy/config/route/v3/route_components.upb.c +253 -255
- data/src/core/ext/upb-generated/envoy/config/route/v3/route_components.upb.h +1108 -1116
- data/src/core/ext/upb-generated/envoy/config/route/v3/scoped_route.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/config/route/v3/scoped_route.upb.h +31 -39
- data/src/core/ext/upb-generated/envoy/config/tap/v3/common.upb.c +35 -37
- data/src/core/ext/upb-generated/envoy/config/tap/v3/common.upb.h +150 -158
- data/src/core/ext/upb-generated/envoy/config/trace/v3/datadog.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/config/trace/v3/datadog.upb.h +10 -18
- data/src/core/ext/upb-generated/envoy/config/trace/v3/dynamic_ot.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/config/trace/v3/dynamic_ot.upb.h +8 -16
- data/src/core/ext/upb-generated/envoy/config/trace/v3/http_tracer.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/config/trace/v3/http_tracer.upb.h +13 -21
- data/src/core/ext/upb-generated/envoy/config/trace/v3/lightstep.upb.c +5 -7
- data/src/core/ext/upb-generated/envoy/config/trace/v3/lightstep.upb.h +19 -27
- data/src/core/ext/upb-generated/envoy/config/trace/v3/opencensus.upb.c +14 -16
- data/src/core/ext/upb-generated/envoy/config/trace/v3/opencensus.upb.h +53 -61
- data/src/core/ext/upb-generated/envoy/config/trace/v3/opentelemetry.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/config/trace/v3/opentelemetry.upb.h +8 -16
- data/src/core/ext/upb-generated/envoy/config/trace/v3/service.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/config/trace/v3/service.upb.h +5 -13
- data/src/core/ext/upb-generated/envoy/config/trace/v3/skywalking.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/config/trace/v3/skywalking.upb.h +24 -32
- data/src/core/ext/upb-generated/envoy/config/trace/v3/trace.upb.c +1 -3
- data/src/core/ext/upb-generated/envoy/config/trace/v3/trace.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/config/trace/v3/xray.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/config/trace/v3/xray.upb.h +23 -31
- data/src/core/ext/upb-generated/envoy/config/trace/v3/zipkin.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/config/trace/v3/zipkin.upb.h +23 -31
- data/src/core/ext/upb-generated/envoy/data/accesslog/v3/accesslog.upb.c +114 -116
- data/src/core/ext/upb-generated/envoy/data/accesslog/v3/accesslog.upb.h +372 -380
- data/src/core/ext/upb-generated/envoy/extensions/clusters/aggregate/v3/cluster.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/extensions/clusters/aggregate/v3/cluster.upb.h +9 -17
- data/src/core/ext/upb-generated/envoy/extensions/filters/common/fault/v3/fault.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/extensions/filters/common/fault/v3/fault.upb.h +30 -38
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/fault/v3/fault.upb.c +21 -23
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/fault/v3/fault.upb.h +81 -89
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/rbac/v3/rbac.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/rbac/v3/rbac.upb.h +24 -32
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/router/v3/router.upb.c +12 -14
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/router/v3/router.upb.h +52 -60
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/stateful_session/v3/stateful_session.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/extensions/filters/http/stateful_session/v3/stateful_session.upb.h +14 -22
- data/src/core/ext/upb-generated/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upb.c +114 -116
- data/src/core/ext/upb-generated/envoy/extensions/filters/network/http_connection_manager/v3/http_connection_manager.upb.h +468 -476
- data/src/core/ext/upb-generated/envoy/extensions/http/stateful_session/cookie/v3/cookie.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/extensions/http/stateful_session/cookie/v3/cookie.upb.h +5 -13
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/client_side_weighted_round_robin/v3/client_side_weighted_round_robin.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/client_side_weighted_round_robin/v3/client_side_weighted_round_robin.upb.h +25 -33
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/common/v3/common.upb.c +11 -13
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/common/v3/common.upb.h +40 -48
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/pick_first/v3/pick_first.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/pick_first/v3/pick_first.upb.h +4 -12
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/ring_hash/v3/ring_hash.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/ring_hash/v3/ring_hash.upb.h +27 -35
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/extensions/load_balancing_policies/wrr_locality/v3/wrr_locality.upb.h +5 -13
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/cert.upb.c +1 -3
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/cert.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/common.upb.c +35 -37
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/common.upb.h +165 -173
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/secret.upb.c +9 -11
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/secret.upb.h +32 -40
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/tls.upb.c +39 -41
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/tls.upb.h +169 -177
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/tls_spiffe_validator_config.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/extensions/transport_sockets/tls/v3/tls_spiffe_validator_config.upb.h +16 -24
- data/src/core/ext/upb-generated/envoy/service/discovery/v3/ads.upb.c +1 -3
- data/src/core/ext/upb-generated/envoy/service/discovery/v3/ads.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/service/discovery/v3/discovery.upb.c +55 -57
- data/src/core/ext/upb-generated/envoy/service/discovery/v3/discovery.upb.h +241 -249
- data/src/core/ext/upb-generated/envoy/service/load_stats/v3/lrs.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/service/load_stats/v3/lrs.upb.h +31 -39
- data/src/core/ext/upb-generated/envoy/service/status/v3/csds.upb.c +23 -25
- data/src/core/ext/upb-generated/envoy/service/status/v3/csds.upb.h +98 -106
- data/src/core/ext/upb-generated/envoy/type/http/v3/cookie.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/http/v3/cookie.upb.h +11 -19
- data/src/core/ext/upb-generated/envoy/type/http/v3/path_transformation.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/http/v3/path_transformation.upb.h +18 -26
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/filter_state.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/filter_state.upb.h +9 -17
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/http_inputs.upb.c +6 -8
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/http_inputs.upb.h +16 -24
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/metadata.upb.c +6 -8
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/metadata.upb.h +24 -32
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/node.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/node.upb.h +13 -21
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/number.upb.c +3 -5
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/number.upb.h +10 -18
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/path.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/path.upb.h +6 -14
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/regex.upb.c +6 -8
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/regex.upb.h +20 -28
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/status_code_input.upb.c +1 -3
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/status_code_input.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/string.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/string.upb.h +33 -41
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/struct.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/struct.upb.h +18 -26
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/value.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/type/matcher/v3/value.upb.h +31 -39
- data/src/core/ext/upb-generated/envoy/type/metadata/v3/metadata.upb.c +8 -10
- data/src/core/ext/upb-generated/envoy/type/metadata/v3/metadata.upb.h +34 -42
- data/src/core/ext/upb-generated/envoy/type/tracing/v3/custom_tag.upb.c +14 -16
- data/src/core/ext/upb-generated/envoy/type/tracing/v3/custom_tag.upb.h +47 -55
- data/src/core/ext/upb-generated/envoy/type/v3/hash_policy.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/v3/hash_policy.upb.h +13 -21
- data/src/core/ext/upb-generated/envoy/type/v3/http.upb.c +1 -3
- data/src/core/ext/upb-generated/envoy/type/v3/http.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/type/v3/http_status.upb.c +2 -4
- data/src/core/ext/upb-generated/envoy/type/v3/http_status.upb.h +4 -12
- data/src/core/ext/upb-generated/envoy/type/v3/percent.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/v3/percent.upb.h +10 -18
- data/src/core/ext/upb-generated/envoy/type/v3/range.upb.c +7 -9
- data/src/core/ext/upb-generated/envoy/type/v3/range.upb.h +19 -27
- data/src/core/ext/upb-generated/envoy/type/v3/ratelimit_strategy.upb.c +6 -8
- data/src/core/ext/upb-generated/envoy/type/v3/ratelimit_strategy.upb.h +20 -28
- data/src/core/ext/upb-generated/envoy/type/v3/ratelimit_unit.upb.c +1 -3
- data/src/core/ext/upb-generated/envoy/type/v3/ratelimit_unit.upb.h +1 -9
- data/src/core/ext/upb-generated/envoy/type/v3/semantic_version.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/v3/semantic_version.upb.h +10 -18
- data/src/core/ext/upb-generated/envoy/type/v3/token_bucket.upb.c +4 -6
- data/src/core/ext/upb-generated/envoy/type/v3/token_bucket.upb.h +12 -20
- data/src/core/ext/upb-generated/google/api/annotations.upb.c +2 -4
- data/src/core/ext/upb-generated/google/api/annotations.upb.h +1 -9
- data/src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.c +45 -47
- data/src/core/ext/upb-generated/google/api/expr/v1alpha1/checked.upb.h +190 -198
- data/src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.c +54 -56
- data/src/core/ext/upb-generated/google/api/expr/v1alpha1/syntax.upb.h +210 -218
- data/src/core/ext/upb-generated/google/api/http.upb.c +15 -17
- data/src/core/ext/upb-generated/google/api/http.upb.h +60 -68
- data/src/core/ext/upb-generated/google/api/httpbody.upb.c +4 -6
- data/src/core/ext/upb-generated/google/api/httpbody.upb.h +15 -23
- data/src/core/ext/upb-generated/google/protobuf/any.upb.c +3 -5
- data/src/core/ext/upb-generated/google/protobuf/any.upb.h +7 -15
- data/src/core/ext/upb-generated/google/protobuf/descriptor.upb.c +359 -204
- data/src/core/ext/upb-generated/google/protobuf/descriptor.upb.h +1340 -760
- data/src/core/ext/upb-generated/google/protobuf/duration.upb.c +3 -5
- data/src/core/ext/upb-generated/google/protobuf/duration.upb.h +7 -15
- data/src/core/ext/upb-generated/google/protobuf/empty.upb.c +1 -3
- data/src/core/ext/upb-generated/google/protobuf/empty.upb.h +1 -9
- data/src/core/ext/upb-generated/google/protobuf/struct.upb.c +11 -13
- data/src/core/ext/upb-generated/google/protobuf/struct.upb.h +43 -51
- data/src/core/ext/upb-generated/google/protobuf/timestamp.upb.c +3 -5
- data/src/core/ext/upb-generated/google/protobuf/timestamp.upb.h +7 -15
- data/src/core/ext/upb-generated/google/protobuf/wrappers.upb.c +10 -12
- data/src/core/ext/upb-generated/google/protobuf/wrappers.upb.h +28 -36
- data/src/core/ext/upb-generated/google/rpc/status.upb.c +4 -6
- data/src/core/ext/upb-generated/google/rpc/status.upb.h +15 -23
- data/src/core/ext/upb-generated/opencensus/proto/trace/v1/trace_config.upb.c +11 -13
- data/src/core/ext/upb-generated/opencensus/proto/trace/v1/trace_config.upb.h +35 -43
- data/src/core/ext/upb-generated/src/proto/grpc/gcp/altscontext.upb.c +10 -12
- data/src/core/ext/upb-generated/src/proto/grpc/gcp/altscontext.upb.h +28 -36
- data/src/core/ext/upb-generated/src/proto/grpc/gcp/handshaker.upb.c +48 -50
- data/src/core/ext/upb-generated/src/proto/grpc/gcp/handshaker.upb.h +190 -198
- data/src/core/ext/upb-generated/src/proto/grpc/gcp/transport_security_common.upb.c +5 -7
- data/src/core/ext/upb-generated/src/proto/grpc/gcp/transport_security_common.upb.h +15 -23
- data/src/core/ext/upb-generated/src/proto/grpc/health/v1/health.upb.c +3 -5
- data/src/core/ext/upb-generated/src/proto/grpc/health/v1/health.upb.h +7 -15
- data/src/core/ext/upb-generated/src/proto/grpc/lb/v1/load_balancer.upb.c +21 -23
- data/src/core/ext/upb-generated/src/proto/grpc/lb/v1/load_balancer.upb.h +80 -88
- data/src/core/ext/upb-generated/src/proto/grpc/lookup/v1/rls.upb.c +9 -11
- data/src/core/ext/upb-generated/src/proto/grpc/lookup/v1/rls.upb.h +29 -37
- data/src/core/ext/upb-generated/src/proto/grpc/lookup/v1/rls_config.upb.c +32 -34
- data/src/core/ext/upb-generated/src/proto/grpc/lookup/v1/rls_config.upb.h +147 -155
- data/src/core/ext/upb-generated/udpa/annotations/migrate.upb.c +10 -12
- data/src/core/ext/upb-generated/udpa/annotations/migrate.upb.h +13 -21
- data/src/core/ext/upb-generated/udpa/annotations/security.upb.c +4 -6
- data/src/core/ext/upb-generated/udpa/annotations/security.upb.h +7 -15
- data/src/core/ext/upb-generated/udpa/annotations/sensitive.upb.c +2 -4
- data/src/core/ext/upb-generated/udpa/annotations/sensitive.upb.h +1 -9
- data/src/core/ext/upb-generated/udpa/annotations/status.upb.c +4 -6
- data/src/core/ext/upb-generated/udpa/annotations/status.upb.h +7 -15
- data/src/core/ext/upb-generated/udpa/annotations/versioning.upb.c +3 -5
- data/src/core/ext/upb-generated/udpa/annotations/versioning.upb.h +4 -12
- data/src/core/ext/upb-generated/validate/validate.upb.c +201 -203
- data/src/core/ext/upb-generated/validate/validate.upb.h +924 -932
- data/src/core/ext/upb-generated/xds/annotations/v3/migrate.upb.c +10 -12
- data/src/core/ext/upb-generated/xds/annotations/v3/migrate.upb.h +13 -21
- data/src/core/ext/upb-generated/xds/annotations/v3/security.upb.c +4 -6
- data/src/core/ext/upb-generated/xds/annotations/v3/security.upb.h +7 -15
- data/src/core/ext/upb-generated/xds/annotations/v3/sensitive.upb.c +2 -4
- data/src/core/ext/upb-generated/xds/annotations/v3/sensitive.upb.h +1 -9
- data/src/core/ext/upb-generated/xds/annotations/v3/status.upb.c +9 -11
- data/src/core/ext/upb-generated/xds/annotations/v3/status.upb.h +16 -24
- data/src/core/ext/upb-generated/xds/annotations/v3/versioning.upb.c +3 -5
- data/src/core/ext/upb-generated/xds/annotations/v3/versioning.upb.h +4 -12
- data/src/core/ext/upb-generated/xds/core/v3/authority.upb.c +2 -4
- data/src/core/ext/upb-generated/xds/core/v3/authority.upb.h +4 -12
- data/src/core/ext/upb-generated/xds/core/v3/cidr.upb.c +3 -5
- data/src/core/ext/upb-generated/xds/core/v3/cidr.upb.h +8 -16
- data/src/core/ext/upb-generated/xds/core/v3/collection_entry.upb.c +6 -8
- data/src/core/ext/upb-generated/xds/core/v3/collection_entry.upb.h +20 -28
- data/src/core/ext/upb-generated/xds/core/v3/context_params.upb.c +4 -6
- data/src/core/ext/upb-generated/xds/core/v3/context_params.upb.h +9 -17
- data/src/core/ext/upb-generated/xds/core/v3/extension.upb.c +3 -5
- data/src/core/ext/upb-generated/xds/core/v3/extension.upb.h +8 -16
- data/src/core/ext/upb-generated/xds/core/v3/resource.upb.c +4 -6
- data/src/core/ext/upb-generated/xds/core/v3/resource.upb.h +12 -20
- data/src/core/ext/upb-generated/xds/core/v3/resource_locator.upb.c +9 -11
- data/src/core/ext/upb-generated/xds/core/v3/resource_locator.upb.h +35 -43
- data/src/core/ext/upb-generated/xds/core/v3/resource_name.upb.c +5 -7
- data/src/core/ext/upb-generated/xds/core/v3/resource_name.upb.h +14 -22
- data/src/core/ext/upb-generated/xds/data/orca/v3/orca_load_report.upb.c +16 -18
- data/src/core/ext/upb-generated/xds/data/orca/v3/orca_load_report.upb.h +43 -51
- data/src/core/ext/upb-generated/xds/service/orca/v3/orca.upb.c +3 -5
- data/src/core/ext/upb-generated/xds/service/orca/v3/orca.upb.h +13 -21
- data/src/core/ext/upb-generated/xds/type/matcher/v3/cel.upb.c +2 -4
- data/src/core/ext/upb-generated/xds/type/matcher/v3/cel.upb.h +5 -13
- data/src/core/ext/upb-generated/xds/type/matcher/v3/domain.upb.c +4 -6
- data/src/core/ext/upb-generated/xds/type/matcher/v3/domain.upb.h +21 -29
- data/src/core/ext/upb-generated/xds/type/matcher/v3/http_inputs.upb.c +1 -3
- data/src/core/ext/upb-generated/xds/type/matcher/v3/http_inputs.upb.h +1 -9
- data/src/core/ext/upb-generated/xds/type/matcher/v3/ip.upb.c +5 -7
- data/src/core/ext/upb-generated/xds/type/matcher/v3/ip.upb.h +24 -32
- data/src/core/ext/upb-generated/xds/type/matcher/v3/matcher.upb.c +24 -26
- data/src/core/ext/upb-generated/xds/type/matcher/v3/matcher.upb.h +103 -111
- data/src/core/ext/upb-generated/xds/type/matcher/v3/range.upb.c +10 -12
- data/src/core/ext/upb-generated/xds/type/matcher/v3/range.upb.h +61 -69
- data/src/core/ext/upb-generated/xds/type/matcher/v3/regex.upb.c +3 -5
- data/src/core/ext/upb-generated/xds/type/matcher/v3/regex.upb.h +9 -17
- data/src/core/ext/upb-generated/xds/type/matcher/v3/string.upb.c +8 -10
- data/src/core/ext/upb-generated/xds/type/matcher/v3/string.upb.h +33 -41
- data/src/core/ext/upb-generated/xds/type/v3/cel.upb.c +5 -7
- data/src/core/ext/upb-generated/xds/type/v3/cel.upb.h +18 -26
- data/src/core/ext/upb-generated/xds/type/v3/range.upb.c +7 -9
- data/src/core/ext/upb-generated/xds/type/v3/range.upb.h +19 -27
- data/src/core/ext/upb-generated/xds/type/v3/typed_struct.upb.c +3 -5
- data/src/core/ext/upb-generated/xds/type/v3/typed_struct.upb.h +8 -16
- data/src/core/ext/upbdefs-generated/google/protobuf/descriptor.upbdefs.c +367 -290
- data/src/core/ext/upbdefs-generated/google/protobuf/descriptor.upbdefs.h +10 -0
- data/src/core/ext/xds/xds_client.cc +6 -9
- data/src/core/ext/xds/xds_client.h +2 -2
- data/src/core/ext/xds/xds_cluster.cc +30 -42
- data/src/core/ext/xds/xds_cluster.h +0 -4
- data/src/core/ext/xds/xds_endpoint.cc +12 -19
- data/src/core/ext/xds/xds_endpoint.h +0 -1
- data/src/core/ext/xds/xds_http_filters.cc +1 -4
- data/src/core/ext/xds/xds_listener.cc +14 -14
- data/src/core/ext/xds/xds_listener.h +13 -3
- data/src/core/ext/xds/xds_resource_type.h +1 -7
- data/src/core/ext/xds/xds_resource_type_impl.h +9 -11
- data/src/core/ext/xds/xds_route_config.cc +10 -11
- data/src/core/ext/xds/xds_route_config.h +1 -1
- data/src/core/ext/xds/xds_server_config_fetcher.cc +53 -28
- data/src/core/ext/xds/xds_transport_grpc.cc +11 -1
- data/src/core/lib/backoff/random_early_detection.cc +4 -2
- data/src/core/lib/backoff/random_early_detection.h +2 -4
- data/src/core/lib/channel/call_tracer.cc +7 -1
- data/src/core/lib/channel/call_tracer.h +4 -1
- data/src/core/lib/channel/channelz_registry.h +4 -2
- data/src/core/lib/channel/connected_channel.cc +1 -1
- data/src/core/lib/config/config_vars.h +1 -1
- data/src/core/lib/config/core_configuration.cc +2 -1
- data/src/core/lib/config/core_configuration.h +5 -4
- data/src/core/lib/debug/stats_data.cc +146 -51
- data/src/core/lib/debug/stats_data.h +81 -20
- data/src/core/lib/event_engine/cf_engine/cf_engine.cc +3 -0
- data/src/core/lib/event_engine/cf_engine/cf_engine.h +3 -0
- data/src/core/lib/event_engine/cf_engine/cfstream_endpoint.cc +3 -0
- data/src/core/lib/event_engine/cf_engine/cfstream_endpoint.h +3 -0
- data/src/core/lib/event_engine/cf_engine/cftype_unique_ref.h +3 -0
- data/src/core/lib/event_engine/cf_engine/dns_service_resolver.cc +15 -3
- data/src/core/lib/event_engine/cf_engine/dns_service_resolver.h +3 -0
- data/src/core/lib/event_engine/posix_engine/tcp_socket_utils.cc +1 -1
- data/src/core/lib/event_engine/thread_pool/thread_count.h +15 -0
- data/src/core/lib/event_engine/thread_pool/thread_pool_factory.cc +3 -15
- data/src/core/lib/event_engine/thread_pool/work_stealing_thread_pool.cc +10 -4
- data/src/core/lib/experiments/config.cc +9 -1
- data/src/core/lib/experiments/experiments.cc +144 -60
- data/src/core/lib/experiments/experiments.h +146 -41
- data/src/core/lib/gprpp/fork.h +1 -1
- data/src/core/lib/gprpp/manual_constructor.h +1 -2
- data/src/core/lib/gprpp/no_destruct.h +1 -1
- data/src/core/lib/gprpp/per_cpu.cc +2 -0
- data/src/core/lib/gprpp/per_cpu.h +36 -7
- data/src/core/lib/gprpp/ref_counted_ptr.h +63 -0
- data/src/core/lib/gprpp/work_serializer.cc +297 -25
- data/src/core/lib/gprpp/work_serializer.h +25 -9
- data/src/core/lib/iomgr/combiner.cc +54 -15
- data/src/core/lib/iomgr/combiner.h +8 -3
- data/src/core/lib/iomgr/event_engine_shims/endpoint.cc +2 -4
- data/src/core/lib/iomgr/exec_ctx.cc +12 -0
- data/src/core/lib/iomgr/exec_ctx.h +55 -19
- data/src/core/lib/iomgr/polling_entity.cc +10 -0
- data/src/core/lib/iomgr/polling_entity.h +2 -0
- data/src/core/lib/iomgr/port.h +14 -0
- data/src/core/lib/iomgr/tcp_posix.cc +17 -14
- data/src/core/lib/load_balancing/lb_policy.h +10 -9
- data/src/core/lib/promise/arena_promise.h +5 -1
- data/src/core/lib/promise/detail/seq_state.h +418 -0
- data/src/core/lib/promise/latch.h +1 -0
- data/src/core/lib/promise/loop.h +8 -5
- data/src/core/lib/promise/pipe.h +24 -24
- data/src/core/lib/promise/poll.h +4 -6
- data/src/core/lib/resolver/server_address.h +1 -0
- data/src/core/lib/resource_quota/memory_quota.cc +58 -2
- data/src/core/lib/resource_quota/memory_quota.h +4 -1
- data/src/core/lib/security/credentials/ssl/ssl_credentials.cc +115 -9
- data/src/core/lib/security/credentials/ssl/ssl_credentials.h +14 -0
- data/src/core/lib/security/credentials/tls/grpc_tls_certificate_match.cc +86 -0
- data/src/core/lib/security/credentials/tls/grpc_tls_certificate_provider.cc +0 -59
- data/src/core/lib/security/credentials/tls/grpc_tls_certificate_verifier.h +2 -0
- data/src/core/lib/security/security_connector/ssl/ssl_security_connector.cc +7 -57
- data/src/core/lib/security/security_connector/ssl/ssl_security_connector.h +1 -1
- data/src/core/lib/security/security_connector/tls/tls_security_connector.cc +2 -14
- data/src/core/lib/slice/slice.h +6 -0
- data/src/core/lib/slice/slice_buffer.cc +15 -0
- data/src/core/lib/slice/slice_buffer.h +16 -4
- data/src/core/lib/slice/slice_refcount.h +1 -1
- data/src/core/lib/surface/call.cc +92 -34
- data/src/core/lib/surface/call.h +4 -0
- data/src/core/lib/surface/channel.cc +7 -4
- data/src/core/lib/surface/channel_init.h +3 -2
- data/src/core/lib/surface/server.cc +45 -5
- data/src/core/lib/surface/server.h +18 -6
- data/src/core/lib/surface/version.cc +2 -2
- data/src/core/lib/transport/batch_builder.cc +3 -5
- data/src/core/lib/transport/metadata_batch.cc +6 -0
- data/src/core/lib/transport/metadata_batch.h +20 -1
- data/src/core/lib/transport/parsed_metadata.h +2 -4
- data/src/core/lib/transport/simple_slice_based_metadata.h +1 -2
- data/src/core/lib/transport/transport.h +21 -11
- data/src/core/tsi/ssl_transport_security.cc +7 -0
- data/src/core/tsi/ssl_transport_security.h +4 -0
- data/src/ruby/ext/grpc/extconf.rb +1 -1
- data/src/ruby/ext/grpc/rb_channel_args.c +6 -4
- data/src/ruby/lib/grpc/version.rb +1 -1
- data/src/ruby/pb/src/proto/grpc/testing/messages_pb.rb +4 -1
- data/third_party/abseil-cpp/absl/random/bit_gen_ref.h +185 -0
- data/third_party/upb/upb/collections/array.c +6 -0
- data/third_party/upb/upb/collections/array.h +6 -0
- data/third_party/upb/upb/collections/map.c +7 -0
- data/third_party/upb/upb/collections/map.h +5 -0
- data/third_party/upb/upb/collections/map_sorter_internal.h +1 -1
- data/third_party/upb/upb/collections/message_value.h +8 -1
- data/third_party/upb/upb/generated_code_support.h +54 -0
- data/third_party/upb/upb/hash/common.c +5 -0
- data/third_party/upb/upb/hash/common.h +1 -0
- data/third_party/upb/upb/hash/str_table.h +1 -0
- data/third_party/upb/upb/message/accessors.c +25 -1
- data/third_party/upb/upb/message/accessors.h +46 -25
- data/third_party/upb/upb/message/accessors_internal.h +69 -3
- data/third_party/upb/upb/message/extension_internal.h +1 -1
- data/third_party/upb/upb/message/internal/map_entry.h +64 -0
- data/third_party/upb/upb/message/internal.h +2 -6
- data/third_party/upb/upb/message/message.c +0 -6
- data/third_party/upb/upb/message/message.h +1 -1
- data/third_party/upb/upb/message/tagged_ptr.h +89 -0
- data/third_party/upb/upb/mini_descriptor/build_enum.c +150 -0
- data/third_party/upb/upb/mini_descriptor/build_enum.h +63 -0
- data/third_party/upb/upb/{mini_table → mini_descriptor}/decode.c +122 -374
- data/third_party/upb/upb/{mini_table → mini_descriptor}/decode.h +11 -50
- data/third_party/upb/upb/mini_descriptor/internal/base92.c +46 -0
- data/third_party/upb/upb/mini_descriptor/internal/base92.h +81 -0
- data/third_party/upb/upb/mini_descriptor/internal/decoder.h +73 -0
- data/third_party/upb/upb/{mini_table → mini_descriptor/internal}/encode.c +58 -32
- data/third_party/upb/upb/{mini_table/encode_internal.h → mini_descriptor/internal/encode.h} +3 -4
- data/third_party/upb/upb/{mini_table/encode_internal.hpp → mini_descriptor/internal/encode.hpp} +1 -1
- data/third_party/upb/upb/mini_descriptor/internal/modifiers.h +50 -0
- data/third_party/upb/upb/{mini_table/common_internal.h → mini_descriptor/internal/wire_constants.h} +3 -23
- data/third_party/upb/upb/mini_descriptor/link.c +142 -0
- data/third_party/upb/upb/mini_descriptor/link.h +104 -0
- data/third_party/upb/upb/mini_table/{types.h → enum.h} +19 -9
- data/third_party/upb/upb/mini_table/extension.h +40 -0
- data/third_party/upb/upb/mini_table/extension_registry.c +1 -1
- data/third_party/upb/upb/mini_table/extension_registry.h +2 -1
- data/third_party/upb/upb/mini_table/field.h +118 -0
- data/third_party/upb/upb/{json_decode.h → mini_table/file.h} +5 -6
- data/third_party/upb/upb/mini_table/{enum_internal.h → internal/enum.h} +7 -19
- data/third_party/upb/upb/mini_table/{extension_internal.h → internal/extension.h} +8 -8
- data/third_party/upb/upb/mini_table/{field_internal.h → internal/field.h} +10 -66
- data/third_party/upb/upb/mini_table/{file_internal.h → internal/file.h} +6 -4
- data/third_party/upb/upb/mini_table/internal/message.c +39 -0
- data/third_party/upb/upb/mini_table/{message_internal.h → internal/message.h} +14 -37
- data/third_party/upb/upb/mini_table/{sub_internal.h → internal/sub.h} +7 -6
- data/third_party/upb/upb/mini_table/{common.c → message.c} +2 -33
- data/third_party/upb/upb/mini_table/{common.h → message.h} +12 -77
- data/third_party/upb/upb/{json_encode.h → mini_table/sub.h} +5 -6
- data/third_party/upb/upb/reflection/def.hpp +16 -4
- data/third_party/upb/upb/reflection/def_pool_internal.h +1 -1
- data/third_party/upb/upb/reflection/desc_state_internal.h +1 -1
- data/third_party/upb/upb/reflection/enum_def.c +1 -1
- data/third_party/upb/upb/reflection/field_def.c +2 -1
- data/third_party/upb/upb/reflection/message.c +2 -2
- data/third_party/upb/upb/reflection/message_def.c +3 -1
- data/third_party/upb/upb/wire/decode.c +68 -29
- data/third_party/upb/upb/wire/decode.h +40 -0
- data/third_party/upb/upb/wire/encode.c +23 -13
- metadata +43 -27
- data/src/core/lib/event_engine/thread_pool/original_thread_pool.cc +0 -256
- data/src/core/lib/event_engine/thread_pool/original_thread_pool.h +0 -137
@@ -74,6 +74,7 @@
|
|
74
74
|
#include "src/core/lib/channel/status_util.h"
|
75
75
|
#include "src/core/lib/config/core_configuration.h"
|
76
76
|
#include "src/core/lib/debug/trace.h"
|
77
|
+
#include "src/core/lib/experiments/experiments.h"
|
77
78
|
#include "src/core/lib/gprpp/debug_location.h"
|
78
79
|
#include "src/core/lib/gprpp/dual_ref_counted.h"
|
79
80
|
#include "src/core/lib/gprpp/match.h"
|
@@ -143,7 +144,8 @@ class XdsResolver : public Resolver {
|
|
143
144
|
public:
|
144
145
|
explicit ListenerWatcher(RefCountedPtr<XdsResolver> resolver)
|
145
146
|
: resolver_(std::move(resolver)) {}
|
146
|
-
void OnResourceChanged(
|
147
|
+
void OnResourceChanged(
|
148
|
+
std::shared_ptr<const XdsListenerResource> listener) override {
|
147
149
|
RefCountedPtr<ListenerWatcher> self = Ref();
|
148
150
|
resolver_->work_serializer_->Run(
|
149
151
|
[self = std::move(self), listener = std::move(listener)]() mutable {
|
@@ -180,7 +182,8 @@ class XdsResolver : public Resolver {
|
|
180
182
|
public:
|
181
183
|
explicit RouteConfigWatcher(RefCountedPtr<XdsResolver> resolver)
|
182
184
|
: resolver_(std::move(resolver)) {}
|
183
|
-
void OnResourceChanged(
|
185
|
+
void OnResourceChanged(
|
186
|
+
std::shared_ptr<const XdsRouteConfigResource> route_config) override {
|
184
187
|
RefCountedPtr<RouteConfigWatcher> self = Ref();
|
185
188
|
resolver_->work_serializer_->Run(
|
186
189
|
[self = std::move(self),
|
@@ -397,8 +400,9 @@ class XdsResolver : public Resolver {
|
|
397
400
|
return it->second->Ref();
|
398
401
|
}
|
399
402
|
|
400
|
-
void OnListenerUpdate(XdsListenerResource listener);
|
401
|
-
void OnRouteConfigUpdate(
|
403
|
+
void OnListenerUpdate(std::shared_ptr<const XdsListenerResource> listener);
|
404
|
+
void OnRouteConfigUpdate(
|
405
|
+
std::shared_ptr<const XdsRouteConfigResource> rds_update);
|
402
406
|
void OnError(absl::string_view context, absl::Status status);
|
403
407
|
void OnResourceDoesNotExist(std::string context);
|
404
408
|
|
@@ -418,17 +422,13 @@ class XdsResolver : public Resolver {
|
|
418
422
|
uint64_t channel_id_;
|
419
423
|
|
420
424
|
ListenerWatcher* listener_watcher_ = nullptr;
|
421
|
-
|
422
|
-
// LDS response; instead, the relevant VirtualHost from the
|
423
|
-
// RouteConfiguration will be saved in current_virtual_host_.
|
424
|
-
XdsListenerResource::HttpConnectionManager current_listener_;
|
425
|
+
std::shared_ptr<const XdsListenerResource> current_listener_;
|
425
426
|
|
426
427
|
std::string route_config_name_;
|
427
428
|
RouteConfigWatcher* route_config_watcher_ = nullptr;
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
cluster_specifier_plugin_map_;
|
429
|
+
std::shared_ptr<const XdsRouteConfigResource> current_route_config_;
|
430
|
+
|
431
|
+
const XdsRouteConfigResource::VirtualHost* current_virtual_host_ = nullptr;
|
432
432
|
|
433
433
|
std::map<absl::string_view, WeakRefCountedPtr<ClusterRef>> cluster_ref_map_;
|
434
434
|
};
|
@@ -546,11 +546,12 @@ XdsResolver::RouteConfigData::CreateMethodConfig(
|
|
546
546
|
route_action.max_stream_duration->ToJsonString()));
|
547
547
|
}
|
548
548
|
// Handle xDS HTTP filters.
|
549
|
+
const auto& hcm = absl::get<XdsListenerResource::HttpConnectionManager>(
|
550
|
+
resolver->current_listener_->listener);
|
549
551
|
auto result = XdsRouting::GeneratePerHTTPFilterConfigs(
|
550
552
|
static_cast<const GrpcXdsBootstrap&>(resolver->xds_client_->bootstrap())
|
551
553
|
.http_filter_registry(),
|
552
|
-
|
553
|
-
resolver->current_virtual_host_.value(), route, cluster_weight,
|
554
|
+
hcm.http_filters, *resolver->current_virtual_host_, route, cluster_weight,
|
554
555
|
resolver->args_);
|
555
556
|
if (!result.ok()) return result.status();
|
556
557
|
for (const auto& p : result->per_filter_configs) {
|
@@ -673,7 +674,9 @@ XdsResolver::XdsConfigSelector::XdsConfigSelector(
|
|
673
674
|
const auto& http_filter_registry =
|
674
675
|
static_cast<const GrpcXdsBootstrap&>(resolver_->xds_client_->bootstrap())
|
675
676
|
.http_filter_registry();
|
676
|
-
|
677
|
+
const auto& hcm = absl::get<XdsListenerResource::HttpConnectionManager>(
|
678
|
+
resolver_->current_listener_->listener);
|
679
|
+
for (const auto& http_filter : hcm.http_filters) {
|
677
680
|
// Find filter. This is guaranteed to succeed, because it's checked
|
678
681
|
// at config validation time in the XdsApi code.
|
679
682
|
const XdsHttpFilterImpl* filter_impl =
|
@@ -694,7 +697,15 @@ XdsResolver::XdsConfigSelector::~XdsConfigSelector() {
|
|
694
697
|
resolver_.get(), this);
|
695
698
|
}
|
696
699
|
route_config_data_.reset();
|
697
|
-
|
700
|
+
if (!IsWorkSerializerDispatchEnabled()) {
|
701
|
+
resolver_->MaybeRemoveUnusedClusters();
|
702
|
+
return;
|
703
|
+
}
|
704
|
+
resolver_->work_serializer_->Run(
|
705
|
+
[resolver = std::move(resolver_)]() {
|
706
|
+
resolver->MaybeRemoveUnusedClusters();
|
707
|
+
},
|
708
|
+
DEBUG_LOCATION);
|
698
709
|
}
|
699
710
|
|
700
711
|
absl::optional<uint64_t> HeaderHashHelper(
|
@@ -1006,26 +1017,27 @@ void XdsResolver::ShutdownLocked() {
|
|
1006
1017
|
}
|
1007
1018
|
}
|
1008
1019
|
|
1009
|
-
void XdsResolver::OnListenerUpdate(
|
1020
|
+
void XdsResolver::OnListenerUpdate(
|
1021
|
+
std::shared_ptr<const XdsListenerResource> listener) {
|
1010
1022
|
if (GRPC_TRACE_FLAG_ENABLED(grpc_xds_resolver_trace)) {
|
1011
1023
|
gpr_log(GPR_INFO, "[xds_resolver %p] received updated listener data", this);
|
1012
1024
|
}
|
1013
1025
|
if (xds_client_ == nullptr) return;
|
1014
|
-
auto* hcm = absl::get_if<XdsListenerResource::HttpConnectionManager>(
|
1015
|
-
&listener
|
1026
|
+
const auto* hcm = absl::get_if<XdsListenerResource::HttpConnectionManager>(
|
1027
|
+
&listener->listener);
|
1016
1028
|
if (hcm == nullptr) {
|
1017
1029
|
return OnError(lds_resource_name_,
|
1018
1030
|
absl::UnavailableError("not an API listener"));
|
1019
1031
|
}
|
1020
|
-
current_listener_ = std::move(
|
1021
|
-
|
1022
|
-
|
1032
|
+
current_listener_ = std::move(listener);
|
1033
|
+
Match(
|
1034
|
+
hcm->route_config,
|
1023
1035
|
// RDS resource name
|
1024
|
-
[&](std::string
|
1036
|
+
[&](const std::string& rds_name) {
|
1025
1037
|
// If the RDS name changed, update the RDS watcher.
|
1026
1038
|
// Note that this will be true on the initial update, because
|
1027
1039
|
// route_config_name_ will be empty.
|
1028
|
-
if (route_config_name_ !=
|
1040
|
+
if (route_config_name_ != rds_name) {
|
1029
1041
|
// If we already had a watch (i.e., if the previous config had
|
1030
1042
|
// a different RDS name), stop the previous watch.
|
1031
1043
|
// There will be no previous watch if either (a) this is the
|
@@ -1038,7 +1050,7 @@ void XdsResolver::OnListenerUpdate(XdsListenerResource listener) {
|
|
1038
1050
|
route_config_watcher_ = nullptr;
|
1039
1051
|
}
|
1040
1052
|
// Start watch for the new RDS resource name.
|
1041
|
-
route_config_name_ =
|
1053
|
+
route_config_name_ = rds_name;
|
1042
1054
|
auto watcher = MakeRefCounted<RouteConfigWatcher>(Ref());
|
1043
1055
|
route_config_watcher_ = watcher.get();
|
1044
1056
|
XdsRouteConfigResourceType::StartWatch(
|
@@ -1051,7 +1063,7 @@ void XdsResolver::OnListenerUpdate(XdsListenerResource listener) {
|
|
1051
1063
|
}
|
1052
1064
|
},
|
1053
1065
|
// inlined RouteConfig
|
1054
|
-
[&](XdsRouteConfigResource
|
1066
|
+
[&](const std::shared_ptr<const XdsRouteConfigResource>& route_config) {
|
1055
1067
|
// If the previous update specified an RDS resource instead of
|
1056
1068
|
// having an inlined RouteConfig, we need to cancel the RDS watch.
|
1057
1069
|
if (route_config_watcher_ != nullptr) {
|
@@ -1060,7 +1072,7 @@ void XdsResolver::OnListenerUpdate(XdsListenerResource listener) {
|
|
1060
1072
|
route_config_watcher_ = nullptr;
|
1061
1073
|
route_config_name_.clear();
|
1062
1074
|
}
|
1063
|
-
OnRouteConfigUpdate(
|
1075
|
+
OnRouteConfigUpdate(route_config);
|
1064
1076
|
});
|
1065
1077
|
}
|
1066
1078
|
|
@@ -1081,16 +1093,15 @@ class VirtualHostListIterator : public XdsRouting::VirtualHostListIterator {
|
|
1081
1093
|
const std::vector<XdsRouteConfigResource::VirtualHost>* virtual_hosts_;
|
1082
1094
|
};
|
1083
1095
|
|
1084
|
-
void XdsResolver::OnRouteConfigUpdate(
|
1096
|
+
void XdsResolver::OnRouteConfigUpdate(
|
1097
|
+
std::shared_ptr<const XdsRouteConfigResource> rds_update) {
|
1085
1098
|
if (GRPC_TRACE_FLAG_ENABLED(grpc_xds_resolver_trace)) {
|
1086
1099
|
gpr_log(GPR_INFO, "[xds_resolver %p] received updated route config", this);
|
1087
1100
|
}
|
1088
|
-
if (xds_client_ == nullptr)
|
1089
|
-
return;
|
1090
|
-
}
|
1101
|
+
if (xds_client_ == nullptr) return;
|
1091
1102
|
// Find the relevant VirtualHost from the RouteConfiguration.
|
1092
1103
|
auto vhost_index = XdsRouting::FindVirtualHostForDomain(
|
1093
|
-
VirtualHostListIterator(&rds_update
|
1104
|
+
VirtualHostListIterator(&rds_update->virtual_hosts),
|
1094
1105
|
data_plane_authority_);
|
1095
1106
|
if (!vhost_index.has_value()) {
|
1096
1107
|
OnError(
|
@@ -1101,9 +1112,8 @@ void XdsResolver::OnRouteConfigUpdate(XdsRouteConfigResource rds_update) {
|
|
1101
1112
|
return;
|
1102
1113
|
}
|
1103
1114
|
// Save the virtual host in the resolver.
|
1104
|
-
|
1105
|
-
|
1106
|
-
std::move(rds_update.cluster_specifier_plugin_map);
|
1115
|
+
current_route_config_ = std::move(rds_update);
|
1116
|
+
current_virtual_host_ = ¤t_route_config_->virtual_hosts[*vhost_index];
|
1107
1117
|
// Send a new result to the channel.
|
1108
1118
|
GenerateResult();
|
1109
1119
|
}
|
@@ -1130,10 +1140,8 @@ void XdsResolver::OnResourceDoesNotExist(std::string context) {
|
|
1130
1140
|
"[xds_resolver %p] LDS/RDS resource does not exist -- clearing "
|
1131
1141
|
"update and returning empty service config",
|
1132
1142
|
this);
|
1133
|
-
if (xds_client_ == nullptr)
|
1134
|
-
|
1135
|
-
}
|
1136
|
-
current_virtual_host_.reset();
|
1143
|
+
if (xds_client_ == nullptr) return;
|
1144
|
+
current_virtual_host_ = nullptr;
|
1137
1145
|
Result result;
|
1138
1146
|
result.addresses.emplace();
|
1139
1147
|
result.service_config = ServiceConfigImpl::Create(args_, "{}");
|
@@ -1154,7 +1162,8 @@ XdsResolver::CreateServiceConfig() {
|
|
1154
1162
|
" \"childPolicy\": %s\n"
|
1155
1163
|
" }",
|
1156
1164
|
cluster.first,
|
1157
|
-
|
1165
|
+
current_route_config_->cluster_specifier_plugin_map.at(
|
1166
|
+
std::string(child_name))));
|
1158
1167
|
} else {
|
1159
1168
|
absl::ConsumePrefix(&child_name, "cluster:");
|
1160
1169
|
clusters.push_back(
|
@@ -1185,12 +1194,13 @@ XdsResolver::CreateServiceConfig() {
|
|
1185
1194
|
}
|
1186
1195
|
|
1187
1196
|
void XdsResolver::GenerateResult() {
|
1188
|
-
if (
|
1197
|
+
if (current_virtual_host_ == nullptr) return;
|
1189
1198
|
// First create XdsConfigSelector, which may add new entries to the cluster
|
1190
1199
|
// state map, and then CreateServiceConfig for LB policies.
|
1191
|
-
auto
|
1192
|
-
|
1193
|
-
|
1200
|
+
const auto& hcm = absl::get<XdsListenerResource::HttpConnectionManager>(
|
1201
|
+
current_listener_->listener);
|
1202
|
+
auto route_config_data = RouteConfigData::Create(
|
1203
|
+
this, current_virtual_host_->routes, hcm.http_max_stream_duration);
|
1194
1204
|
if (!route_config_data.ok()) {
|
1195
1205
|
OnError("could not create ConfigSelector",
|
1196
1206
|
absl::UnavailableError(route_config_data.status().message()));
|
@@ -59,6 +59,8 @@
|
|
59
59
|
#include "src/core/lib/handshaker/proxy_mapper_registry.h"
|
60
60
|
#include "src/core/lib/iomgr/exec_ctx.h"
|
61
61
|
#include "src/core/lib/iomgr/pollset_set.h"
|
62
|
+
#include "src/core/lib/promise/cancel_callback.h"
|
63
|
+
#include "src/core/lib/promise/seq.h"
|
62
64
|
#include "src/core/lib/slice/slice_internal.h"
|
63
65
|
#include "src/core/lib/surface/channel_init.h"
|
64
66
|
#include "src/core/lib/surface/channel_stack_type.h"
|
@@ -133,6 +135,36 @@ size_t ConnectedSubchannel::GetInitialCallSizeEstimate() const {
|
|
133
135
|
channel_stack_->call_stack_size;
|
134
136
|
}
|
135
137
|
|
138
|
+
ArenaPromise<ServerMetadataHandle> ConnectedSubchannel::MakeCallPromise(
|
139
|
+
CallArgs call_args) {
|
140
|
+
// If not using channelz, we just need to call the channel stack.
|
141
|
+
if (channelz_subchannel() == nullptr) {
|
142
|
+
return channel_stack_->MakeClientCallPromise(std::move(call_args));
|
143
|
+
}
|
144
|
+
// Otherwise, we need to wrap the channel stack promise with code that
|
145
|
+
// handles the channelz updates.
|
146
|
+
return OnCancel(
|
147
|
+
Seq(channel_stack_->MakeClientCallPromise(std::move(call_args)),
|
148
|
+
[self = Ref()](ServerMetadataHandle metadata) {
|
149
|
+
channelz::SubchannelNode* channelz_subchannel =
|
150
|
+
self->channelz_subchannel();
|
151
|
+
GPR_ASSERT(channelz_subchannel != nullptr);
|
152
|
+
if (metadata->get(GrpcStatusMetadata())
|
153
|
+
.value_or(GRPC_STATUS_UNKNOWN) != GRPC_STATUS_OK) {
|
154
|
+
channelz_subchannel->RecordCallFailed();
|
155
|
+
} else {
|
156
|
+
channelz_subchannel->RecordCallSucceeded();
|
157
|
+
}
|
158
|
+
return metadata;
|
159
|
+
}),
|
160
|
+
[self = Ref()]() {
|
161
|
+
channelz::SubchannelNode* channelz_subchannel =
|
162
|
+
self->channelz_subchannel();
|
163
|
+
GPR_ASSERT(channelz_subchannel != nullptr);
|
164
|
+
channelz_subchannel->RecordCallFailed();
|
165
|
+
});
|
166
|
+
}
|
167
|
+
|
136
168
|
//
|
137
169
|
// SubchannelCall
|
138
170
|
//
|
@@ -431,6 +463,7 @@ Subchannel::Subchannel(SubchannelKey key,
|
|
431
463
|
pollset_set_(grpc_pollset_set_create()),
|
432
464
|
connector_(std::move(connector)),
|
433
465
|
watcher_list_(this),
|
466
|
+
work_serializer_(args_.GetObjectRef<EventEngine>()),
|
434
467
|
backoff_(ParseArgsForBackoffValues(args_, &min_connect_timeout_)),
|
435
468
|
event_engine_(args_.GetObjectRef<EventEngine>()) {
|
436
469
|
// A grpc_init is added here to ensure that grpc_shutdown does not happen
|
@@ -54,6 +54,7 @@
|
|
54
54
|
#include "src/core/lib/iomgr/iomgr_fwd.h"
|
55
55
|
#include "src/core/lib/iomgr/polling_entity.h"
|
56
56
|
#include "src/core/lib/iomgr/resolved_address.h"
|
57
|
+
#include "src/core/lib/promise/arena_promise.h"
|
57
58
|
#include "src/core/lib/resource_quota/arena.h"
|
58
59
|
#include "src/core/lib/slice/slice.h"
|
59
60
|
#include "src/core/lib/transport/connectivity_state.h"
|
@@ -84,6 +85,8 @@ class ConnectedSubchannel : public RefCounted<ConnectedSubchannel> {
|
|
84
85
|
|
85
86
|
size_t GetInitialCallSizeEstimate() const;
|
86
87
|
|
88
|
+
ArenaPromise<ServerMetadataHandle> MakeCallPromise(CallArgs call_args);
|
89
|
+
|
87
90
|
private:
|
88
91
|
grpc_channel_stack* channel_stack_;
|
89
92
|
ChannelArgs args_;
|
@@ -218,6 +221,8 @@ class Subchannel : public DualRefCounted<Subchannel> {
|
|
218
221
|
|
219
222
|
channelz::SubchannelNode* channelz_node();
|
220
223
|
|
224
|
+
const grpc_resolved_address& address() const { return key_.address(); }
|
225
|
+
|
221
226
|
// Starts watching the subchannel's connectivity state.
|
222
227
|
// The first callback to the watcher will be delivered ~immediately.
|
223
228
|
// Subsequent callbacks will be delivered as the subchannel's state
|
@@ -267,6 +272,10 @@ class Subchannel : public DualRefCounted<Subchannel> {
|
|
267
272
|
void RemoveDataProducer(DataProducerInterface* data_producer)
|
268
273
|
ABSL_LOCKS_EXCLUDED(mu_);
|
269
274
|
|
275
|
+
std::shared_ptr<grpc_event_engine::experimental::EventEngine> event_engine() {
|
276
|
+
return event_engine_;
|
277
|
+
}
|
278
|
+
|
270
279
|
private:
|
271
280
|
// A linked list of ConnectivityStateWatcherInterfaces that are monitoring
|
272
281
|
// the subchannel's state.
|
@@ -49,8 +49,8 @@
|
|
49
49
|
#include <grpc/support/log.h>
|
50
50
|
|
51
51
|
#include "src/core/ext/transport/chttp2/transport/chttp2_transport.h"
|
52
|
-
#include "src/core/ext/transport/chttp2/transport/frame.h"
|
53
52
|
#include "src/core/ext/transport/chttp2/transport/internal.h"
|
53
|
+
#include "src/core/ext/transport/chttp2/transport/legacy_frame.h"
|
54
54
|
#include "src/core/lib/address_utils/sockaddr_utils.h"
|
55
55
|
#include "src/core/lib/channel/channel_args.h"
|
56
56
|
#include "src/core/lib/channel/channelz.h"
|
@@ -55,7 +55,6 @@
|
|
55
55
|
|
56
56
|
#include "src/core/ext/transport/chttp2/transport/context_list_entry.h"
|
57
57
|
#include "src/core/ext/transport/chttp2/transport/flow_control.h"
|
58
|
-
#include "src/core/ext/transport/chttp2/transport/frame.h"
|
59
58
|
#include "src/core/ext/transport/chttp2/transport/frame_data.h"
|
60
59
|
#include "src/core/ext/transport/chttp2/transport/frame_goaway.h"
|
61
60
|
#include "src/core/ext/transport/chttp2/transport/frame_rst_stream.h"
|
@@ -63,6 +62,7 @@
|
|
63
62
|
#include "src/core/ext/transport/chttp2/transport/http2_settings.h"
|
64
63
|
#include "src/core/ext/transport/chttp2/transport/http_trace.h"
|
65
64
|
#include "src/core/ext/transport/chttp2/transport/internal.h"
|
65
|
+
#include "src/core/ext/transport/chttp2/transport/legacy_frame.h"
|
66
66
|
#include "src/core/ext/transport/chttp2/transport/ping_abuse_policy.h"
|
67
67
|
#include "src/core/ext/transport/chttp2/transport/ping_rate_policy.h"
|
68
68
|
#include "src/core/ext/transport/chttp2/transport/varint.h"
|
@@ -569,10 +569,12 @@ grpc_chttp2_transport::grpc_chttp2_transport(
|
|
569
569
|
grpc_endpoint_get_peer(ep), ":client_transport"))),
|
570
570
|
self_reservation(
|
571
571
|
memory_owner.MakeReservation(sizeof(grpc_chttp2_transport))),
|
572
|
-
|
572
|
+
event_engine(
|
573
|
+
channel_args
|
574
|
+
.GetObjectRef<grpc_event_engine::experimental::EventEngine>()),
|
575
|
+
combiner(grpc_combiner_create(event_engine)),
|
573
576
|
state_tracker(is_client ? "client_transport" : "server_transport",
|
574
577
|
GRPC_CHANNEL_READY),
|
575
|
-
is_client(is_client),
|
576
578
|
next_stream_id(is_client ? 1 : 2),
|
577
579
|
ping_abuse_policy(channel_args),
|
578
580
|
ping_rate_policy(channel_args, is_client),
|
@@ -581,9 +583,7 @@ grpc_chttp2_transport::grpc_chttp2_transport(
|
|
581
583
|
channel_args.GetBool(GRPC_ARG_HTTP2_BDP_PROBE).value_or(true),
|
582
584
|
&memory_owner),
|
583
585
|
deframe_state(is_client ? GRPC_DTS_FH_0 : GRPC_DTS_CLIENT_PREFIX_0),
|
584
|
-
|
585
|
-
channel_args
|
586
|
-
.GetObjectRef<grpc_event_engine::experimental::EventEngine>()) {
|
586
|
+
is_client(is_client) {
|
587
587
|
cl = new grpc_core::ContextList();
|
588
588
|
GPR_ASSERT(strlen(GRPC_CHTTP2_CLIENT_CONNECT_STRING) ==
|
589
589
|
GRPC_CHTTP2_CLIENT_CONNECT_STRLEN);
|
@@ -1875,6 +1875,7 @@ static void perform_transport_op_locked(void* stream_op,
|
|
1875
1875
|
if (op->set_accept_stream) {
|
1876
1876
|
t->accept_stream_cb = op->set_accept_stream_fn;
|
1877
1877
|
t->accept_stream_cb_user_data = op->set_accept_stream_user_data;
|
1878
|
+
t->registered_method_matcher_cb = op->set_registered_method_matcher_fn;
|
1878
1879
|
}
|
1879
1880
|
|
1880
1881
|
if (op->bind_pollset) {
|
@@ -1944,6 +1945,10 @@ void grpc_chttp2_maybe_complete_recv_initial_metadata(grpc_chttp2_transport* t,
|
|
1944
1945
|
*s->trailing_metadata_available = true;
|
1945
1946
|
s->trailing_metadata_available = nullptr;
|
1946
1947
|
}
|
1948
|
+
if (t->registered_method_matcher_cb != nullptr) {
|
1949
|
+
t->registered_method_matcher_cb(t->accept_stream_cb_user_data,
|
1950
|
+
s->recv_initial_metadata);
|
1951
|
+
}
|
1947
1952
|
null_then_sched_closure(&s->recv_initial_metadata_ready);
|
1948
1953
|
}
|
1949
1954
|
}
|
@@ -116,20 +116,21 @@ TransportFlowControl::TransportFlowControl(absl::string_view name,
|
|
116
116
|
.set_integral_range(10)),
|
117
117
|
last_pid_update_(Timestamp::Now()) {}
|
118
118
|
|
119
|
-
uint32_t TransportFlowControl::
|
119
|
+
uint32_t TransportFlowControl::DesiredAnnounceSize(bool writing_anyway) const {
|
120
120
|
const uint32_t target_announced_window =
|
121
121
|
static_cast<uint32_t>(target_window());
|
122
122
|
if ((writing_anyway || announced_window_ <= target_announced_window / 2) &&
|
123
123
|
announced_window_ != target_announced_window) {
|
124
|
-
|
125
|
-
|
126
|
-
int64_t{0}, kMaxWindowUpdateSize));
|
127
|
-
announced_window_ += announce;
|
128
|
-
return announce;
|
124
|
+
return Clamp(target_announced_window - announced_window_, int64_t{0},
|
125
|
+
kMaxWindowUpdateSize);
|
129
126
|
}
|
130
127
|
return 0;
|
131
128
|
}
|
132
129
|
|
130
|
+
void TransportFlowControl::SentUpdate(uint32_t announce) {
|
131
|
+
announced_window_ += announce;
|
132
|
+
}
|
133
|
+
|
133
134
|
StreamFlowControl::StreamFlowControl(TransportFlowControl* tfc) : tfc_(tfc) {}
|
134
135
|
|
135
136
|
absl::Status StreamFlowControl::IncomingUpdateContext::RecvData(
|
@@ -170,7 +171,7 @@ int64_t TransportFlowControl::target_window() const {
|
|
170
171
|
return static_cast<uint32_t>(
|
171
172
|
std::min(static_cast<int64_t>((1u << 31) - 1),
|
172
173
|
announced_stream_total_over_incoming_window_ +
|
173
|
-
target_initial_window_size_));
|
174
|
+
std::max<int64_t>(1, target_initial_window_size_)));
|
174
175
|
}
|
175
176
|
|
176
177
|
FlowControlAction TransportFlowControl::UpdateAction(FlowControlAction action) {
|
@@ -363,17 +364,15 @@ FlowControlAction TransportFlowControl::PeriodicUpdate() {
|
|
363
364
|
return UpdateAction(action);
|
364
365
|
}
|
365
366
|
|
366
|
-
|
367
|
+
void StreamFlowControl::SentUpdate(uint32_t announce) {
|
367
368
|
TransportFlowControl::IncomingUpdateContext tfc_upd(tfc_);
|
368
|
-
const int64_t announce = DesiredAnnounceSize();
|
369
369
|
pending_size_ = absl::nullopt;
|
370
370
|
tfc_upd.UpdateAnnouncedWindowDelta(&announced_window_delta_, announce);
|
371
371
|
GPR_ASSERT(DesiredAnnounceSize() == 0);
|
372
372
|
std::ignore = tfc_upd.MakeAction();
|
373
|
-
return static_cast<uint32_t>(announce);
|
374
373
|
}
|
375
374
|
|
376
|
-
|
375
|
+
uint32_t StreamFlowControl::DesiredAnnounceSize() const {
|
377
376
|
int64_t desired_window_delta = [this]() {
|
378
377
|
if (min_progress_size_ == 0) {
|
379
378
|
if (pending_size_.has_value() &&
|
@@ -401,22 +400,29 @@ FlowControlAction StreamFlowControl::UpdateAction(FlowControlAction action) {
|
|
401
400
|
// greater). 8kb means we don't send rapidly unnecessarily when the initial
|
402
401
|
// window size is small.
|
403
402
|
const int64_t hurry_up_size = std::max(
|
404
|
-
static_cast<int64_t>(tfc_->
|
403
|
+
static_cast<int64_t>(tfc_->queued_init_window()) / 2, int64_t{8192});
|
405
404
|
if (desired_announce_size > hurry_up_size) {
|
406
405
|
urgency = FlowControlAction::Urgency::UPDATE_IMMEDIATELY;
|
407
406
|
}
|
408
407
|
// min_progress_size_ > 0 means we have a reader ready to read.
|
409
408
|
if (min_progress_size_ > 0) {
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
//
|
417
|
-
//
|
418
|
-
|
419
|
-
|
409
|
+
if (IsLazierStreamUpdatesEnabled()) {
|
410
|
+
if (announced_window_delta_ <=
|
411
|
+
-static_cast<int64_t>(tfc_->sent_init_window()) / 2) {
|
412
|
+
urgency = FlowControlAction::Urgency::UPDATE_IMMEDIATELY;
|
413
|
+
}
|
414
|
+
} else {
|
415
|
+
// If we're into initial window to receive that data we should wake up
|
416
|
+
// and send an update.
|
417
|
+
if (announced_window_delta_ < 0) {
|
418
|
+
urgency = FlowControlAction::Urgency::UPDATE_IMMEDIATELY;
|
419
|
+
} else if (announced_window_delta_ == 0 &&
|
420
|
+
tfc_->queued_init_window() == 0) {
|
421
|
+
// Special case when initial window size is zero, meaning that
|
422
|
+
// announced_window_delta cannot become negative (it may already be so
|
423
|
+
// however).
|
424
|
+
urgency = FlowControlAction::Urgency::UPDATE_IMMEDIATELY;
|
425
|
+
}
|
420
426
|
}
|
421
427
|
}
|
422
428
|
action.set_send_stream_update(urgency);
|
@@ -179,7 +179,17 @@ class TransportFlowControl final {
|
|
179
179
|
// else returns zero; writing_anyway indicates if a write would happen
|
180
180
|
// regardless of the send - if it is false and this function returns non-zero,
|
181
181
|
// this announce will cause a write to occur
|
182
|
-
uint32_t
|
182
|
+
uint32_t DesiredAnnounceSize(bool writing_anyway) const;
|
183
|
+
// notify that we've actually sent a stream window update
|
184
|
+
// (should be DesiredAnnounceSize())
|
185
|
+
void SentUpdate(uint32_t announce);
|
186
|
+
|
187
|
+
// Older API: combines getting the DesiredAnnounceSize() with SentUpdate()
|
188
|
+
uint32_t MaybeSendUpdate(bool writing_anyway) {
|
189
|
+
uint32_t n = DesiredAnnounceSize(writing_anyway);
|
190
|
+
SentUpdate(n);
|
191
|
+
return n;
|
192
|
+
}
|
183
193
|
|
184
194
|
// Track an update to the incoming flow control counters - that is how many
|
185
195
|
// tokens we report to our peer that we're willing to accept.
|
@@ -260,7 +270,10 @@ class TransportFlowControl final {
|
|
260
270
|
BdpEstimator* bdp_estimator() { return &bdp_estimator_; }
|
261
271
|
|
262
272
|
uint32_t acked_init_window() const { return acked_init_window_; }
|
263
|
-
uint32_t
|
273
|
+
uint32_t queued_init_window() const { return target_initial_window_size_; }
|
274
|
+
uint32_t sent_init_window() const { return sent_init_window_; }
|
275
|
+
|
276
|
+
void FlushedSettings() { sent_init_window_ = queued_init_window(); }
|
264
277
|
|
265
278
|
FlowControlAction SetAckedInitialWindow(uint32_t value);
|
266
279
|
|
@@ -319,6 +332,7 @@ class TransportFlowControl final {
|
|
319
332
|
kDefaultPreferredRxCryptoFrameSize;
|
320
333
|
int64_t announced_window_ = kDefaultWindow;
|
321
334
|
uint32_t acked_init_window_ = kDefaultWindow;
|
335
|
+
uint32_t sent_init_window_ = kDefaultWindow;
|
322
336
|
};
|
323
337
|
|
324
338
|
// Implementation of flow control that abides to HTTP/2 spec and attempts
|
@@ -379,7 +393,17 @@ class StreamFlowControl final {
|
|
379
393
|
|
380
394
|
// returns an announce if we should send a stream update to our peer, else
|
381
395
|
// returns zero
|
382
|
-
uint32_t
|
396
|
+
uint32_t DesiredAnnounceSize() const;
|
397
|
+
// notify that we've actually sent a stream window update
|
398
|
+
// (should be DesiredAnnounceSize())
|
399
|
+
void SentUpdate(uint32_t announce);
|
400
|
+
|
401
|
+
// Older API: combines getting the DesiredAnnounceSize() with SentUpdate()
|
402
|
+
uint32_t MaybeSendUpdate() {
|
403
|
+
uint32_t n = DesiredAnnounceSize();
|
404
|
+
SentUpdate(n);
|
405
|
+
return n;
|
406
|
+
}
|
383
407
|
|
384
408
|
int64_t remote_window_delta() const { return remote_window_delta_; }
|
385
409
|
int64_t announced_window_delta() const { return announced_window_delta_; }
|
@@ -393,7 +417,6 @@ class StreamFlowControl final {
|
|
393
417
|
absl::optional<int64_t> pending_size_;
|
394
418
|
|
395
419
|
FlowControlAction UpdateAction(FlowControlAction action);
|
396
|
-
int64_t DesiredAnnounceSize() const;
|
397
420
|
};
|
398
421
|
|
399
422
|
class TestOnlyTransportTargetWindowEstimatesMocker {
|
@@ -29,7 +29,7 @@
|
|
29
29
|
|
30
30
|
#include <grpc/slice.h>
|
31
31
|
|
32
|
-
#include "src/core/ext/transport/chttp2/transport/
|
32
|
+
#include "src/core/ext/transport/chttp2/transport/legacy_frame.h"
|
33
33
|
#include "src/core/lib/iomgr/error.h"
|
34
34
|
#include "src/core/lib/promise/poll.h"
|
35
35
|
#include "src/core/lib/slice/slice_buffer.h"
|
@@ -24,6 +24,7 @@
|
|
24
24
|
|
25
25
|
#include <algorithm>
|
26
26
|
#include <initializer_list>
|
27
|
+
#include <string>
|
27
28
|
|
28
29
|
#include "absl/container/flat_hash_map.h"
|
29
30
|
#include "absl/status/status.h"
|
@@ -34,6 +35,10 @@
|
|
34
35
|
|
35
36
|
#include "src/core/ext/transport/chttp2/transport/internal.h"
|
36
37
|
#include "src/core/ext/transport/chttp2/transport/ping_abuse_policy.h"
|
38
|
+
#include "src/core/lib/debug/trace.h"
|
39
|
+
|
40
|
+
extern grpc_core::TraceFlag grpc_keepalive_trace;
|
41
|
+
extern grpc_core::TraceFlag grpc_http_trace;
|
37
42
|
|
38
43
|
grpc_slice grpc_chttp2_ping_create(uint8_t ack, uint64_t opaque_8bytes) {
|
39
44
|
grpc_slice slice = GRPC_SLICE_MALLOC(9 + 8);
|
@@ -96,6 +101,10 @@ grpc_error_handle grpc_chttp2_ping_parser_parse(void* parser,
|
|
96
101
|
if (!t->is_client) {
|
97
102
|
const bool transport_idle =
|
98
103
|
t->keepalive_permit_without_calls == 0 && t->stream_map.empty();
|
104
|
+
if (grpc_keepalive_trace.enabled() || grpc_http_trace.enabled()) {
|
105
|
+
gpr_log(GPR_INFO, "t=%p received ping: %s", t,
|
106
|
+
t->ping_abuse_policy.GetDebugString(transport_idle).c_str());
|
107
|
+
}
|
99
108
|
if (t->ping_abuse_policy.ReceivedOnePing(transport_idle)) {
|
100
109
|
grpc_chttp2_exceeded_ping_strikes(t);
|
101
110
|
}
|
@@ -31,9 +31,9 @@
|
|
31
31
|
#include <grpc/slice_buffer.h>
|
32
32
|
#include <grpc/support/log.h>
|
33
33
|
|
34
|
-
#include "src/core/ext/transport/chttp2/transport/frame.h"
|
35
34
|
#include "src/core/ext/transport/chttp2/transport/http_trace.h"
|
36
35
|
#include "src/core/ext/transport/chttp2/transport/internal.h"
|
36
|
+
#include "src/core/ext/transport/chttp2/transport/legacy_frame.h"
|
37
37
|
#include "src/core/lib/debug/trace.h"
|
38
38
|
#include "src/core/lib/gprpp/status_helper.h"
|
39
39
|
#include "src/core/lib/transport/http2_errors.h"
|
@@ -34,10 +34,10 @@
|
|
34
34
|
#include <grpc/support/log.h>
|
35
35
|
|
36
36
|
#include "src/core/ext/transport/chttp2/transport/flow_control.h"
|
37
|
-
#include "src/core/ext/transport/chttp2/transport/frame.h"
|
38
37
|
#include "src/core/ext/transport/chttp2/transport/frame_goaway.h"
|
39
38
|
#include "src/core/ext/transport/chttp2/transport/http_trace.h"
|
40
39
|
#include "src/core/ext/transport/chttp2/transport/internal.h"
|
40
|
+
#include "src/core/ext/transport/chttp2/transport/legacy_frame.h"
|
41
41
|
#include "src/core/lib/debug/trace.h"
|
42
42
|
#include "src/core/lib/gpr/useful.h"
|
43
43
|
#include "src/core/lib/gprpp/debug_location.h"
|