grpc 1.83.1 → 1.84.0
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.
- checksums.yaml +4 -4
- data/Makefile +21 -17
- data/include/grpc/credentials.h +10 -0
- data/include/grpc/grpc_security_constants.h +2 -0
- data/include/grpc/impl/channel_arg_names.h +9 -0
- data/src/core/call/call_filters.h +4 -2
- data/src/core/call/client_call.cc +20 -8
- data/src/core/call/client_call.h +4 -0
- data/src/core/call/interception_chain.cc +2 -0
- data/src/core/call/interception_chain.h +14 -1
- data/src/core/call/metadata.cc +1 -3
- data/src/core/call/metadata_batch.h +13 -5
- data/src/core/call/server_call.cc +31 -14
- data/src/core/call/server_call.h +4 -0
- data/src/core/channelz/text_encode.cc +9 -4
- data/src/core/channelz/v2tov1/convert.cc +2 -2
- data/src/core/client_channel/backup_poller.cc +1 -2
- data/src/core/client_channel/client_channel.cc +6 -33
- data/src/core/client_channel/client_channel_filter.cc +22 -55
- data/src/core/client_channel/client_channel_filter.h +2 -2
- data/src/core/client_channel/client_channel_service_config.cc +3 -19
- data/src/core/client_channel/direct_channel.cc +7 -1
- data/src/core/client_channel/direct_channel.h +2 -2
- data/src/core/client_channel/load_balanced_call_destination.cc +5 -3
- data/src/core/client_channel/retry_filter_legacy_call_data.cc +5 -12
- data/src/core/client_channel/subchannel.cc +310 -1058
- data/src/core/client_channel/subchannel.h +44 -329
- data/src/core/client_channel/subchannel_metrics.cc +48 -0
- data/src/core/client_channel/subchannel_metrics.h +60 -0
- data/src/core/credentials/call/external/file_external_account_credentials.cc +1 -1
- data/src/core/credentials/call/external/url_external_account_credentials.cc +2 -3
- data/src/core/credentials/call/gcp_service_account_identity/gcp_service_account_identity_credentials.cc +8 -24
- data/src/core/credentials/call/gcp_service_account_identity/gcp_service_account_identity_credentials.h +3 -6
- data/src/core/credentials/call/gdch_service_account/gdch_service_account_credentials.cc +525 -0
- data/src/core/credentials/call/gdch_service_account/gdch_service_account_credentials.h +138 -0
- data/src/core/credentials/call/json_util.h +1 -0
- data/src/core/credentials/call/jwt/json_token.cc +10 -2
- data/src/core/credentials/call/jwt/jwt_verifier.cc +15 -1
- data/src/core/credentials/call/jwt_token_file/jwt_token_file_call_credentials.cc +1 -1
- data/src/core/credentials/call/oauth2/oauth2_credentials.cc +42 -79
- data/src/core/credentials/call/oauth2/oauth2_credentials.h +2 -5
- data/src/core/credentials/call/token_fetcher/token_fetcher_credentials.cc +52 -31
- data/src/core/credentials/call/token_fetcher/token_fetcher_credentials.h +21 -8
- data/src/core/credentials/transport/google_default/google_default_credentials.cc +3 -4
- data/src/core/credentials/transport/ssl/ssl_credentials.cc +59 -72
- data/src/core/credentials/transport/ssl/ssl_credentials.h +9 -8
- data/src/core/credentials/transport/ssl/ssl_security_connector.cc +12 -6
- data/src/core/credentials/transport/ssl/ssl_security_connector.h +4 -4
- data/src/core/credentials/transport/tls/grpc_tls_certificate_distributor.cc +29 -18
- data/src/core/credentials/transport/tls/grpc_tls_certificate_distributor.h +9 -6
- data/src/core/credentials/transport/tls/grpc_tls_certificate_provider.cc +45 -56
- data/src/core/credentials/transport/tls/grpc_tls_certificate_provider.h +5 -4
- data/src/core/credentials/transport/tls/grpc_tls_certificate_selector.h +26 -0
- data/src/core/credentials/transport/tls/grpc_tls_crl_provider.cc +1 -1
- data/src/core/credentials/transport/tls/load_system_roots.h +2 -6
- data/src/core/credentials/transport/tls/load_system_roots_fallback.cc +2 -4
- data/src/core/credentials/transport/tls/load_system_roots_supported.cc +13 -15
- data/src/core/credentials/transport/tls/load_system_roots_supported.h +3 -2
- data/src/core/credentials/transport/tls/load_system_roots_windows.cc +5 -8
- data/src/core/credentials/transport/tls/spiffe_utils.cc +1 -1
- data/src/core/credentials/transport/tls/ssl_utils.cc +39 -28
- data/src/core/credentials/transport/tls/ssl_utils.h +12 -49
- data/src/core/credentials/transport/tls/tls_security_connector.cc +48 -33
- data/src/core/credentials/transport/tls/tls_security_connector.h +31 -10
- data/src/core/ext/filters/channel_idle/legacy_channel_idle_filter.cc +15 -11
- data/src/core/ext/filters/http/http_filters_plugin.cc +20 -9
- data/src/core/ext/filters/rbac/rbac_filter.cc +43 -21
- data/src/core/ext/filters/rbac/rbac_filter.h +21 -3
- data/src/core/ext/filters/rbac/rbac_service_config_parser.cc +2 -2
- data/src/core/ext/transport/chttp2/client/chttp2_connector.cc +1 -1
- data/src/core/ext/transport/chttp2/server/chttp2_server.cc +6 -20
- data/src/core/ext/transport/chttp2/transport/chttp2_transport.cc +32 -67
- data/src/core/ext/transport/chttp2/transport/flow_control.cc +2 -0
- data/src/core/ext/transport/chttp2/transport/flow_control.h +78 -4
- data/src/core/ext/transport/chttp2/transport/frame.h +2 -0
- data/src/core/ext/transport/chttp2/transport/frame_data.cc +3 -4
- data/src/core/ext/transport/chttp2/transport/goaway.h +7 -0
- data/src/core/ext/transport/chttp2/transport/hpack_parser.cc +5 -3
- data/src/core/ext/transport/chttp2/transport/hpack_parser.h +3 -1
- data/src/core/ext/transport/chttp2/transport/http2_client_transport.cc +141 -130
- data/src/core/ext/transport/chttp2/transport/http2_client_transport.h +22 -22
- data/src/core/ext/transport/chttp2/transport/http2_server_transport.cc +402 -269
- data/src/core/ext/transport/chttp2/transport/http2_server_transport.h +80 -49
- data/src/core/ext/transport/chttp2/transport/http2_settings_promises.h +1 -2
- data/src/core/ext/transport/chttp2/transport/http2_status.h +38 -37
- data/src/core/ext/transport/chttp2/transport/http2_transport.cc +178 -5
- data/src/core/ext/transport/chttp2/transport/http2_transport.h +345 -5
- data/src/core/ext/transport/chttp2/transport/parsing.cc +5 -5
- data/src/core/ext/transport/chttp2/transport/ping_promise.cc +3 -2
- data/src/core/ext/transport/chttp2/transport/ping_promise.h +25 -5
- data/src/core/ext/transport/chttp2/transport/ping_rate_policy.cc +3 -4
- data/src/core/ext/transport/chttp2/transport/read_context.h +30 -3
- data/src/core/ext/transport/chttp2/transport/stream.h +65 -23
- data/src/core/ext/transport/chttp2/transport/writing.cc +0 -3
- data/src/core/ext/transport/inproc/inproc_transport.cc +1 -5
- data/src/core/ext/transport/inproc/legacy_inproc_transport.cc +4 -17
- data/src/core/ext/upb-gen/envoy/extensions/filters/http/ext_proc/v3/ext_proc.upb.h +1912 -0
- data/src/core/ext/upb-gen/envoy/extensions/filters/http/ext_proc/v3/ext_proc.upb_minitable.c +300 -0
- data/src/core/ext/upb-gen/envoy/extensions/filters/http/ext_proc/v3/ext_proc.upb_minitable.h +37 -0
- data/src/core/ext/upb-gen/envoy/extensions/filters/http/ext_proc/v3/processing_mode.upb.h +187 -0
- data/src/core/ext/upb-gen/envoy/extensions/filters/http/ext_proc/v3/processing_mode.upb_minitable.c +64 -0
- data/src/core/ext/upb-gen/envoy/extensions/filters/http/ext_proc/v3/processing_mode.upb_minitable.h +31 -0
- data/src/core/ext/upb-gen/envoy/service/ext_proc/v3/external_processor.upb.h +2362 -0
- data/src/core/ext/upb-gen/envoy/service/ext_proc/v3/external_processor.upb_minitable.c +556 -0
- data/src/core/ext/upb-gen/envoy/service/ext_proc/v3/external_processor.upb_minitable.h +47 -0
- data/src/core/ext/upb-gen/{src/proto/grpc/channelz → grpc/channelz/v1}/channelz.upb.h +5 -5
- data/src/core/ext/upb-gen/{src/proto/grpc/channelz → grpc/channelz/v1}/channelz.upb_minitable.c +3 -3
- data/src/core/ext/upb-gen/{src/proto/grpc/channelz → grpc/channelz/v1}/channelz.upb_minitable.h +5 -5
- data/src/core/ext/upbdefs-gen/envoy/extensions/filters/http/ext_proc/v3/ext_proc.upbdefs.c +453 -0
- data/src/core/ext/upbdefs-gen/envoy/extensions/filters/http/ext_proc/v3/ext_proc.upbdefs.h +67 -0
- data/src/core/ext/upbdefs-gen/envoy/extensions/filters/http/ext_proc/v3/processing_mode.upbdefs.c +142 -0
- data/src/core/ext/upbdefs-gen/envoy/extensions/filters/http/ext_proc/v3/processing_mode.upbdefs.h +37 -0
- data/src/core/ext/upbdefs-gen/grpc/channelz/v1/channelz.upbdefs.c +715 -0
- data/src/core/ext/upbdefs-gen/{src/proto/grpc/channelz → grpc/channelz/v1}/channelz.upbdefs.h +44 -44
- data/src/core/filter/auth/server_auth_filter.cc +2 -3
- data/src/core/filter/composite/composite_filter.cc +45 -33
- data/src/core/filter/composite/composite_filter.h +5 -4
- data/src/core/filter/ext_proc/ext_proc_filter.cc +224 -0
- data/src/core/filter/ext_proc/ext_proc_filter.h +155 -0
- data/src/core/filter/ext_proc/ext_proc_messages.cc +701 -0
- data/src/core/filter/ext_proc/ext_proc_messages.h +297 -0
- data/src/core/filter/filter_args.h +13 -2
- data/src/core/handshaker/http_connect/http_proxy_mapper.cc +30 -3
- data/src/core/handshaker/security/security_handshaker.cc +9 -6
- data/src/core/lib/channel/channel_stack.cc +3 -0
- data/src/core/lib/channel/channel_stack.h +2 -0
- data/src/core/lib/channel/channel_stack_builder_impl.cc +1 -2
- data/src/core/lib/channel/promise_based_filter.cc +132 -20
- data/src/core/lib/channel/promise_based_filter.h +42 -12
- data/src/core/lib/compression/compression_internal.cc +4 -5
- data/src/core/lib/debug/trace_flags.cc +8 -0
- data/src/core/lib/debug/trace_flags.h +3 -0
- data/src/core/lib/event_engine/ares_resolver.cc +54 -50
- data/src/core/lib/event_engine/ares_resolver.h +3 -2
- data/src/core/lib/event_engine/posix_engine/ev_epoll1_linux.cc +3 -3
- data/src/core/lib/event_engine/posix_engine/ev_poll_posix.cc +4 -10
- data/src/core/lib/event_engine/posix_engine/posix_endpoint.cc +74 -33
- data/src/core/lib/event_engine/posix_engine/posix_endpoint.h +4 -4
- data/src/core/lib/event_engine/posix_engine/posix_engine.cc +6 -2
- data/src/core/lib/event_engine/posix_engine/tcp_socket_utils.cc +3 -0
- data/src/core/lib/event_engine/posix_engine/tcp_socket_utils.h +3 -0
- data/src/core/lib/event_engine/windows/windows_endpoint.cc +1 -3
- data/src/core/lib/experiments/experiments.cc +60 -96
- data/src/core/lib/experiments/experiments.h +34 -50
- data/src/core/lib/iomgr/cfstream_handle.cc +2 -6
- data/src/core/lib/iomgr/endpoint_cfstream.cc +3 -10
- data/src/core/lib/iomgr/error.cc +2 -6
- data/src/core/lib/iomgr/error_cfstream.cc +1 -1
- data/src/core/lib/iomgr/ev_poll_posix.cc +5 -9
- data/src/core/lib/iomgr/event_engine_shims/closure.cc +1 -1
- data/src/core/lib/iomgr/event_engine_shims/endpoint.cc +1 -2
- data/src/core/lib/iomgr/event_engine_shims/tcp_client.cc +1 -2
- data/src/core/lib/iomgr/iomgr_posix.cc +0 -4
- data/src/core/lib/iomgr/iomgr_posix_cfstream.cc +0 -4
- data/src/core/lib/iomgr/iomgr_windows.cc +0 -4
- data/src/core/lib/iomgr/socket_factory_posix.h +1 -1
- data/src/core/lib/iomgr/socket_utils_posix.cc +3 -0
- data/src/core/lib/iomgr/socket_utils_posix.h +3 -0
- data/src/core/lib/iomgr/systemd_utils.cc +0 -1
- data/src/core/lib/iomgr/tcp_client.h +1 -1
- data/src/core/lib/iomgr/tcp_posix.cc +23 -15
- data/src/core/lib/iomgr/tcp_server.h +1 -1
- data/src/core/lib/iomgr/tcp_server_posix.cc +2 -3
- data/src/core/lib/iomgr/tcp_server_utils_posix.h +0 -1
- data/src/core/lib/iomgr/tcp_server_windows.cc +0 -1
- data/src/core/lib/iomgr/tcp_windows.cc +5 -10
- data/src/core/lib/iomgr/unix_sockets_posix.cc +2 -4
- data/src/core/lib/iomgr/unix_sockets_posix.h +3 -1
- data/src/core/lib/iomgr/vsock.h +3 -1
- data/src/core/lib/resource_quota/memory_quota.cc +1 -1
- data/src/core/lib/security/authorization/rbac_policy.cc +139 -56
- data/src/core/lib/security/authorization/rbac_policy.h +21 -3
- data/src/core/lib/surface/call.cc +3 -9
- data/src/core/lib/surface/call_utils.h +113 -0
- data/src/core/lib/surface/channel_create.cc +1 -1
- data/src/core/lib/surface/channel_create.h +0 -2
- data/src/core/lib/surface/channel_init.cc +77 -38
- data/src/core/lib/surface/channel_init.h +30 -16
- data/src/core/lib/surface/filter_stack_call.cc +5 -10
- data/src/core/lib/surface/init.cc +13 -27
- data/src/core/lib/surface/version.cc +1 -1
- data/src/core/lib/transport/error_utils.cc +0 -27
- data/src/core/lib/transport/error_utils.h +0 -16
- data/src/core/lib/transport/transport.h +7 -5
- data/src/core/load_balancing/pick_first/pick_first.cc +2 -0
- data/src/core/load_balancing/rls/rls.cc +28 -11
- data/src/core/load_balancing/weighted_round_robin/weighted_round_robin.cc +33 -42
- data/src/core/load_balancing/weighted_round_robin/weighted_round_robin.h +0 -2
- data/src/core/load_balancing/xds/cds.cc +3 -1
- data/src/core/load_balancing/xds/xds_cluster_impl.cc +0 -1
- data/src/core/mitigation_engine/mitigation.h +14 -5
- data/src/core/mitigation_engine/mitigation_engine.h +7 -3
- data/src/core/mitigation_engine/mitigation_provider.h +2 -1
- data/src/core/plugin_registry/grpc_plugin_registry.cc +39 -8
- data/src/core/resolver/dns/{event_engine/event_engine_client_channel_resolver.cc → dns_resolver.cc} +42 -41
- data/src/core/resolver/dns/{event_engine/event_engine_client_channel_resolver.h → dns_resolver.h} +8 -5
- data/src/core/resolver/dns/{event_engine/service_config_helper.cc → service_config_helper.cc} +1 -1
- data/src/core/resolver/dns/{event_engine/service_config_helper.h → service_config_helper.h} +3 -3
- data/src/core/resolver/endpoint_addresses.h +3 -0
- data/src/core/resolver/google_c2p/google_c2p_resolver.cc +2 -1
- data/src/core/resolver/xds/xds_resolver.cc +35 -9
- data/src/core/server/server.cc +2 -6
- data/src/core/server/server_config_selector.h +18 -3
- data/src/core/server/server_config_selector_filter.cc +178 -91
- data/src/core/server/server_config_selector_filter.h +58 -3
- data/src/core/server/xds_server_config_fetcher.cc +196 -129
- data/src/core/server/xds_server_config_fetcher.h +49 -0
- data/src/core/server/xds_server_config_fetcher_legacy.cc +41 -37
- data/src/core/telemetry/histogram.h +94 -14
- data/src/core/telemetry/instrument.cc +179 -74
- data/src/core/telemetry/instrument.h +78 -30
- data/src/core/telemetry/metrics.h +5 -0
- data/src/core/{resolver/dns/dns_resolver_plugin.h → telemetry/telemetry_label.h} +12 -8
- data/src/core/tsi/alts/crypt/aes_gcm.cc +10 -13
- data/src/core/tsi/alts/handshaker/alts_tsi_handshaker.cc +2 -2
- data/src/core/tsi/alts/handshaker/alts_tsi_handshaker.h +3 -1
- data/src/core/tsi/ssl_telemetry_utils.cc +216 -259
- data/src/core/tsi/ssl_telemetry_utils.h +12 -2
- data/src/core/tsi/ssl_transport_security.cc +238 -80
- data/src/core/tsi/ssl_transport_security.h +63 -33
- data/src/core/tsi/tls_telemetry.cc +31 -0
- data/src/core/tsi/tls_telemetry.h +47 -0
- data/src/core/tsi/transport_security.cc +2 -2
- data/src/core/tsi/transport_security.h +1 -1
- data/src/core/tsi/transport_security_interface.h +1 -1
- data/src/core/{resolver/dns/native/dns_resolver.h → util/address_sorting_init.cc} +21 -8
- data/src/core/{resolver/dns/c_ares/grpc_ares_wrapper_posix.cc → util/address_sorting_init.h} +7 -8
- data/src/core/util/http_client/httpcli.cc +16 -53
- data/src/core/util/http_client/httpcli.h +0 -7
- data/src/core/util/http_client/httpcli_security_connector.cc +13 -8
- data/src/core/util/linux/cpu.cc +1 -1
- data/src/core/util/load_file.cc +3 -9
- data/src/core/util/load_file.h +3 -4
- data/src/core/util/matchers.h +8 -0
- data/src/core/util/posix/cpu.cc +1 -1
- data/src/core/util/status_helper.cc +0 -20
- data/src/core/util/status_helper.h +3 -14
- data/src/core/xds/grpc/xds_audit_logger_registry.cc +51 -31
- data/src/core/xds/grpc/xds_audit_logger_registry.h +17 -3
- data/src/core/xds/grpc/xds_bootstrap_grpc.cc +2 -10
- data/src/core/xds/grpc/xds_bootstrap_grpc.h +8 -6
- data/src/core/xds/grpc/xds_bootstrap_grpc_builder.cc +488 -0
- data/src/core/xds/grpc/xds_bootstrap_grpc_builder.h +97 -0
- data/src/core/xds/grpc/xds_certificate_provider.cc +7 -7
- data/src/core/xds/grpc/xds_client_grpc.cc +4 -8
- data/src/core/xds/grpc/xds_client_grpc.h +0 -4
- data/src/core/xds/grpc/xds_cluster.h +1 -0
- data/src/core/xds/grpc/xds_cluster_parser.cc +1 -5
- data/src/core/xds/grpc/xds_cluster_parser.h +0 -2
- data/src/core/xds/grpc/xds_cluster_specifier_plugin.cc +0 -2
- data/src/core/xds/grpc/xds_cluster_specifier_plugin.h +0 -2
- data/src/core/xds/grpc/xds_common_types.cc +0 -91
- data/src/core/xds/grpc/xds_common_types.h +1 -47
- data/src/core/xds/grpc/xds_common_types_parser.cc +84 -378
- data/src/core/xds/grpc/xds_common_types_parser.h +9 -11
- data/src/core/xds/grpc/xds_endpoint_parser.cc +0 -2
- data/src/core/xds/grpc/xds_grpc_service_parser.cc +177 -0
- data/src/core/{resolver/dns/c_ares/dns_resolver_ares.h → xds/grpc/xds_grpc_service_parser.h} +14 -9
- data/src/core/xds/grpc/xds_http_composite_filter.cc +26 -21
- data/src/core/xds/grpc/xds_http_composite_filter.h +4 -3
- data/src/core/xds/grpc/xds_http_ext_proc_filter.cc +418 -0
- data/src/core/xds/grpc/xds_http_ext_proc_filter.h +89 -0
- data/src/core/xds/grpc/xds_http_fault_filter.cc +9 -12
- data/src/core/xds/grpc/xds_http_fault_filter.h +1 -4
- data/src/core/xds/grpc/xds_http_filter.cc +2 -1
- data/src/core/xds/grpc/xds_http_filter.h +6 -5
- data/src/core/xds/grpc/xds_http_filter_registry.cc +10 -127
- data/src/core/xds/grpc/xds_http_filter_registry.h +7 -59
- data/src/core/xds/grpc/xds_http_gcp_authn_filter.cc +13 -14
- data/src/core/xds/grpc/xds_http_gcp_authn_filter.h +3 -2
- data/src/core/xds/grpc/xds_http_rbac_filter.cc +403 -25
- data/src/core/xds/grpc/xds_http_rbac_filter.h +1 -3
- data/src/core/xds/grpc/xds_http_stateful_session_filter.cc +8 -13
- data/src/core/xds/grpc/xds_http_stateful_session_filter.h +1 -4
- data/src/core/xds/grpc/xds_lb_policy_registry.cc +0 -292
- data/src/core/xds/grpc/xds_lb_policy_registry.h +7 -3
- data/src/core/xds/grpc/xds_listener.cc +2 -0
- data/src/core/xds/grpc/xds_listener.h +5 -0
- data/src/core/xds/grpc/xds_listener_parser.cc +16 -11
- data/src/core/xds/grpc/xds_matcher_parse.h +3 -1
- data/src/core/xds/grpc/xds_metadata_parser.cc +6 -1
- data/src/core/xds/grpc/xds_metadata_parser.h +2 -0
- data/src/core/xds/grpc/xds_route_config.cc +2 -0
- data/src/core/xds/grpc/xds_route_config.h +3 -1
- data/src/core/xds/grpc/xds_route_config_parser.cc +13 -79
- data/src/core/xds/grpc/xds_route_config_parser.h +0 -3
- data/src/core/xds/grpc/xds_routing.cc +116 -69
- data/src/core/xds/grpc/xds_routing.h +19 -8
- data/src/core/xds/grpc/xds_tls_context.cc +117 -0
- data/src/core/xds/grpc/xds_tls_context.h +76 -0
- data/src/core/xds/grpc/xds_tls_context_parser.cc +275 -0
- data/src/core/xds/grpc/xds_tls_context_parser.h +35 -0
- data/src/core/xds/grpc/xds_transport_grpc.cc +41 -38
- data/src/core/xds/grpc/xds_transport_grpc.h +4 -2
- data/src/ruby/ext/grpc/rb_call.c +26 -15
- data/src/ruby/ext/grpc/rb_completion_queue.c +6 -5
- data/src/ruby/ext/grpc/rb_grpc_imports.generated.c +2 -0
- data/src/ruby/ext/grpc/rb_grpc_imports.generated.h +3 -0
- data/src/ruby/lib/grpc/version.rb +1 -1
- data/src/ruby/pb/test/client.rb +5 -4
- data/src/ruby/spec/call_spec.rb +14 -0
- data/src/ruby/spec/generic/server_interceptors_spec.rb +3 -6
- metadata +50 -35
- data/src/core/ext/upbdefs-gen/src/proto/grpc/channelz/channelz.upbdefs.c +0 -716
- data/src/core/lib/iomgr/resolve_address.cc +0 -59
- data/src/core/lib/iomgr/resolve_address.h +0 -125
- data/src/core/lib/iomgr/resolve_address_impl.h +0 -58
- data/src/core/lib/iomgr/resolve_address_posix.cc +0 -184
- data/src/core/lib/iomgr/resolve_address_posix.h +0 -78
- data/src/core/lib/iomgr/resolve_address_windows.cc +0 -169
- data/src/core/lib/iomgr/resolve_address_windows.h +0 -76
- data/src/core/resolver/dns/c_ares/dns_resolver_ares.cc +0 -781
- data/src/core/resolver/dns/c_ares/grpc_ares_ev_driver.h +0 -93
- data/src/core/resolver/dns/c_ares/grpc_ares_ev_driver_posix.cc +0 -203
- data/src/core/resolver/dns/c_ares/grpc_ares_ev_driver_windows.cc +0 -838
- data/src/core/resolver/dns/c_ares/grpc_ares_wrapper.cc +0 -1237
- data/src/core/resolver/dns/c_ares/grpc_ares_wrapper.h +0 -130
- data/src/core/resolver/dns/c_ares/grpc_ares_wrapper_windows.cc +0 -35
- data/src/core/resolver/dns/dns_resolver_plugin.cc +0 -64
- data/src/core/resolver/dns/native/dns_resolver.cc +0 -173
- data/src/core/util/json/json_util.cc +0 -101
- data/src/core/util/json/json_util.h +0 -163
data/src/core/ext/upbdefs-gen/{src/proto/grpc/channelz → grpc/channelz/v1}/channelz.upbdefs.h
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* This file was generated by upb_generator from the input file:
|
|
2
2
|
*
|
|
3
|
-
*
|
|
3
|
+
* grpc/channelz/v1/channelz.proto
|
|
4
4
|
*
|
|
5
5
|
* Do not edit -- your changes will be discarded when the file is
|
|
6
6
|
* regenerated.
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
#ifndef
|
|
12
|
-
#define
|
|
11
|
+
#ifndef GRPC_CHANNELZ_V1_CHANNELZ_PROTO_UPB_H__UPBDEFS_H_
|
|
12
|
+
#define GRPC_CHANNELZ_V1_CHANNELZ_PROTO_UPB_H__UPBDEFS_H_
|
|
13
13
|
|
|
14
14
|
#include "upb/reflection/def.h"
|
|
15
15
|
#include "upb/reflection/internal/def_pool.h"
|
|
@@ -20,200 +20,200 @@
|
|
|
20
20
|
extern "C" {
|
|
21
21
|
#endif
|
|
22
22
|
|
|
23
|
-
extern _upb_DefPool_Init
|
|
23
|
+
extern _upb_DefPool_Init grpc_channelz_v1_channelz_proto_upbdefinit;
|
|
24
24
|
|
|
25
25
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Channel_getmsgdef(upb_DefPool *s) {
|
|
26
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
26
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
27
27
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Channel");
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Subchannel_getmsgdef(upb_DefPool *s) {
|
|
31
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
31
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
32
32
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Subchannel");
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ChannelConnectivityState_getmsgdef(upb_DefPool *s) {
|
|
36
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
36
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
37
37
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ChannelConnectivityState");
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ChannelData_getmsgdef(upb_DefPool *s) {
|
|
41
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
41
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
42
42
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ChannelData");
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ChannelTraceEvent_getmsgdef(upb_DefPool *s) {
|
|
46
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
46
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
47
47
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ChannelTraceEvent");
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ChannelTrace_getmsgdef(upb_DefPool *s) {
|
|
51
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
51
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
52
52
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ChannelTrace");
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ChannelRef_getmsgdef(upb_DefPool *s) {
|
|
56
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
56
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
57
57
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ChannelRef");
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SubchannelRef_getmsgdef(upb_DefPool *s) {
|
|
61
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
61
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
62
62
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SubchannelRef");
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SocketRef_getmsgdef(upb_DefPool *s) {
|
|
66
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
66
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
67
67
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SocketRef");
|
|
68
68
|
}
|
|
69
69
|
|
|
70
70
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ServerRef_getmsgdef(upb_DefPool *s) {
|
|
71
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
71
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
72
72
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ServerRef");
|
|
73
73
|
}
|
|
74
74
|
|
|
75
75
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Server_getmsgdef(upb_DefPool *s) {
|
|
76
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
76
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
77
77
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Server");
|
|
78
78
|
}
|
|
79
79
|
|
|
80
80
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_ServerData_getmsgdef(upb_DefPool *s) {
|
|
81
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
81
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
82
82
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.ServerData");
|
|
83
83
|
}
|
|
84
84
|
|
|
85
85
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Socket_getmsgdef(upb_DefPool *s) {
|
|
86
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
86
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
87
87
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Socket");
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SocketData_getmsgdef(upb_DefPool *s) {
|
|
91
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
91
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
92
92
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SocketData");
|
|
93
93
|
}
|
|
94
94
|
|
|
95
95
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Address_getmsgdef(upb_DefPool *s) {
|
|
96
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
96
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
97
97
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Address");
|
|
98
98
|
}
|
|
99
99
|
|
|
100
100
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Address_TcpIpAddress_getmsgdef(upb_DefPool *s) {
|
|
101
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
101
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
102
102
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Address.TcpIpAddress");
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Address_UdsAddress_getmsgdef(upb_DefPool *s) {
|
|
106
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
106
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
107
107
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Address.UdsAddress");
|
|
108
108
|
}
|
|
109
109
|
|
|
110
110
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Address_OtherAddress_getmsgdef(upb_DefPool *s) {
|
|
111
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
111
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
112
112
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Address.OtherAddress");
|
|
113
113
|
}
|
|
114
114
|
|
|
115
115
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Security_getmsgdef(upb_DefPool *s) {
|
|
116
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
116
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
117
117
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Security");
|
|
118
118
|
}
|
|
119
119
|
|
|
120
120
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Security_Tls_getmsgdef(upb_DefPool *s) {
|
|
121
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
121
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
122
122
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Security.Tls");
|
|
123
123
|
}
|
|
124
124
|
|
|
125
125
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_Security_OtherSecurity_getmsgdef(upb_DefPool *s) {
|
|
126
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
126
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
127
127
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.Security.OtherSecurity");
|
|
128
128
|
}
|
|
129
129
|
|
|
130
130
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SocketOption_getmsgdef(upb_DefPool *s) {
|
|
131
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
131
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
132
132
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SocketOption");
|
|
133
133
|
}
|
|
134
134
|
|
|
135
135
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SocketOptionTimeout_getmsgdef(upb_DefPool *s) {
|
|
136
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
136
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
137
137
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SocketOptionTimeout");
|
|
138
138
|
}
|
|
139
139
|
|
|
140
140
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SocketOptionLinger_getmsgdef(upb_DefPool *s) {
|
|
141
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
141
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
142
142
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SocketOptionLinger");
|
|
143
143
|
}
|
|
144
144
|
|
|
145
145
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_SocketOptionTcpInfo_getmsgdef(upb_DefPool *s) {
|
|
146
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
146
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
147
147
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.SocketOptionTcpInfo");
|
|
148
148
|
}
|
|
149
149
|
|
|
150
150
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetTopChannelsRequest_getmsgdef(upb_DefPool *s) {
|
|
151
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
151
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
152
152
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetTopChannelsRequest");
|
|
153
153
|
}
|
|
154
154
|
|
|
155
155
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetTopChannelsResponse_getmsgdef(upb_DefPool *s) {
|
|
156
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
156
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
157
157
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetTopChannelsResponse");
|
|
158
158
|
}
|
|
159
159
|
|
|
160
160
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetServersRequest_getmsgdef(upb_DefPool *s) {
|
|
161
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
161
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
162
162
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetServersRequest");
|
|
163
163
|
}
|
|
164
164
|
|
|
165
165
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetServersResponse_getmsgdef(upb_DefPool *s) {
|
|
166
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
166
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
167
167
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetServersResponse");
|
|
168
168
|
}
|
|
169
169
|
|
|
170
170
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetServerRequest_getmsgdef(upb_DefPool *s) {
|
|
171
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
171
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
172
172
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetServerRequest");
|
|
173
173
|
}
|
|
174
174
|
|
|
175
175
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetServerResponse_getmsgdef(upb_DefPool *s) {
|
|
176
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
176
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
177
177
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetServerResponse");
|
|
178
178
|
}
|
|
179
179
|
|
|
180
180
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetServerSocketsRequest_getmsgdef(upb_DefPool *s) {
|
|
181
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
181
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
182
182
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetServerSocketsRequest");
|
|
183
183
|
}
|
|
184
184
|
|
|
185
185
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetServerSocketsResponse_getmsgdef(upb_DefPool *s) {
|
|
186
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
186
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
187
187
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetServerSocketsResponse");
|
|
188
188
|
}
|
|
189
189
|
|
|
190
190
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetChannelRequest_getmsgdef(upb_DefPool *s) {
|
|
191
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
191
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
192
192
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetChannelRequest");
|
|
193
193
|
}
|
|
194
194
|
|
|
195
195
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetChannelResponse_getmsgdef(upb_DefPool *s) {
|
|
196
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
196
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
197
197
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetChannelResponse");
|
|
198
198
|
}
|
|
199
199
|
|
|
200
200
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetSubchannelRequest_getmsgdef(upb_DefPool *s) {
|
|
201
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
201
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
202
202
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetSubchannelRequest");
|
|
203
203
|
}
|
|
204
204
|
|
|
205
205
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetSubchannelResponse_getmsgdef(upb_DefPool *s) {
|
|
206
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
206
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
207
207
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetSubchannelResponse");
|
|
208
208
|
}
|
|
209
209
|
|
|
210
210
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetSocketRequest_getmsgdef(upb_DefPool *s) {
|
|
211
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
211
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
212
212
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetSocketRequest");
|
|
213
213
|
}
|
|
214
214
|
|
|
215
215
|
UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetSocketResponse_getmsgdef(upb_DefPool *s) {
|
|
216
|
-
_upb_DefPool_LoadDefInit(s, &
|
|
216
|
+
_upb_DefPool_LoadDefInit(s, &grpc_channelz_v1_channelz_proto_upbdefinit);
|
|
217
217
|
return upb_DefPool_FindMessageByName(s, "grpc.channelz.v1.GetSocketResponse");
|
|
218
218
|
}
|
|
219
219
|
|
|
@@ -224,4 +224,4 @@ UPB_INLINE const upb_MessageDef *grpc_channelz_v1_GetSocketResponse_getmsgdef(up
|
|
|
224
224
|
|
|
225
225
|
#include "upb/port/undef.inc"
|
|
226
226
|
|
|
227
|
-
#endif /*
|
|
227
|
+
#endif /* GRPC_CHANNELZ_V1_CHANNELZ_PROTO_UPB_H__UPBDEFS_H_ */
|
|
@@ -164,9 +164,8 @@ void ServerAuthFilter::RunApplicationCode::OnMdProcessingDone(
|
|
|
164
164
|
if (error_details == nullptr) {
|
|
165
165
|
error_details = "Authentication metadata processing failed.";
|
|
166
166
|
}
|
|
167
|
-
state->client_metadata =
|
|
168
|
-
absl::Status(static_cast<absl::StatusCode>(status), error_details)
|
|
169
|
-
StatusIntProperty::kRpcStatus, status);
|
|
167
|
+
state->client_metadata =
|
|
168
|
+
absl::Status(static_cast<absl::StatusCode>(status), error_details);
|
|
170
169
|
}
|
|
171
170
|
|
|
172
171
|
// Clean up.
|
|
@@ -64,8 +64,16 @@ absl::StatusOr<RefCountedPtr<CompositeFilter>> CompositeFilter::Create(
|
|
|
64
64
|
return absl::InternalError("composite filter config has wrong type");
|
|
65
65
|
}
|
|
66
66
|
auto config = filter_args.config().TakeAsSubclass<const Config>();
|
|
67
|
-
return MakeRefCounted<CompositeFilter>(args, std::move(config)
|
|
68
|
-
|
|
67
|
+
return MakeRefCounted<CompositeFilter>(args, std::move(config));
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
CompositeFilter::CompositeFilter(const ChannelArgs& args,
|
|
71
|
+
RefCountedPtr<const Config> config)
|
|
72
|
+
: V3InterceptorToV2Bridge<CompositeFilter>(args),
|
|
73
|
+
config_(std::move(config)) {
|
|
74
|
+
if (!args.GetBool(GRPC_ARG_USE_V3_STACK).value_or(false)) {
|
|
75
|
+
Init(args);
|
|
76
|
+
}
|
|
69
77
|
}
|
|
70
78
|
|
|
71
79
|
namespace {
|
|
@@ -92,12 +100,11 @@ class InterceptionChainBuilderWrapper final : public FilterChainBuilder {
|
|
|
92
100
|
|
|
93
101
|
} // namespace
|
|
94
102
|
|
|
95
|
-
CompositeFilter::
|
|
96
|
-
RefCountedPtr<const Config> config,
|
|
97
|
-
ChannelFilter::Args filter_args)
|
|
98
|
-
: config_(std::move(config)) {
|
|
103
|
+
void CompositeFilter::Init(const ChannelArgs& args) {
|
|
99
104
|
if (config_->matcher == nullptr) return;
|
|
100
105
|
// Populate filter_chain_map_ from config_.
|
|
106
|
+
const bool is_server =
|
|
107
|
+
args.GetBool(GRPC_ARG_IS_SERVER_FILTER_STACK).value_or(false);
|
|
101
108
|
config_->matcher->ForEachAction([&](const XdsMatcher::Action& action) {
|
|
102
109
|
if (action.type() != ExecuteFilterAction::Type()) return;
|
|
103
110
|
const auto& execute_filter_action =
|
|
@@ -110,31 +117,36 @@ CompositeFilter::CompositeFilter(const ChannelArgs& args,
|
|
|
110
117
|
InterceptionChainBuilder builder(args);
|
|
111
118
|
InterceptionChainBuilderWrapper builder_wrapper(builder);
|
|
112
119
|
for (size_t i = 0; i < merged_configs.size(); ++i) {
|
|
113
|
-
const auto*
|
|
114
|
-
execute_filter_action.filter_chain()[i].filter_impl;
|
|
120
|
+
const auto* factory = execute_filter_action.filter_chain()[i].factory;
|
|
115
121
|
const auto& filter_config = merged_configs[i];
|
|
116
|
-
//
|
|
117
|
-
//
|
|
118
|
-
//
|
|
119
|
-
//
|
|
120
|
-
//
|
|
121
|
-
//
|
|
122
|
-
//
|
|
123
|
-
//
|
|
124
|
-
//
|
|
125
|
-
//
|
|
126
|
-
//
|
|
127
|
-
//
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
122
|
+
// If a filter is not supported on the client or server side
|
|
123
|
+
// (whichever one we're constructing a filter stack for), then we
|
|
124
|
+
// need to fail filter chain construction. This means that any
|
|
125
|
+
// RPC that uses that filter chain will fail.
|
|
126
|
+
//
|
|
127
|
+
// Ideally, we would catch this case at xDS resource validation
|
|
128
|
+
// time, so that we can reject the invalid update instead of
|
|
129
|
+
// failing RPCs. Unfortunately, the composite filter config can
|
|
130
|
+
// be overridden in an RDS resource, and we don't know at RDS
|
|
131
|
+
// resource validation time whether the RDS resource will be used
|
|
132
|
+
// on the client side or server side, so we can't always catch the
|
|
133
|
+
// problem at resource validation time.
|
|
134
|
+
if (is_server) {
|
|
135
|
+
if (!factory->IsSupportedOnServers()) {
|
|
136
|
+
filter_chain_map_[&execute_filter_action] = absl::UnavailableError(
|
|
137
|
+
absl::StrCat(factory->ConfigProtoName(),
|
|
138
|
+
" filter not supported on servers"));
|
|
139
|
+
return;
|
|
140
|
+
}
|
|
141
|
+
} else {
|
|
142
|
+
if (!factory->IsSupportedOnClients()) {
|
|
143
|
+
filter_chain_map_[&execute_filter_action] = absl::UnavailableError(
|
|
144
|
+
absl::StrCat(factory->ConfigProtoName(),
|
|
145
|
+
" filter not supported on clients"));
|
|
146
|
+
return;
|
|
147
|
+
}
|
|
136
148
|
}
|
|
137
|
-
|
|
149
|
+
factory->AddFilter(builder_wrapper, filter_config);
|
|
138
150
|
}
|
|
139
151
|
filter_chain_map_[&execute_filter_action] =
|
|
140
152
|
builder.Build(wrapped_destination());
|
|
@@ -152,7 +164,7 @@ void CompositeFilter::InterceptCall(
|
|
|
152
164
|
handler.PullClientInitialMetadata(),
|
|
153
165
|
[handler, self](ClientMetadataHandle metadata) {
|
|
154
166
|
if (self->config_->matcher == nullptr) {
|
|
155
|
-
GRPC_TRACE_LOG(
|
|
167
|
+
GRPC_TRACE_LOG(composite_filter, INFO)
|
|
156
168
|
<< "[composite " << self.get()
|
|
157
169
|
<< "]: no matcher configured, starting child call";
|
|
158
170
|
CallInitiator initiator = self->MakeChildCall(
|
|
@@ -177,7 +189,7 @@ void CompositeFilter::InterceptCall(
|
|
|
177
189
|
// call to the next filter without sending it
|
|
178
190
|
// through any child filter chain.
|
|
179
191
|
if (action->type() == SkipFilterAction::Type()) {
|
|
180
|
-
GRPC_TRACE_LOG(
|
|
192
|
+
GRPC_TRACE_LOG(composite_filter, INFO)
|
|
181
193
|
<< "[composite " << self.get()
|
|
182
194
|
<< "]: found SkipFilter, starting child call";
|
|
183
195
|
CallInitiator initiator = self->MakeChildCall(
|
|
@@ -201,7 +213,7 @@ void CompositeFilter::InterceptCall(
|
|
|
201
213
|
bool sampled =
|
|
202
214
|
random_value < execute_filter_action.sample_per_million();
|
|
203
215
|
if (!sampled) {
|
|
204
|
-
GRPC_TRACE_LOG(
|
|
216
|
+
GRPC_TRACE_LOG(composite_filter, INFO)
|
|
205
217
|
<< "[composite " << self.get()
|
|
206
218
|
<< "]: not sampled, starting child call";
|
|
207
219
|
CallInitiator initiator = self->MakeChildCall(
|
|
@@ -215,7 +227,7 @@ void CompositeFilter::InterceptCall(
|
|
|
215
227
|
if (it == self->filter_chain_map_.end()) {
|
|
216
228
|
return absl::InternalError("no filter chain found for action");
|
|
217
229
|
}
|
|
218
|
-
GRPC_TRACE_LOG(
|
|
230
|
+
GRPC_TRACE_LOG(composite_filter, INFO)
|
|
219
231
|
<< "[composite " << self.get()
|
|
220
232
|
<< "]: starting call on filter chain";
|
|
221
233
|
auto& unstarted_destination = it->second;
|
|
@@ -58,11 +58,11 @@ class CompositeFilter final : public V3InterceptorToV2Bridge<CompositeFilter> {
|
|
|
58
58
|
class ExecuteFilterAction final : public XdsMatcher::Action {
|
|
59
59
|
public:
|
|
60
60
|
struct Filter {
|
|
61
|
-
const
|
|
61
|
+
const XdsHttpFilterFactory* factory;
|
|
62
62
|
RefCountedPtr<const FilterConfig> filter_config;
|
|
63
63
|
|
|
64
64
|
bool operator==(const Filter& other) const {
|
|
65
|
-
if (
|
|
65
|
+
if (factory != other.factory) return false;
|
|
66
66
|
if (filter_config == nullptr) return other.filter_config == nullptr;
|
|
67
67
|
if (other.filter_config == nullptr) return false;
|
|
68
68
|
return *filter_config == *other.filter_config;
|
|
@@ -136,10 +136,11 @@ class CompositeFilter final : public V3InterceptorToV2Bridge<CompositeFilter> {
|
|
|
136
136
|
static absl::StatusOr<RefCountedPtr<CompositeFilter>> Create(
|
|
137
137
|
const ChannelArgs& args, ChannelFilter::Args filter_args);
|
|
138
138
|
|
|
139
|
-
CompositeFilter(const ChannelArgs& args, RefCountedPtr<const Config> config
|
|
140
|
-
ChannelFilter::Args filter_args);
|
|
139
|
+
CompositeFilter(const ChannelArgs& args, RefCountedPtr<const Config> config);
|
|
141
140
|
|
|
142
141
|
private:
|
|
142
|
+
void Init(const ChannelArgs& args) override;
|
|
143
|
+
|
|
143
144
|
void Orphaned() override {}
|
|
144
145
|
|
|
145
146
|
void InterceptCall(UnstartedCallHandler unstarted_call_handler) override;
|